2016-05-27 10:04:55 -03:00
|
|
|
#pragma once
|
|
|
|
|
|
|
|
#include <GCS_MAVLink/GCS.h>
|
|
|
|
|
|
|
|
class GCS_MAVLINK_Rover : public GCS_MAVLINK
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
|
2019-06-19 08:26:19 -03:00
|
|
|
using GCS_MAVLINK::GCS_MAVLINK;
|
|
|
|
|
2016-05-27 10:04:55 -03:00
|
|
|
protected:
|
|
|
|
|
2016-05-29 21:08:46 -03:00
|
|
|
uint32_t telem_delay() const override;
|
|
|
|
|
2017-07-12 04:42:48 -03:00
|
|
|
uint8_t sysid_my_gcs() const override;
|
2018-12-13 19:12:34 -04:00
|
|
|
bool sysid_enforce() const override;
|
2017-07-12 04:42:48 -03:00
|
|
|
|
2018-03-17 05:19:30 -03:00
|
|
|
MAV_RESULT _handle_command_preflight_calibration(const mavlink_command_long_t &packet) override;
|
2018-07-03 23:38:22 -03:00
|
|
|
MAV_RESULT handle_command_int_packet(const mavlink_command_int_t &packet) override;
|
2018-07-03 23:32:04 -03:00
|
|
|
MAV_RESULT handle_command_long_packet(const mavlink_command_long_t &packet) override;
|
2020-09-07 09:17:50 -03:00
|
|
|
MAV_RESULT handle_command_int_do_reposition(const mavlink_command_int_t &packet);
|
2018-03-17 05:19:30 -03:00
|
|
|
|
2019-05-17 03:53:39 -03:00
|
|
|
void send_position_target_global_int() override;
|
|
|
|
|
2018-05-21 09:34:58 -03:00
|
|
|
bool persist_streamrates() const override { return true; }
|
|
|
|
|
2018-07-05 22:34:29 -03:00
|
|
|
bool set_home_to_current_location(bool lock) override;
|
|
|
|
bool set_home(const Location& loc, bool lock) override;
|
2018-03-28 22:02:36 -03:00
|
|
|
uint64_t capabilities() const override;
|
2018-07-05 22:34:29 -03:00
|
|
|
|
2018-05-04 21:09:34 -03:00
|
|
|
void send_nav_controller_output() const override;
|
2019-02-28 19:31:59 -04:00
|
|
|
void send_pid_tuning() override;
|
2018-05-04 21:09:34 -03:00
|
|
|
|
2016-05-27 10:04:55 -03:00
|
|
|
private:
|
|
|
|
|
2019-04-30 07:22:50 -03:00
|
|
|
void handleMessage(const mavlink_message_t &msg) override;
|
2016-05-27 10:04:55 -03:00
|
|
|
bool handle_guided_request(AP_Mission::Mission_Command &cmd) override;
|
|
|
|
void handle_change_alt_request(AP_Mission::Mission_Command &cmd) override;
|
|
|
|
bool try_send_message(enum ap_message id) override;
|
2018-03-22 06:21:07 -03:00
|
|
|
|
2021-01-04 00:46:45 -04:00
|
|
|
void handle_manual_control(const mavlink_message_t &msg);
|
|
|
|
void handle_set_attitude_target(const mavlink_message_t &msg);
|
|
|
|
void handle_set_position_target_local_ned(const mavlink_message_t &msg);
|
|
|
|
void handle_set_position_target_global_int(const mavlink_message_t &msg);
|
|
|
|
void handle_radio(const mavlink_message_t &msg);
|
|
|
|
|
2021-08-24 11:18:45 -03:00
|
|
|
void send_servo_out();
|
|
|
|
|
2019-04-30 07:22:50 -03:00
|
|
|
void packetReceived(const mavlink_status_t &status, const mavlink_message_t &msg) override;
|
2018-07-07 02:12:45 -03:00
|
|
|
|
2018-03-22 06:21:07 -03:00
|
|
|
MAV_MODE base_mode() const override;
|
2019-11-25 22:46:07 -04:00
|
|
|
MAV_STATE vehicle_system_status() const override;
|
2018-01-30 22:11:27 -04:00
|
|
|
|
|
|
|
int16_t vfr_hud_throttle() const override;
|
|
|
|
|
2018-12-18 06:47:19 -04:00
|
|
|
void send_rangefinder() const override;
|
|
|
|
|
2021-07-06 07:53:38 -03:00
|
|
|
#if HAL_HIGH_LATENCY2_ENABLED
|
|
|
|
uint8_t high_latency_tgt_heading() const override;
|
|
|
|
uint16_t high_latency_tgt_dist() const override;
|
|
|
|
uint8_t high_latency_tgt_airspeed() const override;
|
|
|
|
uint8_t high_latency_wind_speed() const override;
|
|
|
|
uint8_t high_latency_wind_direction() const override;
|
|
|
|
#endif // HAL_HIGH_LATENCY2_ENABLED
|
2016-05-27 10:04:55 -03:00
|
|
|
};
|