robots icon indicating copy to clipboard operation
robots copied to clipboard

How to use my own laser?

Open Jingjinganhao opened this issue 4 years ago • 6 comments

Hi, I want to use RPLIDAR A3 on mini cheetah, and I change the gazebo parameter of hokuyo in yobotics.urdf, but it doesn't work . How can I use RPLIDAR A3 ?

Jingjinganhao avatar Nov 20 '20 08:11 Jingjinganhao

Hi,

The easiest way to do this is to just model RPLIDAR's specifications here https://github.com/HitSZwang/mini-cheetah-gazebo-urdf/blob/7f8ae920903084db6971c3de618cb710d6da8f4d/yobo_model/yobotics_description/xacro/accessories.urdf.xacro#L7-L13 . Otherwise, you can just replace the UTM sensor with RPLidar's xacro tag, just don't forget to define the parent frame and its translation/orientation of the sensor

grassjelly avatar Nov 20 '20 17:11 grassjelly

Hi, I set ray_count="10" in accessories.urdf.xacro for testing, but it still doesn't work .

Jingjinganhao avatar Nov 23 '20 02:11 Jingjinganhao

sorry forgot to mention you have to regenerate the URDF for every changes you make:

roscd yobotics_description/urdf
./gen_urdf

grassjelly avatar Nov 23 '20 11:11 grassjelly

Hi, thank you very much, I did what you said and when I run: roslaunch mini_cheetah_config gazebo.launch that works for me . but I want to use my own world file, and when I change the "gazebo_world" in gazebo.launch, it doesn't work. I still get ray_count="1040"

Jingjinganhao avatar Nov 24 '20 01:11 Jingjinganhao

that's strange, because the world file does not contain anything related to your LIDAR. Have you tried the default.world?

grassjelly avatar Nov 24 '20 11:11 grassjelly

Which default.world? When I use outdoor.world, it works. When I use my own world file test.world , even I set ray_count="10" in accessories.urdf.xacro and make roscd yobotics_description/urdf ./gen_urdf I also get ray_count="1040"

Jingjinganhao avatar Nov 25 '20 01:11 Jingjinganhao