Can gravity affect into MPU6050 signal?

253 Views Asked by At

I stream ax,ay,az from sensor mpu6050 to calculate the angle as this equation:

ax = data_mpu["ax"]
ay = data_mpu["ay"]
az = data_mpu["az"]

phi   = np.arctan2(ay,az) * 180/np.pi 
theta = np.arctan2(ax,az) * 180/np.pi 
psi   = np.arctan2(ay,ax) * 180/np.pi 

But it seem like if any axis get the orientation parallel with the gravity, i can not calculate angle of sensor rotate around that axis correctly. Is that true, Anybody get the same problem? Can anyone help me :(

0

There are 0 best solutions below