0
$\begingroup$

Rosanswers logo

Hello everyone,

I am trying to convert a raw Velodyne VLP16 .pcap file to Rosbag but I am getting stuck in the first step. Basically, I run the following command:

$ roslaunch velodyne_pointcloud VLP16_points.launch pcap:=$(pwd)/velodyne_lidar.pcap readonce:=true

Then when I try to see the published information at /velodyne_points "rostopic echo /velodyne_points" is not printing anything. I am getting the following warning --> Error -2 reading Velodyne packet

Picture

Has anyone ever experienced this issue? Thanks in advance.


Originally posted by risc-v on ROS Answers with karma: 1 on 2021-09-22

Post score: 0


Original comments

Comment by Mike Scheutzow on 2021-09-23:
If you try this command using your own filename, do you see any messages on /scan?

rosrun velodyne_driver velodyne_node _pcap:=dump.pcap

Note: this is rosrun, not roslaunch, so the underscore in front of pcap indicates it's a private parameter, not a topic name remap.

Comment by risc-v on 2021-09-23:
Hi Mike,

Thanks very much for your reply. I tried the command you suggested but I am still getting the same error --> [ WARN] [1632399476.053965374]: Error -2 reading Velodyne packet.

I tried other .pcap files from the internet and they work perfectly meaning that I see data output on /velodyne_points. I tried to filter packets on the .pcap files giving me the -2 error (I used Wireshark for that, mainly keeping UDP packets), but still not working and giving the same error. Any ideas? Thanks in advance.

Comment by Mike Scheutzow on 2021-09-23:
Sounds like it is that specific pcap file. In wireshark, I would check the destination port number in the udp header. I believe the driver expects it to be 2368. If your file has something different, you have to specify it on the command line.

Comment by risc-v on 2021-09-24:
Hi Mike,

That worked perfectly Thanks very much. Really appreciate it :)

$\endgroup$

1 Answer 1

0
$\begingroup$

Rosanswers logo

Sounds like this problem is specific to one pcap file. In wireshark, I would check the destination port number in the udp header. I believe the driver expects it to be 2368. If your file has something different, you have to specify it on the command line.

I guess we now know that -2 means "no data packets found".


Originally posted by Mike Scheutzow with karma: 4903 on 2021-09-24

This answer was ACCEPTED on the original site

Post score: 1


Original comments

Comment by risc-v on 2021-09-24:
Hi Mike,

That's great. Changing the port number on the command line worked like a charm. All packets are visible now. Thanks again. Really appreciate it :)

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.