02-22-2024 08:36 PM - edited 02-22-2024 08:37 PM
Hello, I am currently using BHI360 to extract aceleartion to get velocity and distance, and I have been processing readings from linear accelerometer using average and LP and HP filters as can be seen in the file below.
I have heard that there are built-in filters in Bosch's library, but I haven't found any library in C that I can instantly use. Can anyone point me to where or how I can use these filters in a C environment?
Solved! Go to Solution.
02-27-2024 03:53 AM
Hi Newguy,
BHI360 has a built-in algorithm that outputs sensor data and algorithm results to the host in FIFO format. For a detailed description, please refer to Section "15 FIFO Data Type and Format" in data sheet.
02-29-2024 09:35 PM
I don't see mentions of a filter implementation, so I am moving towards using accelerometer correct data.
But when I run BHY2_SENSOR_ID_ACC using this c file (I just changed the sensor name on line 167, 191, 193), it outputs uncalibrated data, which I found by reading META event.
Is there a way to have the sensor calibrated before output data?
03-03-2024 12:57 AM
Additionally, I would prefer a way to have the sensor calibrated without having to go through the calibration process for a 6 axis accelerometer, where you have to rotate the sensor to certain positions.
03-07-2024 07:13 AM
Hi Newguy,
BHI360 fw has not disclosed any implementation of filters. But you can obtain different data through different virtual sensor IDs.
BHY2_SENSOR_ID_ACC is the virtual sensor ID that has been calibrated for acceleration data.
You can find the code annotation in bhy2_defs.h
#define BHY2_SENSOR_ID_ACC_PASS UINT8_C(1) /* Accelerometer passthrough */
#define BHY2_SENSOR_ID_ACC_RAW UINT8_C(3) /* Accelerometer uncalibrated */
#define BHY2_SENSOR_ID_ACC UINT8_C(4) /* Accelerometer corrected */
#define BHY2_SENSOR_ID_ACC_BIAS UINT8_C(5) /* Accelerometer offset */