mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-01-09 01:18:29 -04:00
Sub: use AP::ahrs() for GCS_MAVLink
This commit is contained in:
parent
0d04e916a1
commit
15f212adc0
@ -517,11 +517,6 @@ bool GCS_MAVLINK_Sub::try_send_message(enum ap_message id)
|
||||
sub.send_location(chan);
|
||||
break;
|
||||
|
||||
case MSG_LOCAL_POSITION:
|
||||
CHECK_PAYLOAD_SIZE(LOCAL_POSITION_NED);
|
||||
send_local_position(sub.ahrs);
|
||||
break;
|
||||
|
||||
case MSG_NAV_CONTROLLER_OUTPUT:
|
||||
CHECK_PAYLOAD_SIZE(NAV_CONTROLLER_OUTPUT);
|
||||
sub.send_nav_controller_output(chan);
|
||||
@ -588,18 +583,13 @@ bool GCS_MAVLINK_Sub::try_send_message(enum ap_message id)
|
||||
#endif
|
||||
break;
|
||||
|
||||
case MSG_AHRS:
|
||||
CHECK_PAYLOAD_SIZE(AHRS);
|
||||
send_ahrs(sub.ahrs);
|
||||
break;
|
||||
|
||||
case MSG_SIMSTATE:
|
||||
#if CONFIG_HAL_BOARD == HAL_BOARD_SITL
|
||||
CHECK_PAYLOAD_SIZE(SIMSTATE);
|
||||
sub.send_simstate(chan);
|
||||
#endif
|
||||
CHECK_PAYLOAD_SIZE(AHRS2);
|
||||
send_ahrs2(sub.ahrs);
|
||||
send_ahrs2();
|
||||
break;
|
||||
|
||||
case MSG_MOUNT_STATUS:
|
||||
@ -617,7 +607,7 @@ bool GCS_MAVLINK_Sub::try_send_message(enum ap_message id)
|
||||
case MSG_OPTICAL_FLOW:
|
||||
#if OPTFLOW == ENABLED
|
||||
CHECK_PAYLOAD_SIZE(OPTICAL_FLOW);
|
||||
send_opticalflow(sub.ahrs, sub.optflow);
|
||||
send_opticalflow(sub.optflow);
|
||||
#endif
|
||||
break;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user