Hi Nicholas,
I tried your launch parameters setting in my raspberrypi+RPLidarA2. Also on my laptop and directly pluged the lidar, both setups work perfectly. Now, since I would like to visualize the RViz on my Ubuntu PC and run the sensor on RaspberryPi board, I did the ROS multiple machine setup just like described in this page: https://wiki.ros.org/ROS/Tutorials/MultipleMachines.
I started the roscore and roslaunch rplidar_ros rplidar.launch in my RaspberryPi board. I can see the laser scan data in my Ubuntu PC with rostopic echo scan. However, I cannot see the visualization on RViz. The console output of the hector_slam shows lookupTransform base_link to laser timed out. Could not transform laser scan into base_frame.
This is the rqt_graph output of the failed SLAM:
If hector_slam works in one machine, I get this graph:
Thus, somehow the node parameter setting <node pkg="tf" type="static_transform_publisher" name="base_to_laser_broadcaster" args="0 0 0 0 0 0 base_link laser 100" /> is for the setup with two machines not suitable. Based on the tf documentation, the arguments mean frame_id is base_link, and child_frame_id is laser.
Hi Nicholas, I tried your launch parameters setting in my raspberrypi+RPLidarA2. Also on my laptop and directly pluged the lidar, both setups work perfectly. Now, since I would like to visualize the RViz on my Ubuntu PC and run the sensor on RaspberryPi board, I did the ROS multiple machine setup just like described in this page: https://wiki.ros.org/ROS/Tutorials/MultipleMachines.
I started the
roscore
androslaunch rplidar_ros rplidar.launch
in my RaspberryPi board. I can see the laser scan data in my Ubuntu PC withrostopic echo scan
. However, I cannot see the visualization on RViz. The console output of the hector_slam showslookupTransform base_link to laser timed out. Could not transform laser scan into base_frame.
This is the rqt_graph output of the failed SLAM:If hector_slam works in one machine, I get this graph:
Thus, somehow the node parameter setting
<node pkg="tf" type="static_transform_publisher" name="base_to_laser_broadcaster" args="0 0 0 0 0 0 base_link laser 100" />
is for the setup with two machines not suitable. Based on the tf documentation, the arguments meanframe_id
isbase_link
, andchild_frame_id
islaser
.