Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Revision 17:6c226e3e9d61, committed 2018-09-03
- Comitter:
- fahim.alavi@u-blox.com
- Date:
- Mon Sep 03 14:39:27 2018 +0500
- Parent:
- 16:cb9861f0f4d8
- Child:
- 18:7adca4350499
- Commit message:
- Set ground speed, fixType and avg_ignss
Changed in this revision
| gnss.cpp | Show annotated file Show diff for this revision Revisions of this file |
| gnss.h | Show annotated file Show diff for this revision Revisions of this file |
--- a/gnss.cpp Wed Aug 01 13:14:52 2018 +0500 +++ b/gnss.cpp Mon Sep 03 14:39:27 2018 +0500 @@ -436,6 +436,10 @@ return_decoded_msg.day = buf[index++]; + // Go to Fix type + index = UBX_PAYLOAD_INDEX + 20; + return_decoded_msg.fixType = buf[index]; + // Go to lon index = UBX_PAYLOAD_INDEX + 24; @@ -454,6 +458,13 @@ return_decoded_msg.height |= (buf[index++] << 16); return_decoded_msg.height |= (buf[index++] << 24); + // Go to gSpeed + index = UBX_PAYLOAD_INDEX + 60; + return_decoded_msg.speed = buf[index++]; + return_decoded_msg.speed |= (buf[index++] << 8); + return_decoded_msg.speed |= (buf[index++] << 16); + return_decoded_msg.speed |= (buf[index++] << 24); + return return_decoded_msg; }
--- a/gnss.h Wed Aug 01 13:14:52 2018 +0500 +++ b/gnss.h Mon Sep 03 14:39:27 2018 +0500 @@ -72,9 +72,11 @@ uint16_t year; uint8_t month; uint8_t day; + uint8_t fixType; int32_t lon; // scaling 1e-7 int32_t lat; // scaling 1e-7 int32_t height; + int32_t speed; }tUBX_NAV_PVT;