mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-01-18 06:38:29 -04:00
AP_GPS: Fix novatel driver to handle DOP correctly, and fix overly optimistic horizontal accuracy estimate
This commit is contained in:
parent
812128125b
commit
6b0dd7e689
@ -59,13 +59,11 @@ AP_GPS_NOVA::AP_GPS_NOVA(AP_GPS &_gps, AP_GPS::GPS_State &_state,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
const char* const AP_GPS_NOVA::_initialisation_blob[6] {
|
const char* const AP_GPS_NOVA::_initialisation_blob[4] {
|
||||||
"\r\n\r\nunlogall\r\n", // cleanup enviroment
|
"\r\n\r\nunlogall\r\n", // cleanup enviroment
|
||||||
"log bestposb ontime 0.2 0 nohold\r\n", // get bestpos
|
"log bestposb ontime 0.2 0 nohold\r\n",
|
||||||
"log bestvelb ontime 0.2 0 nohold\r\n", // get bestvel
|
"log bestvelb ontime 0.2 0 nohold\r\n",
|
||||||
"log psrdopb onchanged\r\n", // tersus
|
"log psrdopb ontime 0.2 0 nohold\r\n",
|
||||||
"log psrdopb ontime 0.2\r\n", // comnav
|
|
||||||
"log psrdopb\r\n" // poll message, as dop only changes when a sat is dropped/added to the visible list
|
|
||||||
};
|
};
|
||||||
|
|
||||||
// Process all bytes available from the stream
|
// Process all bytes available from the stream
|
||||||
@ -213,7 +211,7 @@ AP_GPS_NOVA::process_message(void)
|
|||||||
|
|
||||||
state.num_sats = bestposu.svsused;
|
state.num_sats = bestposu.svsused;
|
||||||
|
|
||||||
state.horizontal_accuracy = (float) ((bestposu.latsdev + bestposu.lngsdev)/2);
|
state.horizontal_accuracy = norm(bestposu.latsdev, bestposu.lngsdev);
|
||||||
state.vertical_accuracy = (float) bestposu.hgtsdev;
|
state.vertical_accuracy = (float) bestposu.hgtsdev;
|
||||||
state.have_horizontal_accuracy = true;
|
state.have_horizontal_accuracy = true;
|
||||||
state.have_vertical_accuracy = true;
|
state.have_vertical_accuracy = true;
|
||||||
|
@ -55,7 +55,7 @@ private:
|
|||||||
|
|
||||||
uint8_t _init_blob_index = 0;
|
uint8_t _init_blob_index = 0;
|
||||||
uint32_t _init_blob_time = 0;
|
uint32_t _init_blob_time = 0;
|
||||||
static const char* const _initialisation_blob[6];
|
static const char* const _initialisation_blob[4];
|
||||||
|
|
||||||
uint32_t crc_error_counter = 0;
|
uint32_t crc_error_counter = 0;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user