Browse Source

Plane: move high_latency_air_temperature up

gps-1.3.1
Josh Henderson 3 years ago committed by Andrew Tridgell
parent
commit
9a3fed0263
  1. 12
      ArduPlane/GCS_Mavlink.cpp
  2. 1
      ArduPlane/GCS_Mavlink.h

12
ArduPlane/GCS_Mavlink.cpp

@ -1404,18 +1404,6 @@ uint8_t GCS_MAVLINK_Plane::high_latency_wind_direction() const @@ -1404,18 +1404,6 @@ uint8_t GCS_MAVLINK_Plane::high_latency_wind_direction() const
// need to convert -180->180 to 0->360/2
return wrap_360(degrees(atan2f(-wind.y, -wind.x))) / 2;
}
int8_t GCS_MAVLINK_Plane::high_latency_air_temperature() const
{
// return units are degC
AP_Airspeed *airspeed = AP_Airspeed::get_singleton();
float air_temperature;
if (airspeed != nullptr && airspeed->enabled() && airspeed->get_temperature(air_temperature)) {
return air_temperature;
}
return INT8_MIN;
}
#endif // HAL_HIGH_LATENCY2_ENABLED
MAV_VTOL_STATE GCS_MAVLINK_Plane::vtol_state() const

1
ArduPlane/GCS_Mavlink.h

@ -69,7 +69,6 @@ private: @@ -69,7 +69,6 @@ private:
uint8_t high_latency_tgt_airspeed() const override;
uint8_t high_latency_wind_speed() const override;
uint8_t high_latency_wind_direction() const override;
int8_t high_latency_air_temperature() const override;
#endif // HAL_HIGH_LATENCY2_ENABLED
MAV_VTOL_STATE vtol_state() const override;

Loading…
Cancel
Save