Home | Tutorials | Wiki | Issues
Ask Your Question
0

Simple URDF vehicle model

asked 2017-10-30 09:25:00 -0500

Nicola gravatar image

Hi,

I have been using Gazebo for a few days and I need to simulate a wheeled vehicle, guided via keyboard, housing a GPS and an IMU. In order to do that, I found and followed this tutorial, explaining how to create and simulate an URDF model of a robot:

https://www.generationrobots.com/blog...

However I have noticed the following problems:

1) the graphic simulation is not consistent with the keyboard input commands: a "real time response" occurs only after many minutes from the simulation start.

2) I added a GPS to the "mybot.gazebo" file, using the following code:

 <gazebo>
<plugin name="name_gps" filename="libhector_gazebo_ros_gps.so"> 
<alwayson>1</alwayson> 
<updaterate>10.0</updaterate> 
<bodyname>chassis</bodyname>
<topicname>mybot/gps_fix</topicname> 
<velocitytopicname>mybot/gps_fixvelocity</velocitytopicname> 
<drift>5.0 5.0 5.0</drift> 
<gaussiannoise>0.1 0.1 0.1</gaussiannoise> 
<velocitydrift>0 0 0</velocitydrift> 
<velocitygaussiannoise>0.1 0.1 0.1</velocitygaussiannoise> 
</plugin>
</gazebo>

However, despite not having encountered any error/warning from the GPS plugin, the /mybot/gps_fix and /mybot/gps_fixvelocity do not appear on the rostopic list.

Does anyone know how to fix these problems?

Thank you in advance

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2018-08-23 03:00:57 -0500

Subodh Malgonde gravatar image

For the first problem you need to tune the PID control parameters in mybot_control/config/mybot_control.yaml. The following works for me:

  # Effort Controllers ---------------------------------------
  leftWheel_effort_controller:
    type: effort_controllers/JointEffortController
    joint: left_wheel_hinge
    pid: {p: 18.0, i: 0.1, d: 2.0}
  rightWheel_effort_controller:
    type: effort_controllers/JointEffortController
    joint: right_wheel_hinge
    pid: {p: 18.0, i: 0.1, d: 2.0}

I don't have an answer to your 2nd question. Also I think you should post a separate question since the 2 questions are not related to each other.

edit flag offensive delete link more
Login/Signup to Answer

Question Tools

1 follower

Stats

Asked: 2017-10-30 09:25:00 -0500

Seen: 433 times

Last updated: Aug 23