06-23-2020 06:01 PM
Hi,
In the BSXLite Integration guide, it is mentioned that the sensor fusion output has a fixed data rate of 50Hz.
Could you clarify, if the acquisition is interrupt-based and if the sensor fusion data ( such as Quaternion, Euler) can be sampled automatically at 50Hz using an interrupt callback?
Or is there a need for a separate timer to sample the data at 50Hz manually.?
Thanks
Solved! Go to Solution.
06-23-2020 08:17 PM
BSX lite is just sensor fusion and it only supports 50Hz data rate.
This means you can only call BSX lite's do_step every 20ms.
The data acqusition is done on physical sensor level which can be interrupt based.
Then you get desired data in the time stick then feed into BSX lite.
A system timer to align on the precies tick for BSX lite is recommend.
06-24-2020 03:27 PM
So, the sensor fusion data as such is not interrupt based..?
And to acquire the sensor fusion data I have to either manually call the dostep() function every time or use a 50Hz Timer and execute the dostep() function in the Timer callback..?
06-25-2020 12:16 AM
Yes, you need manully call the do_step of fusion lib.
Those detail steps are able to be found in BSX porting guide along with the lib.
Only the physical data acquisiton can be set as interrupt based.
Or you can use physical sensor's data ready interrupt service routine to call fusion lib's do_step which is not recommend to do so.
06-25-2020 07:15 AM
ok. Thanks.