Why amcl is not working?
Hi, I am trying to implement amcl on rviz using nxt and kinect.
However, it just can't localize itself. I have used rviz 2D pose estimate to select the initial location of the robot as shown below (but no particle cloud is shown after I release my mouse click button -> rviz highlighted the particle cloud in yellow)
The navigation stack is working perfectly, it can plan the required navigation path and move to the desired destination, as shown in the pictures below:
The rxgraph is shown below (amcl did received all the 4 needed subscribed topics which are /scan, /tf, /map and /initialpose reference) :
The tf_frames is shown below (I can't detect any error with the tf_frames as well ,hmm...):
The yaml files:
costmap_common_params.yaml:
obstacle_range: 2.5
raytrace_range: 3.0
footprint: [[0.305, 0.278], [0.04, 0.193], [-0.04, 0.193], [-0.282, 0.178], [-0.282, -0.178], [-0.04, -0.193], [0.04, -0.193], [0.305, -0.278]]
inflation_radius: 0.55
observation_sources: laser_scan_sensor
laser_scan_sensor: {sensor_frame: openni_depth_frame, data_type: LaserScan, topic: scan, marking: false, clearing: true}
global_costmap_params.yaml:
global_costmap:
global_frame: /map
robot_base_frame: base_footprint
update_frequency: 5.0
static_map: true
local_costmap_params.yaml:
local_costmap:
global_frame: odom_combined
robot_base_frame: base_footprint
update_frequency: 5.0
publish_frequency: 2.0
static_map: false
rolling_window: true
width: 6.0
height: 6.0
resolution: 0.05
base_local_planner_params.yaml:
TrajectoryPlannerROS:
max_vel_x: 0.45
min_vel_x: 0.1
max_rotational_vel: 1.0
min_in_place_rotational_vel: 0.4
acc_lim_th: 3.2
acc_lim_x: 2.5
acc_lim_y: 2.5
holonomic_robot: False
The launch files:
amcl_diff_with_map_hwk.launch:
<launch>
<node pkg="amcl" type="amcl" name="amcl" output="screen">
<param name="use_map_topic " value="true"/>
<!-- Publish scans from best pose at a max of 10 Hz -->
<param name="odom_model_type" value="diff"/>
<param name="odom_alpha5" value="0.1"/>
<param name="transform_tolerance" value="0.2" />
<param name="gui_publish_rate" value="10.0"/>
<param name="laser_max_beams" value="30"/>
<param name="min_particles" value="500"/>
<param name="max_particles" value="5000"/>
<param name="kld_err" value="0.05"/>
<param name="kld_z" value="0.99"/>
<param name="odom_alpha1" value="0.2"/>
<param name="odom_alpha2" value="0.2"/>
<!-- translation std dev, m -->
<param name="odom_alpha3" value="0.8"/>
<param name="odom_alpha4" value="0.2"/>
<param name="laser_z_hit" value="0.5"/>
<param name="laser_z_short" value="0.05"/>
<param name="laser_z_max" value="0.05"/>
<param name="laser_z_rand" value="0.5"/>
<param name="laser_sigma_hit" value="0.2"/>
<param name="laser_lambda_short" value="0.1"/>
<param name="laser_lambda_short" value="0.1"/>
<param name="laser_model_type" value="likelihood_field"/>
<!-- <param name="laser_model_type" value="beam"/> -->
<param name="laser_likelihood_max_dist" value="2.0"/>
<param name="update_min_d" value="0.2"/>
<param name="update_min_a" value="0.5"/>
<param name="odom_frame_id" value="odom"/>
<param name="resample_interval" value="1"/>
<param name="transform_tolerance" value="0.1"/>
<param name="recovery_alpha_slow" value="0.0"/>
<param name="recovery_alpha_fast" value="0.0"/>
</node>
</launch>
move_base.launch:
<launch>
<master auto="start"/>
<!-- Run the map server -->
<node name="map_server" pkg="map_server" type="map_server" args="$(find not_good)/Maps/map.pgm 0.05"/>
<!-- tf /map to /odom_combined -->
<node pkg="tf" type="static_transform_publisher" name="map_to_odom_combined" args="100 100 0 0 ...