accel31
2.1.0.0
|
Accel 31 Click is a compact add-on board designed for precise motion and orientation detection in space-constrained devices. This board features the BMA580, a triaxial low-g accelerometer from Bosch Sensortec, which offers a 16-bit digital resolution with measurement ranges of ±2, ±4, ±8, and ±16 g, along with flexible output data rates from 1.56Hz to 6.4kHz, enabling high adaptability and accuracy. The BMA580 supports advanced power modes, including high-performance and low-power, self-wake-up functionality, and bone conduction-based voice activity detection.
We provide a library for the Accel 31 Click as well as a demo application (example), developed using MikroElektronika compilers. The demo can run on all the main MikroElektronika development boards.
Package can be downloaded/installed directly from NECTO Studio Package Manager(recommended way), downloaded from our LibStock™ or found on Mikroe github account.
This library contains API for Accel 31 Click driver.
accel31_cfg_setup
Config Object Initialization function. accel31_init
Initialization function. accel31_default_cfg
Click Default Configuration function. accel31_get_data
This function reads the accelerometer and temperature measurement data. accel31_set_accel_odr
This function sets the accel measurement output data rate. accel31_set_accel_fsr
This function sets the accel measurement full scale range. This example demonstrates the use of Accel 31 Click board by reading and displaying
the accelerometer data (X, Y, and Z axis) and a temperature measurement in degrees Celsius.
The demo application is composed of two sections :
Initializes the driver and performs the Click default configuration.
Checks for a new data ready indication and then reads the accelerometer and temperature
measurements. The results are displayed on the USB UART at 12.5 Hz output data rate.
The Click board determines the communication protocol at the first communication check
after power-up. In the case of I2C, the IC responds with NACK on the first check, which blocks the I2C bus on some MCUs. Re-running the program (without power cycling the Click board power supply) should unlock the communication and solve this issue.
The full application code, and ready to use projects can be installed directly from NECTO Studio Package Manager(recommended way), downloaded from our LibStock™ or found on Mikroe github account.
Other Mikroe Libraries used in the example:
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 MikroElektronika compilers.