From 36788a60f42a9bd0611d4006f8f41140ddc98164 Mon Sep 17 00:00:00 2001 From: Corvus Corax Date: Fri, 27 Dec 2013 16:26:59 +0100 Subject: [PATCH] bugfix for xplane hitl, convert gyroscope sensor from rad/s to deg/s --- ground/openpilotgcs/src/plugins/hitl/xplanesimulator.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ground/openpilotgcs/src/plugins/hitl/xplanesimulator.cpp b/ground/openpilotgcs/src/plugins/hitl/xplanesimulator.cpp index 53609951e..20beab45d 100644 --- a/ground/openpilotgcs/src/plugins/hitl/xplanesimulator.cpp +++ b/ground/openpilotgcs/src/plugins/hitl/xplanesimulator.cpp @@ -318,10 +318,10 @@ void XplaneSimulator::processUpdate(const QByteArray & dataBuf) out.velEast = velX; out.velDown = -velZ; - // Update gyroscope sensor data - out.rollRate = rollRate_rad; - out.pitchRate = pitchRate_rad; - out.yawRate = yawRate_rad; + // Update gyroscope sensor data - convert from rad/s to deg/s + out.rollRate = rollRate_rad * (180.0/M_PI); + out.pitchRate = pitchRate_rad * (180.0/M_PI); + out.yawRate = yawRate_rad * (180.0/M_PI); // Update accelerometer sensor data out.accX = accX;