Skip to content

Commit

Permalink
Update MPUxxxx.h
Browse files Browse the repository at this point in the history
  • Loading branch information
qqqlab authored Aug 29, 2024
1 parent 6bbe53f commit b4f7dc4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/madflight/imu/MPUxxxx/MPUxxxx.h
Original file line number Diff line number Diff line change
Expand Up @@ -226,7 +226,7 @@ class MPUXXXX {
{
uint8_t d[14]; //response is 14 bytes = 6 acc + 2 temp + 6 gyro
_iface->setFreqFast();
_iface->ReadRegs(MPUREG_ACCEL_XOUT_H, d, 20);
_iface->ReadRegs(MPUREG_ACCEL_XOUT_H, d, 14);
// Get accelerometer (6 bytes) - sensor orientation for acc/gyro is NWU
rawa[0] = -(int16_t)((d[0]<<8) | d[1]); //-N = -N
rawa[1] = (int16_t)((d[2]<<8) | d[3]); //-E = W
Expand Down

0 comments on commit b4f7dc4

Please sign in to comment.