Sub: move try_send_message mission handling up
This commit is contained in:
parent
fee9e83881
commit
7a72c3b1fb
@ -337,11 +337,6 @@ void NOINLINE Sub::send_vfr_hud(mavlink_channel_t chan)
|
||||
climb_rate / 100.0f);
|
||||
}
|
||||
|
||||
void NOINLINE Sub::send_current_waypoint(mavlink_channel_t chan)
|
||||
{
|
||||
mavlink_msg_mission_current_send(chan, mission.get_current_nav_index());
|
||||
}
|
||||
|
||||
/*
|
||||
send RPM packet
|
||||
*/
|
||||
@ -534,21 +529,11 @@ bool GCS_MAVLINK_Sub::try_send_message(enum ap_message id)
|
||||
send_sensor_offsets(sub.ins, sub.compass, sub.barometer);
|
||||
break;
|
||||
|
||||
case MSG_CURRENT_WAYPOINT:
|
||||
CHECK_PAYLOAD_SIZE(MISSION_CURRENT);
|
||||
sub.send_current_waypoint(chan);
|
||||
break;
|
||||
|
||||
case MSG_NEXT_PARAM:
|
||||
CHECK_PAYLOAD_SIZE(PARAM_VALUE);
|
||||
queued_param_send();
|
||||
break;
|
||||
|
||||
case MSG_NEXT_WAYPOINT:
|
||||
CHECK_PAYLOAD_SIZE(MISSION_REQUEST);
|
||||
queued_waypoint_send();
|
||||
break;
|
||||
|
||||
case MSG_RANGEFINDER:
|
||||
#if RANGEFINDER_ENABLED == ENABLED
|
||||
CHECK_PAYLOAD_SIZE(RANGEFINDER);
|
||||
@ -646,11 +631,6 @@ bool GCS_MAVLINK_Sub::try_send_message(enum ap_message id)
|
||||
send_vibration(sub.ins);
|
||||
break;
|
||||
|
||||
case MSG_MISSION_ITEM_REACHED:
|
||||
CHECK_PAYLOAD_SIZE(MISSION_ITEM_REACHED);
|
||||
mavlink_msg_mission_item_reached_send(chan, mission_item_reached_index);
|
||||
break;
|
||||
|
||||
case MSG_BATTERY_STATUS:
|
||||
send_battery_status(sub.battery);
|
||||
break;
|
||||
|
@ -486,7 +486,6 @@ private:
|
||||
void send_hwstatus(mavlink_channel_t chan);
|
||||
void send_radio_out(mavlink_channel_t chan);
|
||||
void send_vfr_hud(mavlink_channel_t chan);
|
||||
void send_current_waypoint(mavlink_channel_t chan);
|
||||
#if RPM_ENABLED == ENABLED
|
||||
void send_rpm(mavlink_channel_t chan);
|
||||
void rpm_update();
|
||||
|
Loading…
Reference in New Issue
Block a user