Browse Source

GimbalController.cc: send NAN instead of 0 when rates are not used

QGC4.4
davidsastresas 11 months ago committed by Julian Oes
parent
commit
29003c4f97
No known key found for this signature in database
GPG Key ID: F0ED380FEA56DE41
  1. 12
      src/Gimbal/GimbalController.cc

12
src/Gimbal/GimbalController.cc

@ -477,8 +477,8 @@ void GimbalController::sendPitchBodyYaw(float pitch, float yaw, bool showError)
showError, showError,
pitch, pitch,
yaw, yaw,
0, NAN,
0, NAN,
flags, flags,
0, 0,
_activeGimbal->deviceId()->rawValue().toUInt()); _activeGimbal->deviceId()->rawValue().toUInt());
@ -510,8 +510,8 @@ void GimbalController::sendPitchAbsoluteYaw(float pitch, float yaw, bool showErr
showError, showError,
pitch, pitch,
yaw, yaw,
0, NAN,
0, NAN,
flags, flags,
0, 0,
_activeGimbal->deviceId()->rawValue().toUInt()); _activeGimbal->deviceId()->rawValue().toUInt());
@ -558,8 +558,8 @@ void GimbalController::sendPitchYawFlags(uint32_t flags)
true, true,
_activeGimbal->absolutePitch()->rawValue().toFloat(), _activeGimbal->absolutePitch()->rawValue().toFloat(),
yaw_in_vehicle_frame ? _activeGimbal->bodyYaw()->rawValue().toFloat() : _activeGimbal->absoluteYaw()->rawValue().toFloat(), yaw_in_vehicle_frame ? _activeGimbal->bodyYaw()->rawValue().toFloat() : _activeGimbal->absoluteYaw()->rawValue().toFloat(),
static_cast<float>(qQNaN()), NAN,
static_cast<float>(qQNaN()), NAN,
flags, flags,
0, 0,
_activeGimbal->deviceId()->rawValue().toUInt()); _activeGimbal->deviceId()->rawValue().toUInt());

Loading…
Cancel
Save