I'm using the MPU6050 for a fall detector project and I want to use the gyroscope to display the Yaw, Pitch and Roll values. I'm using a code to convert the gyroscope values to quaternion values, then use that to display yaw, pitch and roll but when I test it on my MPU6050, the values keep changing (all three axes) even if I only rotate it in one axis. Is there another formula? Why are my readings erroneous ?
Eld.ino (9.37 KB)