Hi,
I have the following questions about Fusion Library 5.0:
1) Systick shows 53 for 9 axis fusion. Does it mean the function for 9 axis fusion need (53/120MHz)==0.44uS to run once?
2) Fusion task is lower priority than sampling task, will be interrupt by sampling task. I tested the time required to read ACC around 237uS. If the fusion task is interrupted by sampling task, the systick should be much longer?
3) My own project is not using MQX. I am using PIT0/1/2 for data sampling, fusion and MAGCal. PIT0 priority is higher than PIT1/2. PIT1 priority is higher than PIT2.
When I call 9 axis fusion function, it takes around 1.6ms? Why does it make so big difference?
Thanks,
Christie
Solved! Go to Solution.
Hi Mike,
I found the reason. I need to use -O3 instead of -O0 to do the optimization. Now almost the same as demo project...
Thanks,
Christie
Christie,
In order:
Mike
Hi Mike,
1) My mistake. in K-ticks, the measuring time is reasonable.
2) I measure the timing between your demo project and my own project:
-----Sampling time in my project is about 1183uS===7100/60MHz.
-----9-axis data fusion in my project==1600uS==95700/60MHz, in your demo project==442uS
-----6-axis GB data fusion in my project==317uS==19000/60MHz, in your demo project==94uS
-----9-axis GY data fusion in my project===96uS==5750/60MHz, in your demo project==25uS
All functions in both projects are working fine. Do you think that there is any performance difference in data fusion result?
3) I am using KDS 3.0.0 and KSDK 1.2.0 to develop my own project. Both projects are running on the same demo board. In my project, I am using 120MHz for core, 60 MHz for BUS clock. I am using 60MHz for PIT0/1/2. I am using PIT0 ticks to measure the time. My measuring time is just for data fusion function.
Is possible to be related to CPU floating setting or math library difference between two projects?
Thanks,
Christie
Hi Mike,
I found the reason. I need to use -O3 instead of -O0 to do the optimization. Now almost the same as demo project...
Thanks,
Christie
That will do it! Glad the mystery has been cleared up.
Mike