Open EwingKang opened 5 years ago
It turns out that there's a parameter called reversion
, you have to set those manually.
<node name="ydlidar_node" pkg="ydlidar" type="ydlidar_node" output="screen">
<param name="port" type="string" value="/dev/ydlidar"/>
<param name="baudrate" type="int" value="115200"/>
<param name="frame_id" type="string" value="laser_frame"/>
<param name="angle_fixed" type="bool" value="true"/>
<param name="low_exposure" type="bool" value="false"/>
<param name="heartbeat" type="bool" value="false"/>
<param name="resolution_fixed" type="bool" value="true"/>
<param name="reversion" type="bool" value="true"/>
<param name="angle_min" type="double" value="-180" />
<param name="angle_max" type="double" value="180" />
<param name="range_min" type="double" value="0.08" />
<param name="range_max" type="double" value="16.0" />
<param name="ignore_array" type="string" value="" />
<param name="samp_rate" type="int" value="9"/>
<param name="frequency" type="double" value="7"/>
</node>
But still, the scanning direction is reversed compare to the standard definition of ROS (http://docs.ros.org/melodic/api/sensor_msgs/html/msg/LaserScan.html) which, which will cause problem if vehicle is moving.
The scanning frame, including the robot model is rotated by 180 degrees around Z axis. In this picture, the wall corner is actually on the right-front direction, while the arrow pointing at the LIDAR is at its left-hand-side