2021-02-11 08:43 AM
We are using ST IMU LSM6DSL in to our chipset/PCB.
We are looking for ready to use software or algorithm to implement in to our firmware to determine the speed/acceleration & distance from IMU data.
Is there any example code available for share?
Solved! Go to Solution.
2021-02-12 12:33 AM
Hi @IKhan.1 ,
I believe that the problem can be divided into two step.
The first step is data acquisition process. For this purpose, especially if you are using a custom application processor, you can refer to the C drivers (lsm6dsl_reg.c) and the C example on Github (lsm6dsl_read_data_polling.c). If you instead are using an STM32, there a re a lot of project /examples
The second step is the algorithm implementation. If you want to calculate the speed and the distance from the raw data, you should use more complex libraries, and take care of the periodic calibration of the sensors. There are some examples available for STM32 in the X-CUBE-MEMS1 firmware function pack (such as the MotionPE real-time pose estimation or the MotionFX sensor fusion library). You could start from these examples (although the source code of these libraries is not open source) and build up your own code.
-Eleon
2021-02-12 12:33 AM
Hi @IKhan.1 ,
I believe that the problem can be divided into two step.
The first step is data acquisition process. For this purpose, especially if you are using a custom application processor, you can refer to the C drivers (lsm6dsl_reg.c) and the C example on Github (lsm6dsl_read_data_polling.c). If you instead are using an STM32, there a re a lot of project /examples
The second step is the algorithm implementation. If you want to calculate the speed and the distance from the raw data, you should use more complex libraries, and take care of the periodic calibration of the sensors. There are some examples available for STM32 in the X-CUBE-MEMS1 firmware function pack (such as the MotionPE real-time pose estimation or the MotionFX sensor fusion library). You could start from these examples (although the source code of these libraries is not open source) and build up your own code.
-Eleon
2021-02-15 07:23 AM
2021-02-15 08:48 AM
Thank you @IKhan.1 :smiling_face_with_smiling_eyes:
Have a nice day you too,
-Eleon
2024-05-19 11:57 PM
Can i use this Motion librarys for nxp controller ?