Does ROS publish random values to its joints when launched ?

asked 2019-07-29 11:53:12 -0500

microbot gravatar image

updated 2019-07-29 17:22:07 -0500

jayess gravatar image

Hello,

I am trying to run a robot by first launching it on gazebo and then later running the plugin to control it autonomously in another tab of the terminal. Initially when I launch the robot in gazebo using this following command

roslaunch spider_gazebo spider_world.launch

The robot gets successfully spawned in gazebo in the desired world along with loading all the position controllers for all the joints and joint_state_controller. Immediately after robot is spawnned and all the controllers are loaded, robot starts moving its joints which means it keeps updating its joint positions with random values. I can not understand this behaviour, can anyone please help me with this ?

for reference, I would like to provide the code about how i added controllers ,

<transmission name="tran1_1">
<type>transmission_interface/SimpleTransmission</type>
<joint name="joint_1_1">
  <hardwareInterface>PositionJointInterface</hardwareInterface>
</joint>
<actuator name="motor1_1">
  <hardwareInterface>PositionJointInterface</hardwareInterface>
  <mechanicalReduction>1</mechanicalReduction>
</actuator>
</transmission>

and this is how i added controller to gazebo ,

joint_1_1_position_controller:
type: position_controllers/JointPositionController
joint: joint_1_1
pid: {p: 100.0, i: 0.1, d: 0.0}

can anyone please help me clarify this or provide me related webpage where this is explained ? I have gone through ros-control page multiple times but i still can not understand the following problem. Thank you

edit retag flag offensive close merge delete

Comments

Are you sure your controllers aren't just unstable? Could it be that your PID control values are causing the motion while trying to hold the joints still?

jarvisschultz gravatar imagejarvisschultz ( 2019-07-29 19:11:22 -0500 )edit

Thanks for pointing out, that might be the reason too, i will try to check it and let you know. Thanks once again.

microbot gravatar imagemicrobot ( 2019-07-30 03:22:11 -0500 )edit