2021-09-14 12:49 AM
We get three 16-bit value from the register of ISM330DLC, how to use the three values to calculate the acceleration? Please help.
Solved! Go to Solution.
2021-09-14 06:17 AM
Hi, you can check the datasheet for the conversion formula and the sensitivities, but I found a C sample code on GitHub that if maintained by ST, and where you can find the conversion formula. The "lsb" are the raw data to be inserted in:
float_t ism330dlc_from_fs2g_to_mg(int16_t lsb)
{
return ((float_t)lsb * 0.061f);
}
2021-09-14 06:17 AM
Hi, you can check the datasheet for the conversion formula and the sensitivities, but I found a C sample code on GitHub that if maintained by ST, and where you can find the conversion formula. The "lsb" are the raw data to be inserted in:
float_t ism330dlc_from_fs2g_to_mg(int16_t lsb)
{
return ((float_t)lsb * 0.061f);
}
2021-09-15 12:54 AM
Thanks for the reply @TSand.1 . Do we need to use vector magnitude calculation formula to find the overall acceleration magnitude?
2021-09-16 06:31 AM
yes, you need the 3 spatial axis components to get the total acceleration magnitude in space
2021-09-17 01:37 AM
Thanks @TSand.1