cancel
Showing results for 
Search instead for 
Did you mean: 

MCU entry hardfault when I called the fuction of MotionFX_CM0P_initialize(), the sensor is LSM6DS3,

wchao.1
Associate II

Hello bro, MCU entry hardfault when I called the fuction of MotionFX_CM0P_initialize(), the sensor is LSM6DS3,  the algorithm I am using is motionFX Library. The stack did not overflow. Do you have any good idea for this problem ? thanks!

5 REPLIES 5
Eleon BORLINI
ST Employee

Hi @wchao.1​ , please check if this thread can be of any help. They get HardFault after the call of motionFx_CM0P_Initialize() too (with ARM and STM32L031K6). Regards

Hi Eleon, thank you for your reply, maybe it is related to the MCU, I found that the hardware CRC initialization needs to be called before calling the library initialization, otherwise the F103 OR F429 will crash. May I ask whether this sensor algorithm can be used on the other MCU, such as NXP or Non-st manufacturer's products. thanks again!

These libraries can in principle be used on ARM-based micro-controllers, but the portability across different MCU families is easy only among the ST MCUs, thanks to the STM32Cube software, and is optimized for the ST MCUs interface with ST sensors... Regards

Sorry for the late reply, what should I do if I want to use the FX library on the another CM0+ MCU?

I can now work with the LSM6DS3's data to calculate the pitch and yaw angles, but the deviation fluctuates  a lot, so I would like to use ST official library to compare the calculate's result, thanks Eleon

Hi @wchao.1​ , it is possible, but for this kind of question please note that the release of STM proprietary libraries is subject to signature of a License User Agreement (LUA); and you should please contact an STMicroelectronics sales office and representative of your geographical area for further information. Regards