Gazebo | Ignition | Community
Ask Your Question
0

4 wheel robot differential controller

asked 2018-01-21 00:17:33 -0600

kallileo gravatar image

I have designed simple a 4-wheel robot and I want to make it move. The controller below is located in "myrobot.gazebo" file and it works with 2 wheels and a caster. Is it possible to modify the controller so it can control 2 wheels on each side?

    <gazebo>
<plugin name="differential_drive_controller" filename="libgazebo_ros_diff_drive.so">
  <legacyMode>false</legacyMode>
  <alwaysOn>true</alwaysOn>
  <updateRate>20</updateRate>
  <leftJoint>left_wheel_hinge</leftJoint>
  <rightJoint>right_wheel_hinge</rightJoint>
  <wheelSeparation>0.4</wheelSeparation>
  <wheelDiameter>0.1</wheelDiameter>
  <torque>20</torque>
  <commandTopic>cmd_vel</commandTopic>
  <odometryTopic>odom</odometryTopic>
  <odometryFrame>odom</odometryFrame>
  <robotBaseFrame>chassis</robotBaseFrame>
</plugin>
</gazebo>
edit retag flag offensive close merge delete

Comments

hi @VEGETA did you find the answer to this question? I have found some examples for this problem. However, they are all made using 2 wheels. And I think it's very difficult to make a 4 or 6-wheel robot using these examples. I have a robot with 6 wheels right now and I want to make it move. https://goo.gl/9wknlrhttps://goo.gl/JtEWFChttps://goo.gl/UUVdzA

tooght gravatar imagetooght ( 2018-01-21 12:52:59 -0600 )edit

2 Answers

Sort by ยป oldest newest most voted
0

answered 2018-01-31 04:13:50 -0600

moshimojo gravatar image

For a 4-wheel robot you better use the Skid Steer plugin in here. Differential drive doesn't control both 2 wheels on each side.

edit flag offensive delete link more
0

answered 2018-01-23 01:44:17 -0600

Raskkii gravatar image

You would have to modify the source code of the diffdrive controller (better to make a new plugin yourself and use diffdrive as a base).

It shouldn't be much work, you'd just need to obviously add the rear wheels to the plugin and apply the velocity the same way as it is applied to the front wheels.

If you're not familiar on how to make your own plugin then I suggest you read this tutorial: http://gazebosim.org/tutorials/?tut=p...

Good luck!

edit flag offensive delete link more

Comments

Thankyou so much.

tooght gravatar imagetooght ( 2018-01-27 13:53:16 -0600 )edit

Question Tools

1 follower

Stats

Asked: 2018-01-21 00:17:04 -0600

Seen: 8,331 times

Last updated: Jan 31 '18