This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

CCS/CC2650STK: CC2650 Madgwick AHRS

Part Number: CC2650STK


Tool/software: Code Composer Studio

I am using CCS 7.0.0 on Linux and TI CGT ARM LTS 16.9.LTS compiler. I am using the SensorTag firmware as a base.
I just implemented a 20 Hz periodic clock task/handler for running Madgwick AHRS fusion algorithm at a rate of 20 Hz. I just post a semaphore to the main thread (SensorTag_taskFxn) at the beginning of Madgwick periodic clock handler.
The task properly runs at 20 Hz and posts to main thread too. Problem here is that the end result just doesn't create any meaningful data, the euler angles nowhere correspond to the physical orientation. Also, after some 40 seconds the values become stable and stay that way forever and do not change when the orientation is changed.
I am disabling Wake-On-Motion interrupt and enabling Data Rdy Interrupt but it seems to not have any effect. In both cases, Wake-On-Motion and Data Rdy, the results are exactly the same.