SICKAG / sick_scan_xd

A versatile driver for a wide range of SICK LiDAR and RADAR devices, providing support for both Linux (native, ROS 1, ROS 2) and Windows (native, ROS 2) platforms.
Apache License 2.0
110 stars 86 forks source link

could not get this data through the msg_fields_buffer.name #412

Closed Jonny0816 closed 2 weeks ago

Jonny0816 commented 3 weeks ago

Dear Sir

A customer use driver under unbantu without ros for picoScan150. They feedback just can get the intensity data through the msg_fields_buffer[n]. name and without others data. Such as: fields_offset_rang:-1 fields_offset_azimuth:-1 fields_offset_elevation:-1 fields_offset_intensity:12 fields_offset_t:-1 Please help to check what is the reason and how to deal with it, Thanks.

rostest commented 3 weeks ago

Thank you for your feedback. I think this is the same problem as in the https://github.com/SICKAG/sick_scan_xd/issues/410#issuecomment-2443725824 issue. Otherwise, please post more information, i.e. which API functions, parameters and callbacks your customer is using.

The customer can get the range,azimuth,elevation,i fields by registering a polar point cloud callback. Function SickScanApiRegisterCartesianPointCloudMsg registers for cartesian point clouds with the fields x,y,z,i; function SickScanApiRegisterPolarPointCloudMsg registers for polar point clouds with the fields azimuth,elevation,range,i. Simply replace SickScanApiRegisterCartesianPointCloudMsg(apiHandle, customizedPointCloudMsgCb) with SickScanApiRegisterPolarPointCloudMsg(apiHandle, customizedPointCloudMsgCb) in the code and the callback should get azimuth,elevation,range,i.

See the Generic Driver API for examples and details.