Tutorials/drcsim/2.4/keyboard teleop


 * 1) Keyboard Teleoperation

DRCSim v2.4 introduces an example interface to the Atlas Sim Interface and BDI Controller. It consists of an Actionlib server and a keyboard_teleop python ROS node. This tutorial explains how to use the teleop.

Launch the simulator (be sure to first `source /usr/share/drcsim/setup.sh` as usual):
 * 1) Setup ##

roslaunch atlas_utils atlas_sandia_hands.launch

Launch keyboard teleop
 * 1) Teleop ##

roslaunch atlas_utils keyboard_teleop.launch

You will see a screen like below:

Keyboard Teleop for AtlasSimInterface 1.0.5 Copyright (C) 2013 Open Source Robotics Foundation Released under the Apache 2 License --       Linear movement:

i              j         l                , Turn movements: o/u Turn around a point m/. Turn in place 1-9: Change the length of step trajectory E: View and Edit Parameters R: Reset robot to standing pose Q: Quit


 * 1) Initializing/Resetting the robot

Press 'R' to move the robot to a BDI-controlled standing position. You should do this once at startup, before issuing other commands. You can do it again at any time (e.g., after the robot has fallen over).


 * 1) Movements

Press I to move forward, ',' to move backward. J sidesteps laterally to the left, and L sidesteps to the right.

Pressing O, or U walks the atlas in a circle around a point to the left or right by 2 meters.

Pressing M and '.' turns the robot around on a point

This is an image of Atlas walking in a 2 meter circle.




 * 1) Changing parameters

You can change a number of parameters to experiment with the walking controller. Press E on the main screen to enter the parameter adjustment screen. It should look like this:

0 : Walk Sequence Length 5 1 : Forward Stride Length 0.15 2 : Step Height          0 3 : Stride Duration      0.63 4 : Stride Width         0.2 5 : Lateral Stride Length 0.15 6 : In Place Turn Size   0.196349540849 7 : Swing Height         0.3 8 : Turn Radius          2 X : Exit Enter number of param you want to change:

Enter a number of the param you to change, in this case we can increase the forward stride length by pressing 1 and 'Enter'. It brings up the following:

New value for Forward Stride Length [min: 0, max: 1, type: float]?

Type in 0.3 and press enter to increase the stride length. Then type x and press 'Enter' to exit the screen.

Press 'i' and the robot will walk forward a total of 1.5 meters.

It is recommended to keep the forward stride length below 0.4 meters, and the lateral stride length below 0.5 meters. The stride duration should be kept between 0.75 and 0.55, but it may depend on the chosen step width.

Press `Q` to exit `keyboard_teleop.py`, then Ctrl-C to kill `roslaunch`.
 * 1) Exiting

* Holding down a key will flood the server with commands. The overlap of commands can cause unpredictable results. To avoid this issue for now, press your command once and wait until the robot comes to a stop. If you want longer trajectories, change the sequence length. [Ticket](https://bitbucket.org/osrf/drcsim/issue/204) * Rotating in place with an Atlas model with hands is not very stable, use rotate around a point instead and plan your trajectories carefully. [Ticket](https://bitbucket.org/osrf/drcsim/issue/205/atlas-falls-while-rotating-in-place-using) * Ctrl-C does not kill teleop. You must first press `Q` to exit `keyboard_teleop.py`, then Ctrl-C to kill `roslaunch`. [Ticket](https://bitbucket.org/osrf/drcsim/issue/203
 * 1) Known Issues