I am writing in this forum for the first time. I am using a BNO055 fixed at the thigh to record the orientation of the leg during a gait. In order to do it, I plotted the yaw output. There is weird behavior based on the inversion walk. Imagine being in a room doing a walk forward, then rotate yourself and you come back. During the inversion, the coordinate system of the start is changed from 0 to 360 because the base coordinate system for navigation is fixed to the Earth. In the black section, the sensor is just calibrated totally. Then it is worn at the level of the thigh more or less and I start to walk. The red indicates the walk in a direction and the green in the opposite one (where each wave indicates a step). All of them of course include the inversion of gait at the end of each color. I need to put some thresholds to let the sensor recognize in real-time the maximum and minimum of each wave. How can I do it?
Furthermore, I am not able to interpret the graph of the quaternion.
Tips or github link are super appreciated. Thank you so much.
Solved! Go to Solution.
Thanks for your inquiry.
The red and green waveforms of BNO055 yaw output clearly show each step. You don't need to define min/mac threshold to recognize each step. Instead, you can use peak detection algorithm which you can search online.
Quaternion is a way to describe the relationship between BNO055 body axes and fixed local frame axes. It is equivalent to Euler angles (pitch/roll/yaw). So you can just use Euler angles for your application and ignore quaternions.
If the x axis of the your device is towards up or down(pitch angle =90/-90 deg). And then you measure the yaw angle around the z axis to try to measure the angle of thigh. That's not a good way. Because we use the rotation sequence as yaw-pitch-roll, so when rotate to 90 deg , that would be gimbal lock handling. I would suppose 3 ways to fix this issue:
1.You can make the y axis towards up/down and then measure the yaw angle.
2.You can put the z axis of the device towards up, and then measure the pitch or roll angle.
3.We can remap the axis of the BNO055 and generate a new firmware for you.
Thank you so much, I figured out avoiding the gimbal lock. I did it only considering the vertical acceleration. Then I measured the inclination referring to it. Thank you again.