PepperlFuchs / pf_lidar_ros_driver

ROS driver for Pepperl+Fuchs R2000 and R2300 laser scanners
https://www.pepperl-fuchs.com/global/en/23097.htm
Apache License 2.0
37 stars 37 forks source link

the time stamp of r2000 #97

Closed dlutjwh closed 1 year ago

dlutjwh commented 1 year ago

hi, i used the https://github.com/dillenberger/pepperl_fuchs ros driver, and adpted the code to ros2, and set the freq 15hz, but i find the time increment between continuous scans is not stable at 0.067s(15Hz), it is jumping. i'm confused of it. thanks. i guess there is a delay in ros::now(),which the code set it as our laserscan timestamp. but i donot know why. is it related to the TCP,which old code use?

ros2 topic echo /sensor/lidar/front |grep "nan" return: nanosec: 318257440 nanosec: 351830200 nanosec: 443586160 nanosec: 507178640 nanosec: 575243960 nanosec: 642684760 nanosec: 711937880 nanosec: 774544320 nanosec: 812977520 nanosec: 910250320 nanosec: 946705240 nanosec: 41409120 nanosec: 75564240 nanosec: 178305840 nanosec: 212612680 nanosec: 313216520 nanosec: 376459200 nanosec: 446580800 nanosec: 514330840 nanosec: 590611800 nanosec: 645330520 nanosec: 681103960 nanosec: 775655080 nanosec: 815243520