Reverted change to speed reporting.
This commit is contained in:
parent
e88eba1009
commit
ccb155fc8e
|
@ -78,7 +78,6 @@
|
||||||
|
|
||||||
#include "flight/pid.h"
|
#include "flight/pid.h"
|
||||||
#include "flight/navigation.h"
|
#include "flight/navigation.h"
|
||||||
#include "flight/altitudehold.h"
|
|
||||||
#include "io/gps.h"
|
#include "io/gps.h"
|
||||||
|
|
||||||
#include "telemetry/telemetry.h"
|
#include "telemetry/telemetry.h"
|
||||||
|
@ -196,13 +195,8 @@ void hottPrepareGPSResponse(HOTT_GPS_MSG_t *hottGPSMessage)
|
||||||
|
|
||||||
addGPSCoordinates(hottGPSMessage, GPS_coord[LAT], GPS_coord[LON]);
|
addGPSCoordinates(hottGPSMessage, GPS_coord[LAT], GPS_coord[LON]);
|
||||||
|
|
||||||
uint16_t speed = GPS_speed;
|
// GPS Speed is returned in cm/s (from io/gps.c) and must be sent in km/h (Hott requirement)
|
||||||
if (!STATE(GPS_FIX)) {
|
const uint16_t speed = (GPS_speed * 36) / 1000;
|
||||||
speed = vario;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Speed is returned in cm/s and must be sent in km/h (Hott requirement)
|
|
||||||
speed = (speed * 36) / 1000;
|
|
||||||
hottGPSMessage->gps_speed_L = speed & 0x00FF;
|
hottGPSMessage->gps_speed_L = speed & 0x00FF;
|
||||||
hottGPSMessage->gps_speed_H = speed >> 8;
|
hottGPSMessage->gps_speed_H = speed >> 8;
|
||||||
|
|
||||||
|
|
|
@ -174,7 +174,6 @@ int32_t mAhDrawn;
|
||||||
uint32_t fixedMillis = 0;
|
uint32_t fixedMillis = 0;
|
||||||
|
|
||||||
baro_t baro;
|
baro_t baro;
|
||||||
uint16_t vario;
|
|
||||||
|
|
||||||
uint32_t millis(void) {
|
uint32_t millis(void) {
|
||||||
return fixedMillis;
|
return fixedMillis;
|
||||||
|
|
Loading…
Reference in New Issue