Skip to content
This repository has been archived by the owner on Feb 16, 2018. It is now read-only.

Running ros_myo and Examples

roboTJ101 edited this page Dec 22, 2014 · 7 revisions

Bare Minimum

To run just the node responsible for parsing raw Myo data, you will need to (with a roscore running) go to your catkin_ws and run:
rosrun ros_myo myo-rawNode.py

This must be run separately before any other nodes run. If you try to launch any nodes that read from myo-rawNode.py topics, you will get an error as the node must establish the BT protocol first. A Myo dongle does not need to be plugged in or even on to run.

Gesture Control (digital)

To see an example of how you might use the Myo to control a robot using digital (on/off) gestures, and with a running myo-rawNode, run:
roslaunch ros_myo turtle_pose.launch

This will fire up a turtlesim window. Perform the Sync Gesture (the Myo should vibrate when successful) and then perform any of the four accepted gestures to move the turtle around the screen. The control scheme is:

  • Spread fingers: move forward
  • Make a fist: move backward
  • Wave left: turn left
  • Wave right: turn right

Gesture Control (analog)

To see an example of how you might use the Myo to control a robot using analog gestures, and with a running myo-rawNode, run:
roslaunch ros_myo turtle_analog.launch

This will fire up a turtlesim window. The control of the turtle is now achieved by looking at the muscle activation in your arm. If all the muscles are very activated (signified by EMG readings > 200) then the turtle will move forward. The more activated your muscles, the faster the turtle will move (try making a fist and squeezing different amounts). The next part is a little trickier.

The turning command is designed such that if you wave your hand to the left, the turtle will turn left, and right works the same way. However for this to be the case, the Myo must be oriented such that the first 4 sensors are on the right, and the second 4 sensors are on the left. To position the Myo correctly on your arm, put your arm out like you are returning a handshake and then rotate the 4th sensor (the one with the glowing Thalmic logo on it) so that it is facing straight up with the charging indicator pointing towards your wrist. If you are having trouble driving the turtle, run the myo-rawNode and then run rostopic echo myo_emg, which will allow you to see the readings coming out of the Myo EMG sensors in order.