1 # Copyright (c) 2019-2020, NVIDIA CORPORATION. All rights reserved.
3 @page lidar_usecase1 Get Decoded Data
5 @note SW Release Applicability: This tutorial is applicable to modules in both **NVIDIA DriveWorks** and **NVIDIA DRIVE Software** releases.
7 #### Get decoded lidar packet from live lidar sensor
10 dwSAL_initialize(&sal, sdk);
12 dwSensorHandle_t lidarSensor = DW_NULL_HANDLE;
13 dwSensorParams params;
14 params.parameters = "ip=192.168.3.43,port=2368,device=VELO_HDL64E,scan-frequency=10.0";
15 params.protocol = "lidar.socket";
16 dwSAL_createSensor(&lidarSensor, params, sal);
20 // query lidar properties
21 dwLidarProperties lidarProperties;
22 dwSensorLidar_getProperties(&lidarProperties, lidarSensor);
25 dwSensorLidar_readPacket(...);
27 // CODE: use the lidar packets for other tasks
29 dwSensorLidar_returnPacket(...);
33 dwSAL_releaseSensor(&lidarSensor);
37 #### Get decoded lidar packet from lidar recordings
40 dwSAL_initialize(&sal, sdk);
42 dwSensorHandle_t lidarSensor = DW_NULL_HANDLE;
43 dwSensorParams params;
44 params.parameters = "file=lidar_recording.bin";
45 params.protocol = "lidar.virtual";
46 dwSAL_createSensor(&lidarSensor, params, sal);
50 // query lidar properties
51 dwLidarProperties lidarProperties;
52 dwSensorLidar_getProperties(&lidarProperties, lidarSensor);
55 dwSensorLidar_readPacket(...);
57 // CODE: use the lidar packets for other tasks
59 dwSensorLidar_returnPacket(...);
63 dwSAL_releaseSensor(&lidarSensor);
67 For more details see @ref dwx_lidar_replay_sample