0
$\begingroup$

Rosanswers logo

I use Turtlebot(Kobuki) and Xbox One Kinect(Kinect v2) on Ubuntu16.04 and ROS Kinetic. I succeeded to SLAM and AMCL with turtlebot_navigation package. On the other hand, when turtlebot moved autonomously, it didn't avoid obstacles like walking human. I checked my costmap_common_params.yaml, but I couldn't find any mistakes. If you have some idea, could you please tell me?

When I attached and launch Kinect, I referred to this page. To start SLAM and AMCL, I type following commands. When I launched minimal.launch, 3 nodes(rocon_master, rocon_app_manager, interactions) failed to start. I understand rocon is just a interface to communicate with user, so 3 nodes wake up error don't relate not to avoid obstacles issue.

  1. roslaunch turtlebot_bringup minimal.launch
  2. roslaunch kinect2_bridge kinect2_bridge.launch publish_tf:=true
  3. rosrun depthimage_to_laserscan depthimage_to_laserscan image:=/kinect2/sd/image_depth_rect _output_frame_id:=/base_kinectv2_link
  4. roslaunch turtlebot_navigation gmapping_demo.launch / amcl_demo.launch

To succeed SLAM and AMCL, I mainly changed following files. I didn't change my local_costmap_params.yaml.

  1. 3dsensor.launch
    I commented out from line 43 to the end of file.

  2. turtlebot_library.urdf.xacro
    I added Kinect v2 model. I checked out Kinect v2 one from here and named turtlebot_kinect2_rgb_optical_frame. Furthermore, I defined base_kinect2_link originally. This is because when I used turtlebot_kinect2_rgb_optical_frame, scan data is projected on Y-Z plane, not X-Y plane. I found the reason of this problem is that attitude of turtlebot_kinect2_rgb_optical_frame is not rotated for base_link and base_footprint. So I resolve the problem, I defined base_kinect2_link which attitude is same as base_link and the pose is same as turtlebot_kinect2_rgb_optical_frame.

  3. costmap_common_params.yaml(1), costmap_common_params.yaml(2) I added "sensor_frame" in scan section. The name of the topic publishing Kinect v2 data is "scan".


[CHANGE] I uploaded my configuration files and other ones to GitHub. URL is https://github.com/graziegrazie/my_turtlebot. If you have a time, please check my files and comment to my problem.


Originally posted by graziegrazie on ROS Answers with karma: 46 on 2016-10-09

Post score: 1


Original comments

Comment by mgruhler on 2016-10-10:
There are other ways to show your configuration files. Upload them to GitHub, put them in as a GIST or use any other of the codes snippet hosters out there...

Comment by graziegrazie on 2016-10-11:
Hi, mig. Thank you for your comment. I uploaded my code and configuration files to GitHub and added URL to content. If you check it and comment to me, it's a very glad for me.

$\endgroup$

1 Answer 1

0
$\begingroup$

Rosanswers logo

It might be because of the laserscan transformation to the robot base, in the yaml file, put min_obstacle_height lower and the max higher.


Originally posted by zhibo with karma: 36 on 2016-10-13

This answer was ACCEPTED on the original site

Post score: 0


Original comments

Comment by graziegrazie on 2016-10-18:
Hi, zhibo. Thank you for your comment and I'm sorry for my late response. I updated my yamls(common_costmap_params.yaml and ...

Comment by graziegrazie on 2016-10-18:
local_costmap_params.yaml. But while turtlebot moved autonomously and I suddenly jumped out in front of it, it didn't avoid me. Did I change files as you say?

Comment by zhibo on 2016-10-18:
0.0 won't work for sure, I'd put 0.01 and the max at 1, then if it detects, you can adjust the values.

Comment by graziegrazie on 2016-11-04:
sorry for my late response. I changed min_obstacle_height and max to 0.01 and 1.0, but turtlebot didn't avoid me.

I'll check source code around obstacle avoidance(base local planner and dwa) to resolve this.

If you have other ideas about this problem, could you tell me them?

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.