AP_ADSB: fix unit conversion

This commit is contained in:
Tom Pittenger 2015-12-10 08:43:16 -08:00 committed by Randy Mackay
parent 63e1d0753e
commit d003e24189
1 changed files with 1 additions and 1 deletions

View File

@ -175,7 +175,7 @@ void AP_ADSB::perform_threat_detection(void)
Location AP_ADSB::get_location(const adsb_vehicle_t &vehicle) const
{
Location loc {};
loc.alt = vehicle.info.altitude * 10; // convert mm to cm.
loc.alt = vehicle.info.altitude * 0.1f; // convert mm to cm.
loc.lat = vehicle.info.lat;
loc.lng = vehicle.info.lon;
loc.flags.relative_alt = false;