How does it work?
Accel 27 Click is based on the ADXL373, a complete three-axis ±400g acceleration measurement system from Analog Devices, operating at extremely low power levels. Built-in digital logic enables autonomous operation and implements functions that enhance system-level power savings. It offers 12-bit output data at 200mg/LSB scale factor, where acceleration is reported digitally through a configurable and selectable serial interface. The ADXL373 has three operating modes. Measurement mode is used for continuous, broad bandwidth sensing. The wake-up mode is used for limited bandwidth low g activity detection, and the instant-on mode is used for low power impact detection. Measurement can be suspended entirely by placing the ADXL373 in Standby mode.
As mentioned, the acceleration data is accessed through I2C or SPI interface with a maximum frequency of 3.4MHz for I2C and 10MHz for SPI communication. The selection is made by positioning SMD jumpers labeled COMM SEL in an appropriate position. Note that all the jumpers’ positions must be on the same side, or the Click board™ may become unresponsive. While the I2C interface is selected, the ADXL373 allows choosing the least significant bit (LSB) of its I2C slave address using the SMD jumper labeled ADDR SEL.
This board also possesses two interrupts, IT1 and IT2, routed to, where by default, the INT and AN pins stand on the mikroBUS™ socket, entirely programmed by the user through a serial interface. They signal MCU that a motion event has been sensed.
This Click board™ can be operated only with a 3.3V logic voltage level. The board must perform appropriate logic voltage level conversion before using MCUs with different logic levels. However, the Click board™ comes equipped with a library containing functions and an example code that can be used as a reference for further development.
Specifications
Type
Motion
Applications
Can be used for motion-activated functions, impact, and shock detection, medical IoT applications, and more
On-board modules
ADXL373 – three-axis MEMS accelerometer from Analog Devices
Key Features
±400g measurement range, user selectable bandwidth with 4-pole antialiasing filter, selectable oversampling ratio, low power consumption, built-in features for system power savings, selectable interface, event monitoring, and more
Interface
I2C,SPI
Feature
ClickID
Compatibility
mikroBUS™
Input Voltage
3.3V
Pinout diagram
This table shows how the pinout on Accel 27 Click corresponds to the pinout on the mikroBUS™ socket (the latter shown in the two middle columns).
Onboard settings and indicators
Label | Name | Default | Description |
---|---|---|---|
LD1 | PWR | – | Power LED Indicator |
JP1-JP4 | COMM SEL | Right | Communication Interface Selection SPI/I2C: Left position SPI, Right position I2C |
JP5 | ADDR SEL | Left | I2C Address Selection 0/1: Left position 0, Right position 1 |
Accel 27 Click electrical specifications
Description | Min | Typ | Max | Unit |
---|---|---|---|---|
Supply Voltage | – | 3.3 | – | V |
Acceleration Range | – | ±400 | – | g |
Resolution | – | 12 | – | bits |
Scale Factor | – | 200 | – | mg/LSB |
Software Support
We provide a library for the Accel 27 Click as well as a demo application (example), developed using Mikroe compilers. The demo can run on all the main Mikroe development boards.
Package can be downloaded/installed directly from NECTO Studio Package Manager (recommended), downloaded from our LibStock™ or found on Mikroe github account.
Library Description
This library contains API for Accel 27 Click driver.
Key functions
-
accel27_get_int1_pin
This function returns the interrupt 1 (INT1) pin logic state. -
accel27_get_axes
This function reads accel X, Y, and Z axis data in g. -
accel27_reset_device
This function performs the chip software reset.
Example Description
This example demonstrates the use of Accel 27 Click board™ by reading and displaying the accelerometer data (X, Y, and Z axis) averaged from 100 samples.
void application_task ( void )
{
accel27_axes_t axes = { 0 };
uint16_t cnt = 0;
while ( cnt < NUM_OF_SAMPLES )
{
// Wait for data ready indication
while ( !accel27_get_int1_pin ( &accel27 ) );
accel27_axes_t tmp_axes;
if ( ACCEL27_OK == accel27_get_axes ( &accel27, &tmp_axes ) )
{
axes.x += tmp_axes.x;
axes.y += tmp_axes.y;
axes.z += tmp_axes.z;
cnt++;
}
}
axes.x = axes.x / NUM_OF_SAMPLES;
axes.y = axes.y / NUM_OF_SAMPLES;
axes.z = axes.z / NUM_OF_SAMPLES;
log_printf( &logger, " X: %.1f grn", axes.x );
log_printf( &logger, " Y: %.1f grn", axes.y );
log_printf( &logger, " Z: %.1f grnn", axes.z );
}
The full application code, and ready to use projects can be installed directly from NECTO Studio Package Manager (recommended), downloaded from our LibStock™ or found on Mikroe github account.
Other Mikroe Libraries used in the example:
- MikroSDK.Board
- MikroSDK.Log
- Click.Accel27
Additional notes and informations
Depending on the development board you are using, you may need USB UART click, USB UART 2 Click or RS232 Click to connect to your PC, for development systems with no UART to USB interface available on the board. UART terminal is available in all Mikroe compilers.
mikroSDK
This Click board™ is supported with mikroSDK – Mikroe Software Development Kit, which needs to be downloaded from the LibStock and installed for the compiler you are using to ensure proper operation of mikroSDK compliant Click board™ demo applications.
For more information about mikroSDK, visit the official page.