Husky robot not moving as it should

Hello @girishkumar.kannan,

the robot doesn’t move because it using a velocity command multiplexer with a dead-man’s switch to increases the safety of the robot operation. This causes the robot to stop automatically if it does not continuously receive a new command message. By default rostopic pub will only send one message to each subscriber. In this case the dead-man switch will stop the robot as said before. In order for the robot to keep operating we must tell rostopic pub command to keep sending new messages at a constant frequency. We do so by adding the -r option and specifying a frequency. Try this command here and see if it works:

user:~$ rostopic pub -r 50 /cmd_vel geometry_msgs/Twist "linear:
  x: -1.0
  y: 0.0
  z: 0.0
angular:
  x: 0.0
  y: 0.0
  z: 0.0"

You will also note that the robot will immediately stop if you kill the publisher using Ctrl+C. Normally we would have to stop the robot sending a new velocity command with all zeros.

By the way this is not part of the course, so don’t worry to much about it. For the unit you have to use the keyboard teleoperation node to control the robot, and as you will have noticed you have to keep the keys pressed to move the robot. If you release a key the robot will stop. This is due to the same reasons.

I added a note to the unit indicating that it is necessary to press and hold a key on the keyboard to move the robot.

Hope this helped,

Cheers,

Roberto