![]() |
DriveWorks SDK Reference| 0.6.67 Release |
Defines the GPS sensor.
Data Structures | |
struct | dwGPSFrame |
A GPS packet containing localization information. More... | |
Functions | |
DW_API_PUBLIC dwStatus | dwSensorGPS_popFrame (dwGPSFrame *frame, dwSensorHandle_t sensor) |
Returns any GPS frame previously processed through RAW data stream. More... | |
DW_API_PUBLIC dwStatus | dwSensorGPS_processRawData (const uint8_t *data, size_t size, dwSensorHandle_t sensor) |
Decodes RAW data previously read. More... | |
DW_API_PUBLIC dwStatus | dwSensorGPS_readFrame (dwGPSFrame *frame, dwTime_t timeout_us, dwSensorHandle_t sensor) |
Reads the next GPS packet with a given timeout. More... | |
struct dwGPSFrame |
Data Fields | ||
---|---|---|
float64_t | altitude | Altitude in m over see level as reported by the GPS sensor, represented following WGS84. |
float64_t | climb | Vertical speed in m/s. |
float64_t | course | Course relative to true north in degrees. |
float64_t | hdop | Horizontal dilution of precision (HDOP) |
float64_t | latitude | Latitude in degrees. |
float64_t | longitude | Longitude in degrees. |
float64_t | speed | Horizontal speed in m/s. |
dwTime_t | timestamp_us | Timestamp of the message when first received [usec]. |
char | utcDate[16] | UTC date as provided in the GPS package [ddmmyy] (null terminated). |
char | utcTime[16] | UTC time as provided in the GPS package [hhmmss.sss] (null terminated). |
float64_t | vdop | Vertical dilution of precision (VDOP) |
DW_API_PUBLIC dwStatus dwSensorGPS_popFrame | ( | dwGPSFrame * | frame, |
dwSensorHandle_t | sensor | ||
) |
Returns any GPS frame previously processed through RAW data stream.
This happens on the CPU thread where the function is called, incurring on additional load on that thread.
[out] | frame | Container for the decoded frame. |
[in] | sensor | Sensor handle of the sensor previously created with dwSAL_createSensor() . |
DW_API_PUBLIC dwStatus dwSensorGPS_processRawData | ( | const uint8_t * | data, |
size_t | size, | ||
dwSensorHandle_t | sensor | ||
) |
Decodes RAW data previously read.
This happens on the CPU thread where the function is called, incurring on additional load on that thread.
[in] | data | Undecoded gps data. |
[in] | size | Size in bytes of the raw data. |
[in] | sensor | Sensor handle of the sensor previously created with dwSAL_createSensor() . |
DW_NOT_READY
). DW_API_PUBLIC dwStatus dwSensorGPS_readFrame | ( | dwGPSFrame * | frame, |
dwTime_t | timeout_us, | ||
dwSensorHandle_t | sensor | ||
) |
Reads the next GPS packet with a given timeout.
The method blocks until either a new valid frame is received from the sensor or the given timeout exceeds.
[out] | frame | A pointer to a GPS frame structure to be filled with new localization data. |
[in] | timeout_us | Specifies the timeout in us to wait for a new message. Special values: DW_TIMEOUT_INFINITE - to wait infinitly. Zero - means polling of internal queue. |
[in] | sensor | Specifies the sensor handle of the GPS sensor previously created with dwSAL_createSensor() . |