2017-02-13 21:30:32 -04:00
|
|
|
#include "GCS_Tracker.h"
|
|
|
|
#include "Tracker.h"
|
|
|
|
|
|
|
|
void GCS_Tracker::request_datastream_position(const uint8_t sysid, const uint8_t compid)
|
|
|
|
{
|
|
|
|
for (uint8_t i=0; i < num_gcs(); i++) {
|
|
|
|
// request position
|
|
|
|
if (HAVE_PAYLOAD_SPACE((mavlink_channel_t)i, DATA_STREAM)) {
|
|
|
|
mavlink_msg_request_data_stream_send(
|
|
|
|
(mavlink_channel_t)i,
|
|
|
|
sysid,
|
|
|
|
compid,
|
|
|
|
MAV_DATA_STREAM_POSITION,
|
|
|
|
tracker.g.mavlink_update_rate,
|
|
|
|
1); // start streaming
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
void GCS_Tracker::request_datastream_airpressure(const uint8_t sysid, const uint8_t compid)
|
|
|
|
{
|
|
|
|
for (uint8_t i=0; i < num_gcs(); i++) {
|
|
|
|
// request air pressure
|
|
|
|
if (HAVE_PAYLOAD_SPACE((mavlink_channel_t)i, DATA_STREAM)) {
|
|
|
|
mavlink_msg_request_data_stream_send(
|
|
|
|
(mavlink_channel_t)i,
|
|
|
|
sysid,
|
|
|
|
compid,
|
|
|
|
MAV_DATA_STREAM_RAW_SENSORS,
|
|
|
|
tracker.g.mavlink_update_rate,
|
|
|
|
1); // start streaming
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
2019-02-19 17:34:14 -04:00
|
|
|
|
|
|
|
// update sensors and subsystems present, enabled and healthy flags for reporting to GCS
|
2019-02-19 20:18:12 -04:00
|
|
|
void GCS_Tracker::update_vehicle_sensor_status_flags()
|
2019-02-19 17:34:14 -04:00
|
|
|
{
|
|
|
|
// default sensors present
|
2019-02-19 20:18:12 -04:00
|
|
|
control_sensors_present |=
|
|
|
|
MAV_SYS_STATUS_SENSOR_ANGULAR_RATE_CONTROL |
|
|
|
|
MAV_SYS_STATUS_SENSOR_ATTITUDE_STABILIZATION |
|
|
|
|
MAV_SYS_STATUS_SENSOR_YAW_POSITION;
|
|
|
|
|
|
|
|
control_sensors_enabled |=
|
|
|
|
MAV_SYS_STATUS_SENSOR_ANGULAR_RATE_CONTROL |
|
|
|
|
MAV_SYS_STATUS_SENSOR_ATTITUDE_STABILIZATION |
|
|
|
|
MAV_SYS_STATUS_SENSOR_YAW_POSITION;
|
|
|
|
|
|
|
|
control_sensors_health |=
|
|
|
|
MAV_SYS_STATUS_SENSOR_ANGULAR_RATE_CONTROL |
|
|
|
|
MAV_SYS_STATUS_SENSOR_ATTITUDE_STABILIZATION |
|
|
|
|
MAV_SYS_STATUS_SENSOR_YAW_POSITION;
|
2019-02-19 17:34:14 -04:00
|
|
|
}
|
2019-03-01 20:08:51 -04:00
|
|
|
|
2019-09-05 02:01:45 -03:00
|
|
|
// avoid building/linking LTM:
|
|
|
|
void AP_LTM_Telem::init() {};
|
2019-03-01 20:08:51 -04:00
|
|
|
// avoid building/linking Devo:
|
|
|
|
void AP_DEVO_Telem::init() {};
|