DriveWorks SDK Reference
3.5.78 Release
For Test and Development only

GPS.h
Go to the documentation of this file.
1 // This code contains NVIDIA Confidential Information and is disclosed
3 // under the Mutual Non-Disclosure Agreement.
4 //
5 // Notice
6 // ALL NVIDIA DESIGN SPECIFICATIONS AND CODE ("MATERIALS") ARE PROVIDED "AS IS" NVIDIA MAKES
7 // NO REPRESENTATIONS, WARRANTIES, EXPRESSED, IMPLIED, STATUTORY, OR OTHERWISE WITH RESPECT TO
8 // THE MATERIALS, AND EXPRESSLY DISCLAIMS ANY IMPLIED WARRANTIES OF NONINFRINGEMENT,
9 // MERCHANTABILITY, OR FITNESS FOR A PARTICULAR PURPOSE.
10 //
11 // NVIDIA Corporation assumes no responsibility for the consequences of use of such
12 // information or for any infringement of patents or other rights of third parties that may
13 // result from its use. No license is granted by implication or otherwise under any patent
14 // or patent rights of NVIDIA Corporation. No third party distribution is allowed unless
15 // expressly authorized by NVIDIA. Details are subject to change without notice.
16 // This code supersedes and replaces all information previously supplied.
17 // NVIDIA Corporation products are not authorized for use as critical
18 // components in life support devices or systems without express written approval of
19 // NVIDIA Corporation.
20 //
21 // Copyright (c) 2016-2020 NVIDIA Corporation. All rights reserved.
22 //
23 // NVIDIA Corporation and its licensors retain all intellectual property and proprietary
24 // rights in and to this software and related documentation and any modifications thereto.
25 // Any use, reproduction, disclosure or distribution of this software and related
26 // documentation without an express license agreement from NVIDIA Corporation is
27 // strictly prohibited.
28 //
30 
49 #ifndef DW_SENSORS_GPS_GPS_H_
50 #define DW_SENSORS_GPS_GPS_H_
51 
52 #include <dw/core/Config.h>
53 #include <dw/core/Exports.h>
54 #include <dw/core/Types.h>
55 
56 #include <dw/sensors/Sensors.h>
57 
58 #ifdef __cplusplus
59 extern "C" {
60 #endif
61 
63 typedef enum dwGPSFlags {
64  DW_GPS_LAT = 1 << 0,
65  DW_GPS_LON = 1 << 1,
66  DW_GPS_ALT = 1 << 2,
67  DW_GPS_COURSE = 1 << 3,
68  DW_GPS_SPEED = 1 << 4,
69  DW_GPS_CLIMB = 1 << 5,
70  DW_GPS_HDOP = 1 << 6,
71  DW_GPS_VDOP = 1 << 7,
72  DW_GPS_HACC = 1 << 8,
73  DW_GPS_VACC = 1 << 9,
74 } dwGPSFlags;
75 
80 typedef struct dwGPSFrame
81 {
84 
87 
90 
93 
96 
99 
102 
104  char utcTime[16];
105 
107  char utcDate[16];
108 
111 
114 
117 
120 
122  uint32_t flags;
123 
124 } dwGPSFrame;
125 
145 
161 dwStatus dwSensorGPS_processRawData(const uint8_t* data, size_t size, dwSensorHandle_t sensor);
162 
177 
178 #ifdef __cplusplus
179 }
180 #endif
181 
182 #endif // DW_SENSORS_GPS_GPS_H_
char utcTime[16]
UTC time as provided in the GPS package [hhmmss.sss] (null terminated).
Definition: GPS.h:104
Value of dwGPSFrame.longitude is valid.
Definition: GPS.h:65
float64_t vdop
Vertical dilution of precision (VDOP).
Definition: GPS.h:113
NVIDIA DriveWorks API: Core Types
Value of dwGPSFrame.latitude is valid.
Definition: GPS.h:64
Value of dwGPSFrame.vdop is valid.
Definition: GPS.h:71
float64_t latitude
Latitude [degree].
Definition: GPS.h:86
char utcDate[16]
UTC date as provided in the GPS package [ddmmyy] (null terminated).
Definition: GPS.h:107
Value of dwGPSFrame.speed is valid.
Definition: GPS.h:68
float64_t hacc
Horizontal accuracy [m].
Definition: GPS.h:116
double float64_t
Definition: Types.h:71
Value of dwGPSFrame.course is valid.
Definition: GPS.h:67
struct dwSensorObject * dwSensorHandle_t
Handle representing a sensor.
Definition: Sensors.h:88
dwStatus
Status definition.
Definition: Status.h:178
NVIDIA DriveWorks API: Sensors
Value of dwGPSFrame.climb is valid.
Definition: GPS.h:69
int64_t dwTime_t
Specifies a timestamp unit, in microseconds.
Definition: Types.h:82
DW_API_PUBLIC dwStatus dwSensorGPS_processRawData(const uint8_t *data, size_t size, dwSensorHandle_t sensor)
Decodes RAW data previously read.
Value of dwGPSFrame.altitude is valid.
Definition: GPS.h:66
DW_API_PUBLIC dwStatus dwSensorGPS_popFrame(dwGPSFrame *frame, dwSensorHandle_t sensor)
Returns any GPS frame previously processed through RAW data stream.
float64_t course
Course relative to true north [degree].
Definition: GPS.h:95
Value of dwGPSFrame.hdop is valid.
Definition: GPS.h:70
float64_t altitude
Altitude over WGS84 ellipsoid [m].
Definition: GPS.h:92
float64_t climb
Vertical speed [m/s].
Definition: GPS.h:101
dwTime_t timestamp_us
Timestamp of the message when first received [usec].
Definition: GPS.h:83
uint32_t flags
The flags to show which values are valid in this GPS frame.
Definition: GPS.h:122
dwGPSFlags
Each flag shows if that value is valid in this GPS frame.
Definition: GPS.h:63
Value of dwGPSFrame.vacc is valid.
Definition: GPS.h:73
float64_t speed
Horizontal speed [m/s].
Definition: GPS.h:98
float64_t hdop
Horizontal dilution of precision (HDOP).
Definition: GPS.h:110
NVIDIA DriveWorks API: Core Exports
DW_API_PUBLIC dwStatus dwSensorGPS_readFrame(dwGPSFrame *frame, dwTime_t timeout_us, dwSensorHandle_t sensor)
Reads the next GPS packet with a given timeout.
float64_t longitude
Longitude [degree].
Definition: GPS.h:89
Value of dwGPSFrame.hacc is valid.
Definition: GPS.h:72
#define DW_API_PUBLIC
Definition: Exports.h:56
float64_t vacc
Vertical accuracy [m].
Definition: GPS.h:119
A GPS packet containing localization information.
Definition: GPS.h:80