Ask Your Question
0

AMCL / Hector_Slam problem

asked 2019-02-12 17:30:44 -0500

JankenGatsu gravatar image

Hello !

Actually I'm working on a SLAM robot using a Raspberry PI3B with Ubuntu Mate 16.04 et ROS Kinetic.

I started with the mapping (using Hector_Slam) and the result was pretty good.

For the localization, I use in a first time a laser_scan_matcher node to get the pose and rotation of the robot and the result was pretty good without any IMU data and ACML or EKF techniques.

But using the scan_matching I have big problems when I make big rotation with my robot and the rotation drift and my mapping is wrong.

So I search how to use AMCL to make better localisation/rotation prediction. But the result is even worse ! And I get a drift instantly when I rotate the robot.

Below you will see all my information, do you see any problems in my using of AMCL ?

Do I strictly need an IMU for get good rotations predictions ? Can I just do not use the rotation for my SLAM project and just use the pose prediction ?

Lidar ( RPLIDAR A1)

 <launch>
          <node name="rplidarNode"          pkg="rplidar_ros"  type="rplidarNode" output="screen">
          <param name="serial_port"         type="string" value="/dev/ttyUSB0"/>  
          <param name="serial_baudrate"     type="int"    value="115200"/>
          <param name="frame_id"            type="string" value="laser"/>
          <param name="inverted"            type="bool"   value="false"/>
          <param name="angle_compensate"    type="bool"   value="true"/>
          </node>
   </launch>

Mapping / Localization

<launch>

<arg name="trajectory_source_frame_name" default="/laser"/>
  <arg name="trajectory_update_rate" default="1"/> 
  <arg name="trajectory_publish_rate" default="1"/>
  <arg name="map_file_path" default="$(find hector_geotiff)/maps"/>
  <arg name="map_file_base_name" default="hector_slam_map"/>

  <node pkg="hector_trajectory_server" type="hector_trajectory_server" name="hector_trajectory_server" output="screen">
    <param name="target_frame_name" type="string" value="/map" />
    <param name="source_frame_name" type="string" value="$(arg trajectory_source_frame_name)" />
    <param name="trajectory_update_rate" type="double" value="$(arg trajectory_update_rate)" />
    <param name="trajectory_publish_rate" type="double" value="$(arg trajectory_publish_rate)" />
  </node>
<node pkg="tf" type="static_transform_publisher" name="link1_broadcaster" args="0 0 0 0 0 0 base_link laser 100" />


 <node pkg="laser_scan_matcher" type="laser_scan_matcher_node" 
    name="laser_scan_matcher_node" output="screen">


    <param name="base_frame" value="base_link"/>
    <param name="fixed_frame" value="odom"/>
    <param name="use_alpha_beta" value="false"/>
    <param name="use_odom" value="true"/>
    <param name="use_imu" value="false"/>
    <param name="max_iterations" value="4"/>
    <param name="publish_pose" value="true"/>
    <param name="publish_tf" value="true"/>


  </node>

    <node pkg="hector_mapping" type="hector_mapping" name="hector_height_mapping" output="screen">
     <param name="scan_topic" value="scan" />
    <param name="base_frame" value="base_link" />
    <param name="odom_frame" value="base_link" />

    <param name="output_timing" value="false"/>
    <param name="advertise_map_service" value="true"/>
    <param name="use_tf_scan_transformation" value="false"/>
    <param name="use_tf_pose_start_estimate" value="false"/>
    <param name="pub_map_odom_transform" value="false"/>
    <param name="map_with_known_poses" value="false"/>
    <param name="pub_map_scanmatch_transform" value="false"/>

    <param name="map_pub_period" value="0.9"/>
    <param name="update_factor_free" value="0.45"/>
    <param name="laser_max_dist" value="12"/>
    <param name="map_update_distance_thresh" value="0.4"/>
    <param name="map_update_angle_thresh" value="1"/>

    <param name="map_resolution" value="0.05"/>
    <param name="map_size" value="1024"/>
    <param name="map_start_x" value="0.5"/>
    <param name="map_start_y" value="0.5"/>

    <param name="pub_odometry" value="true"/>



  </node>

<node pkg="amcl" type="amcl" name="amcl" output="screen">

  <param name="use_map_topic " value="true"/>



  <param name="odom_model_type" value="diff"/>

  <param name="odom_alpha5" value="0 ...
(more)
edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2019-02-12 20:21:40 -0500

jordan gravatar image

By 'big rotation'... Does it work OK with rotations having a low angular velocity? ie. does the problem only appear when the robot turns quickly? If yes, then the problem might be the scan match failing due to exceeding the angular search range. You may need to limit the angular velocity of the robot, or perhaps get a faster LiDAR. If anyone knows how to expand the scan matching to tolerate larger rotations between scans (at the cost of CPU load?) in hector... that might be interesting too.

edit flag offensive delete link more

Comments

Yeah I suppose that my LIDAR is maybe too slow. Perhaps by reducing the angular velocity of the robot can resolve the problem.

I just tried to rotate slowly and whitout ACML i got good results, not perfect but still ok.

Strangely when I use ACML all goes mad when I move the robot.

JankenGatsu gravatar imageJankenGatsu ( 2019-02-13 07:16:21 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2019-02-12 17:30:44 -0500

Seen: 167 times

Last updated: Feb 12