DriveWorks SDK Reference
3.0.4260 Release
For Test and Development only

Radar.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) 2017-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_RADAR_RADAR_H_
50 #define DW_SENSORS_RADAR_RADAR_H_
51 
52 #include <dw/core/Config.h>
53 #include <dw/core/Types.h>
54 
55 #include <dw/sensors/Sensors.h>
56 
58 typedef enum {
61 
64 
67 
70 
73 } dwRadarRange;
74 
76 typedef enum {
79 
82 
85 
89 
91 typedef enum {
94 
97 
100 
103 
106 
110 
112 typedef struct dwRadarScanType
113 {
116 
120 
122 #pragma pack(push, 1)
123 
125 typedef struct dwRadarDetection
126 {
129 
132 
135 
138 
141 
144 
147 
150 
153 
156 
159 
162 
166 
167 typedef struct dwRadarTrack
168 {
170  uint32_t id;
171 
173  uint32_t age;
174 
177 
180 
183 
186 
189 
192 
195 
198 
201 
204 
207 
210 
213 
216 
219 
222 } dwRadarTrack;
223 
225 typedef struct dwRadarScan
226 {
228  uint32_t scanIndex;
229 
232 
235 
238 
240  uint32_t numReturns;
241 
244 
246  void* data;
247 } dwRadarScan;
248 
249 #pragma pack(pop)
250 
252 typedef struct dwRadarStatus
253 {
256 
259 
262 
265 
268 
271 
272  /*
273  * Deviation of azimuth angle for returns (radians)
274  * This is the deviation of the measured azimuth from what would be
275  * expected based on the geometric boresight of the sensor.
276  */
277  float32_t azimuthDeviation[DW_RADAR_RANGE_COUNT];
278 
279  /*
280  * Deviation of elevation angle for returns (radians)
281  * This is the deviation of the elevation azimuth from what would be
282  * expected based on the geometric boresight of the sensor.
283  */
284  float32_t elevationDeviation[DW_RADAR_RANGE_COUNT];
285 
288 
290  bool sensorOK;
291 
294 
297 } dwRadarStatus;
298 
300 typedef struct dwRadarVehicleState
301 {
304 
307 
310 
314 
316 typedef struct dwRadarMountPosition
317 {
319  uint32_t sensorId;
320 
323 
326 
329 
333 
335 typedef struct dwRadarProperties
336 {
338  uint8_t isDecodingOn;
339 
341  uint32_t numScanTypes;
342 
344  uint32_t supportedScanTypes[DW_RADAR_RETURN_TYPE_COUNT][DW_RADAR_RANGE_COUNT];
345 
347  uint32_t packetsPerScan;
348 
350  uint32_t maxReturnsPerScan[DW_RADAR_RETURN_TYPE_COUNT][DW_RADAR_RANGE_COUNT];
351 
357  uint32_t scansPerSecond;
358 
362 
363 #ifdef __cplusplus
364 extern "C" {
365 #endif
366 
380 
393 
413  const dwTime_t timeout_us, dwSensorHandle_t sensor);
426 
445  const dwTime_t timeout_us, dwSensorHandle_t sensor);
446 
459 
474 dwStatus dwSensorRadar_processRawData(const dwRadarScan** data, const uint8_t* rawData, size_t size,
475  dwSensorHandle_t sensor);
476 
488 
500 
512 
513 #ifdef __cplusplus
514 }
515 #endif
516 
518 #endif // DW_SENSORS_RADAR_RADAR_H_
float32_t rcs
Compensated reflection amplitude (dB)
Definition: Radar.h:218
float32_t Ax
X-component (m/s^2) of the acceleration.
Definition: Radar.h:197
uint32_t numScanTypes
Number of supported scan types.
Definition: Radar.h:341
float32_t dopplerAmbiguity
Doppler ambiguity free range.
Definition: Radar.h:243
float32_t acceleration
Longitudinal acceleration (m/s^2)
Definition: Radar.h:306
float32_t Ay
Y-component (m/s^2) of the aceleration in the azimuth direction.
Definition: Radar.h:143
float32_t radius
Radial distance (m)
Definition: Radar.h:149
dwRadarScanType scanType
Type of scan.
Definition: Radar.h:237
DW_API_PUBLIC dwStatus dwSensorRadar_returnData(const dwRadarScan *scan, dwSensorHandle_t sensor)
Returns the data read to the internal pool.
float32_t yaw
Yaw angle of sensor (radians)
Definition: Radar.h:264
Short Range.
Definition: Radar.h:60
float32_t radialVelocity
Radial velocity (m/s)
Definition: Radar.h:212
float32_t x
X-position (m)
Definition: Radar.h:128
NVIDIA DriveWorks API: Core Types
Defines the structure for reporting sensor mount position.
Definition: Radar.h:316
Defines the structure for a complete radar scan.
Definition: Radar.h:225
float float32_t
Specifies POD types.
Definition: Types.h:70
uint8_t isDecodingOn
Indicates whether decoding is enabled.
Definition: Radar.h:338
dwRadarReturnType returnType
Type of radar return.
Definition: Radar.h:115
Processed tracker output.
Definition: Radar.h:81
dwRadarRange range
Scan range.
Definition: Radar.h:118
bool sensorAligned
Indicates if the sensor is aligned.
Definition: Radar.h:287
DW_API_PUBLIC dwStatus dwSensorRadar_setVehicleState(dwRadarVehicleState *data, dwSensorHandle_t sensor)
Sends vehicle dynamics information to the radar.
float32_t Vx
X-component (m/s) of the velocity.
Definition: Radar.h:191
float32_t Vx
X-component (m/s) of the velocity in the azimuth direction.
Definition: Radar.h:134
bool sensorOK
Indicaes if the is OK.
Definition: Radar.h:290
float32_t y
Y-position (m)
Definition: Radar.h:185
float32_t z
Z-position (m)
Definition: Radar.h:188
DW_API_PUBLIC dwStatus dwSensorRadar_readData(const dwRadarScan **data, const dwRadarScanType type, const dwTime_t timeout_us, dwSensorHandle_t sensor)
Reads a single packet, which might be an entire scan or a fraction of a scan, which is sensor depende...
dwRadarDynamicState dynamicState
Dynamic state of the object.
Definition: Radar.h:179
float32_t roll
Roll angle of sensor (radians)
Definition: Radar.h:270
float32_t wheelbase
Size of wheel-base (m)
Definition: Radar.h:325
float32_t x
X-position (m) of sensor mounting in AUTOSAR-coordinates from CoG.
Definition: Radar.h:255
float32_t Vy
Y-component (m/s) of the velocity in the azimuth direction.
Definition: Radar.h:137
float32_t radius
Radial distance (m)
Definition: Radar.h:209
float32_t Ay
Y-component (m/s^2) of the aceleration.
Definition: Radar.h:200
Stopped (was moving, now stationary)
Definition: Radar.h:105
Long Range.
Definition: Radar.h:66
Specifies a 3D rigid transformation.
Definition: Types.h:462
uint32_t id
Radar-provided track id.
Definition: Radar.h:170
float32_t damping
Damping of radome (db)
Definition: Radar.h:328
DW_API_PUBLIC dwStatus dwSensorRadar_getProperties(dwRadarProperties *radarProperties, dwSensorHandle_t sensor)
Gets information about the Radar sensor.
struct dwSensorObject * dwSensorHandle_t
Handle representing a sensor.
Definition: Sensors.h:88
float32_t Vy
Y-component (m/s) of the velocity.
Definition: Radar.h:194
uint32_t scanIndex
Sensor-provided scan index.
Definition: Radar.h:228
dwTime_t sensorTimestamp
Sensor timestamp for this scan (us)
Definition: Radar.h:231
dwStatus
Status definition.
Definition: Status.h:166
NVIDIA DriveWorks API: Sensors
uint32_t numReturns
Number of radar returns in this scan.
Definition: Radar.h:240
void * data
Pointer to the array of returns (to be casted based on return type)
Definition: Radar.h:246
DW_API_PUBLIC dwStatus dwSensorRadar_readScan(const dwRadarScan **data, const dwTime_t timeout_us, dwSensorHandle_t sensor)
Reads a one scan chunk.
dwRadarDynamicState
Defines the dynamic state of the radar return.
Definition: Radar.h:91
Defines the type of scan (combination of return type & range)
Definition: Radar.h:112
Defines the return structure for sensor status messages.
Definition: Radar.h:252
float32_t radialVelocity
Radial velocity (m/s)
Definition: Radar.h:152
int64_t dwTime_t
Specifies a timestamp unit, in microseconds.
Definition: Types.h:82
DW_API_PUBLIC dwStatus dwSensorRadar_toggleScanType(bool enable, dwRadarScanType scanType, dwSensorHandle_t sensor)
Enables/Disables a scan type for the radar sensor.
float32_t azimuthRate
Rate of change of azimuth angle (radians/s)
Definition: Radar.h:206
DW_API_PUBLIC dwStatus dwSensorRadar_setMountPosition(dwRadarMountPosition *data, dwSensorHandle_t sensor)
Sends the radar mount position information to the radar.
bool sensorDisturbed
Indicates if the sensor is disturbed due to interference.
Definition: Radar.h:293
DW_API_PUBLIC dwStatus dwSensorRadar_setDataDecoding(bool enable, dwSensorHandle_t sensor)
Enables/disables the decoding of the Radar packets, which incurs in additional CPU load...
Defines the properties of the radar.
Definition: Radar.h:335
Unknown Range.
Definition: Radar.h:69
uint32_t packetsPerScan
of packets per scan (Note: will be deprecated soon)
Definition: Radar.h:347
Medium Range.
Definition: Radar.h:63
bool sensorBlock
Indicates if the sensor is blocked.
Definition: Radar.h:296
float32_t azimuth
Azimuth angle (radians)
Definition: Radar.h:203
dwRadarReturnType
Defines the type of radar return.
Definition: Radar.h:76
float32_t Ax
X-component (m/s^2) of the acceleration in the azimuth direction.
Definition: Radar.h:140
float32_t azimuth
Azimuth angle (radians)
Definition: Radar.h:146
float32_t radialAcceleration
Radial acceleration (m/s^2)
Definition: Radar.h:155
dwTransformation3f radarPosition
Radar position.
Definition: Radar.h:322
float32_t confidence
Confidence of object existence (range: 0-1);.
Definition: Radar.h:176
uint32_t inputPacketsPerSecond
Number of input odometry packets per second.
Definition: Radar.h:360
dwRadarRange
Defines the range of radar return.
Definition: Radar.h:58
DW_API_PUBLIC dwStatus dwSensorRadar_returnScan(const dwRadarScan *scan, dwSensorHandle_t sensor)
Returns the data covering an entire scan read to the internal pool.
uint32_t age
Age of tracked object (in scans)
Definition: Radar.h:173
float32_t y
Y-position (m)
Definition: Radar.h:131
float32_t x
X-position (m)
Definition: Radar.h:182
float32_t y
Y-position (m) of sensor mounting in AUTOSAR-coordinates from CoG.
Definition: Radar.h:258
float32_t pitch
Pitch angle of sensor (radians)
Definition: Radar.h:267
Defines the structure for reporting current vehicle dynamics state.
Definition: Radar.h:300
Sensor status information.
Definition: Radar.h:84
float32_t yawRate
Yaw rate (radians/s)
Definition: Radar.h:312
float32_t rcs
Reflection amplitude (dB)
Definition: Radar.h:158
float32_t radialAcceleration
Radial acceleration (m/s^2)
Definition: Radar.h:215
The structs below are serialized in binary and the layout is assummed to be packed.
Definition: Radar.h:125
uint32_t scansPerSecond
Number of scans (of a particular type) per second.
Definition: Radar.h:357
bool isReversed
Indicates if the sensor is reversed from its default orientation.
Definition: Radar.h:331
dwTime_t hostTimestamp
Host timestamp at reception of first packet belonging to this scan (us)
Definition: Radar.h:234
float32_t z
Z-position (m) of sensor mounting in AUTOSAR-coordinates from CoG.
Definition: Radar.h:261
#define DW_API_PUBLIC
Definition: Exports.h:56
bool elevationValid
Indicates validity of z position.
Definition: Radar.h:221
uint32_t sensorId
Id of the sensor (vendor-specific)
Definition: Radar.h:319
bool elevationValidity
Indicates validity of the elevation angle.
Definition: Radar.h:164
float32_t velocity
Longitudinal velocity (m/s)
Definition: Radar.h:303
DW_API_PUBLIC dwStatus dwSensorRadar_processRawData(const dwRadarScan **data, const uint8_t *rawData, size_t size, dwSensorHandle_t sensor)
Decodes RAW data previously read onto the application side structure.
float32_t lateralAcceleration
Lateral acceleration (m/s^2)
Definition: Radar.h:309
Raw detection.
Definition: Radar.h:78
float32_t elevationAngle
Angle of elevation (radians)
Definition: Radar.h:161