From c4dcdcf5a215710db2983bdcc9bc4ec7e4f063cb Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Sat, 21 Sep 2013 09:27:22 +1000 Subject: [PATCH] Plane: only send RC_CHANNELS_SCALED in HIL saves a bit of telemetry bandwidth --- ArduPlane/GCS_Mavlink.pde | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ArduPlane/GCS_Mavlink.pde b/ArduPlane/GCS_Mavlink.pde index 1257304384..54b3cbd624 100644 --- a/ArduPlane/GCS_Mavlink.pde +++ b/ArduPlane/GCS_Mavlink.pde @@ -309,6 +309,7 @@ static void NOINLINE send_gps_raw(mavlink_channel_t chan) g_gps->num_sats); } +#if HIL_MODE != HIL_MODE_DISABLED static void NOINLINE send_servo_out(mavlink_channel_t chan) { // normalized values scaled to -10000 to 10000 @@ -328,6 +329,7 @@ static void NOINLINE send_servo_out(mavlink_channel_t chan) 0, receiver_rssi); } +#endif static void NOINLINE send_radio_in(mavlink_channel_t chan) { @@ -581,8 +583,10 @@ static bool mavlink_try_send_message(mavlink_channel_t chan, enum ap_message id, break; case MSG_SERVO_OUT: +#if HIL_MODE != HIL_MODE_DISABLED CHECK_PAYLOAD_SIZE(RC_CHANNELS_SCALED); send_servo_out(chan); +#endif break; case MSG_RADIO_IN: