Robotics StackExchange | Archived questions

Adding wheel diameter(diff_drive_controller) for a stl file added in urdf

I created a 4 wheel bot and i want it to move with the help of diffdrivecontroller by giving parameters like all 4 wheel joints, wheel separation,wheel diameter and so on... the thing is my wheel is not created by a shapes, instead i added a stl file for left and right wheel. so, i have to give the wheel diameter to make it move, how can i give the diameter of a stl file which i don't know?

Asked by the_one on 2023-07-10 09:00:53 UTC

Comments

Answers

You can "measure" them creating a simple cylinder model and adjusting its radius to visually match the size of your wheels. Then you save the model and read the radius value in the .sdf file ().

Asked by MSanMon on 2023-07-10 10:10:38 UTC

Comments

It would also be useful when you are implementing collision geometry, as you certainly should when working with any robot. This way, you define your collision cylinder, and then copy over the diameter to your controller parameters

Asked by sampreets3 on 2023-07-11 05:12:40 UTC

i already gave the collision geometry for the wheels( same as added mesh file in visual geometry). I added an stl file for the wheels because of i don't want to implement the wheel part from just shapes.

Asked by the_one on 2023-07-11 23:49:49 UTC

hey, thank you for your reply. Actually i got the wheel size of an stl file from online free websites by just uploading and measuring it. I should have done that before asking here.

Asked by the_one on 2023-07-11 23:50:17 UTC

moving forward, how can i give the diff_drive_controller for a wheel wheeled bot? I searched online, many are 2 wheeled robots. i tried many different ways, but the robot doesn't move a mm when i run give this command in another terminal rostopic pub /cmd_vel geometry_msgs/Twist -r 10 -- '[0.2, 0.0, 0.0]' '[0.0, 0.0, 0.6]' and the wheels are in gazebo are so shaking. i don't know why. how can i make it move?

Asked by the_one on 2023-07-12 01:33:56 UTC

I just followed this urdf tutorial for the 4 wheel bot("learning URDF step by step" context) driving with the help of diff_drive_controller.

Asked by the_one on 2023-07-18 23:29:10 UTC

Comments