diff options
author | Thomas Gubler <thomasgubler@gmail.com> | 2014-05-30 14:37:23 +0200 |
---|---|---|
committer | Thomas Gubler <thomasgubler@gmail.com> | 2014-05-30 14:41:35 +0200 |
commit | 718206bd6d4103d8d2b1ad6a111770f65622029a (patch) | |
tree | 5a94774bdc37f1fa3ef56feec1d4262c589294b7 /src/drivers/gps/ubx.cpp | |
parent | 861249d571dbe0d7b7c4e45ca5d18b343e90866c (diff) | |
download | px4-firmware-718206bd6d4103d8d2b1ad6a111770f65622029a.tar.gz px4-firmware-718206bd6d4103d8d2b1ad6a111770f65622029a.tar.bz2 px4-firmware-718206bd6d4103d8d2b1ad6a111770f65622029a.zip |
ubx driver: fix unit of speed and position accuracy estimate
Diffstat (limited to 'src/drivers/gps/ubx.cpp')
-rw-r--r-- | src/drivers/gps/ubx.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/drivers/gps/ubx.cpp b/src/drivers/gps/ubx.cpp index 19cf5beec..7502809bd 100644 --- a/src/drivers/gps/ubx.cpp +++ b/src/drivers/gps/ubx.cpp @@ -447,8 +447,8 @@ UBX::handle_message() gps_bin_nav_sol_packet_t *packet = (gps_bin_nav_sol_packet_t *) _rx_buffer; _gps_position->fix_type = packet->gpsFix; - _gps_position->s_variance_m_s = packet->sAcc; - _gps_position->p_variance_m = packet->pAcc; + _gps_position->s_variance_m_s = (float)packet->sAcc * 1e-2f; // from cm/s to m/s + _gps_position->p_variance_m = (float)packet->pAcc * 1e-2f; // from cm to m _gps_position->timestamp_variance = hrt_absolute_time(); ret = 1; |