Skip to main content
QAbba.1
Associate II
February 19, 2022
Solved

I am using BSP_MOTION_SENSOR_GetAxes function to acquire data (gyro+accelero) from sensortile kit. I want to know: 1- What are the output units of this data? 2- Do I need to do any processing before passing this data to MotionDI_update function?

..

    This topic has been closed for replies.
    Petr S
    Petr SBest answer
    ST Employee
    February 24, 2022

    1. The BSP_MOTION_SENSOR_GetAxes function provides ACC data in mg and GYR data in mdps.

    2. These data need to be converted from mg resp. mdps to g resp. dps and you also need to provide timestamp in microseconds. You can use DI_Data_Handler function in DynamicInclinometer FW application inside X-CUBE-MEMS1 package as a reference.

    2 replies

    Petr S
    Petr SBest answer
    ST Employee
    February 24, 2022

    1. The BSP_MOTION_SENSOR_GetAxes function provides ACC data in mg and GYR data in mdps.

    2. These data need to be converted from mg resp. mdps to g resp. dps and you also need to provide timestamp in microseconds. You can use DI_Data_Handler function in DynamicInclinometer FW application inside X-CUBE-MEMS1 package as a reference.

    QAbba.1
    QAbba.1Author
    Associate II
    February 24, 2022

    Hi Petr,

    I figured out the units of angular velocity and linear acceleration. However, I didn't know that the MotionDI_update function needed timestamp input in microseconds. I was giving input in milliseconds and hence I was getting wrong rotation. Thank you for mentioning it. Now, I am able to get the correct rotation.