mirror of
https://gitee.com/xiaohuolufeihua/bizhang_-obav.git
synced 2026-05-22 09:28:58 +00:00
mavlink and commander app: Add support for manual input, either directly or via remote control
This commit is contained in:
@@ -123,6 +123,7 @@ Mavlink::Mavlink() :
|
||||
_mavlink_fd(-1),
|
||||
_task_running(false),
|
||||
_hil_enabled(false),
|
||||
_generate_rc(false),
|
||||
_use_hil_gps(false),
|
||||
_forward_externalsp(false),
|
||||
_is_usb_uart(false),
|
||||
@@ -1497,6 +1498,8 @@ Mavlink::task_main(int argc, char *argv[])
|
||||
if (status_sub->update(&status_time, &status)) {
|
||||
/* switch HIL mode if required */
|
||||
set_hil_enabled(status.hil_state == vehicle_status_s::HIL_STATE_ON);
|
||||
|
||||
set_manual_input_mode_generation(status.rc_input_off == vehicle_status_s::RC_IN_MODE_GENERATED);
|
||||
}
|
||||
|
||||
/* check for requested subscriptions */
|
||||
|
||||
Reference in New Issue
Block a user