Home | Tutorials | Wiki | Issues
Ask Your Question
0

ros_controllers problems

asked 2013-10-01 19:08:19 -0500

Hi, I am writing a description of my robot combining xacros, gazebos and yamls files. I have some troubles with my controllers and sensors.

About sensors: I am tring to add an IMU in my robot. I have a link "imulink" in my xacro and a fixed joint "imujoint" between imu_link and another link in my robot. Now, in my robot.gazebo file I have the following:

< gazebo > < plugin name="imu_sensor_controller" filename="libgazebo_ros_imu.so" > < bodyName >imu_link< /bodyName > < always_on >1< /always_on > < !-- update_rate >1000.0< /update_rate -- > < robotNamespace >/COMAN< /robotNamespace > < topicName >coman_imu< /topicName > < /plugin > < /gazebo >

and in my robot_control.yaml I have:

imu_sensor_controller: type: imu_sensor_controller/ImuSensorController publish_rate: 50

In the launch file for the controller I use the controllermanager spawner to spawn the imusensor_controller. When I launch it I have the following error from GAZEBO:

[ERROR] [1380671129.134196839]: This controller requires a hardware interface of type 'hardware_interface::ImuSensorInterface'. Make sure this is registered in the hardware_interface::RobotHW class.

I think I have to put this in my transmission.urdf.xacro but I do not well know where is he syntax for the imu hardware interface. Do you have some suggestion? Maybe I am wronging something?

Thank you for your help.

Enrico

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2013-10-02 11:37:35 -0500

updated 2013-10-10 10:27:41 -0500

nkoenig gravatar image

Solved using the following:

 <gazebo>
    <plugin name="quadrotor_imu_sim" filename="libhector_gazebo_ros_imu.so">
      <updateRate>100.0</updateRate>
      <bodyName>imu_link</bodyName>
      <topicName>COMAN/raw_imu</topicName>
      <rpyOffsets>0 0 0</rpyOffsets> <!-- deprecated -->
      <gaussianNoise>0</gaussianNoise>  <!-- deprecated -->
      <accelDrift>0.5 0.5 0.5</accelDrift>
      <accelGaussianNoise>0.35 0.35 0.3</accelGaussianNoise>
      <rateDrift>0.1 0.1 0.1</rateDrift>
      <rateGaussianNoise>0.05 0.05 0.015</rateGaussianNoise>
      <headingDrift>0.1</headingDrift>
      <headingGaussianNoise>0.05</headingGaussianNoise>
    </plugin>
  </gazebo>
</robot>
edit flag offensive delete link more

Comments

Does this IMU plugin simulate realistic data? I tried to simulate my IMU with "libgazebo\_ros\_imu.so", but the simulated data doesnt look very good....

psei gravatar imagepsei ( 2013-10-10 05:52:13 -0500 )edit

Can you start a new question, and elaborate on "doesn't look very good"?

nkoenig gravatar imagenkoenig ( 2013-10-10 10:31:02 -0500 )edit
Login/Signup to Answer

Question Tools

Stats

Asked: 2013-10-01 19:08:19 -0500

Seen: 1,038 times

Last updated: Oct 10 '13