How to continue Motion Detection with MMRL SensorFusion after unexpected Disconnect
I want to detect certain motions of the upper arm by using SensorFusion. Leaving unexpected disconnects aside it works quite well so far with the following steps:
1. user places sensor on arm and stays still for a while, SensorFusion is started (as in the Meta-ROM App)
2. i take the quaternion of that initial position.
3. use initial position quaternion to interpret the new incoming quaternions as upper arm motions
after an unexpected disconnect i have to reconnect and restart the SensorFusion, which will begin with a different initial position, which in turn will mess up my motion detection. i want to avoid making the user go into the start position and stand still for a few seconds again.
1. is it possible to keep streaming the SensorFusion after a disconnect so it wont restart with fresh initial values?
2. or if i would roughly infer the sensor position with sensorFusion.GRAVITY, could I write a start quaternion into the sensorFusion so all later incoming quaternions are relative to that written start quaternion?
"sensorFusion.writeCalibrationData(startQuaternion);" as described in https://mbientlab.com/androiddocs/latest/sensor_fusion.html.
Thanks so much!
Thanks for your reply!
i like the idea, but i am struggling at implementation now. i took a look at the MetaBase source code and found the code snippets for logging and streaming with "addRouteAsync(...)".
1. What are you refering to with "event module"? i dont find anything like that in the SDK documentation.
2. is there any example code of using this event module, even it its not about for SensorFusion?