francocruces / MioConnect

MyoConnect alternative for the Myo Armband with OSC protocol
MIT License
22 stars 12 forks source link
emg imu myo myo-armband osc

Background

MioConnect is a MyoConnect alternative for the Myo Armband, connects to the device(s) and transmits EMG/IMU via OSC.

This software was developed for the Emovere Project (http://www.emovere.cl/). They needed to avoid MyoConnect, because they only required raw EMG/IMU data during a contemporary dance performance, and could not re-sync the armband after sudden arm movements.

The code provides a comprehensible framework for a direct connection to the Myo Armband, using the Bluegiga BLE Bluetooth library and the Myo Bluetooth Protocol released by Thalmic Labs on March 26, 2015. Hopefully this helps a lot of people developing their own direct connections and understanding the bluetooth protocol.

Requirements

This project runs on Python 3. Requirements are inside requirements.txt file.

You can easily install them via pip install -r requirements.txt.

How to run

The file mio_connect.py contains the main loop for the application. Which instantiates a MyoDriver object and starts the main procedure.

Run mio_connect.py -h to get help on the software usage. You can add the following commands:

Default configuration is written in a single file: src/config.py. These settings include:

What it does

The code is thoroughly documented and should be easy to follow, but a high-level description will be given:

If a myo disconnects, an event is received and a reconnection routine will start with provided configuration.

Project files

mio_connect.py

This file contains the main loop for the application.

src

Each file contains a single python class with its own responsibility:

src/public

Contains files that are taken from another project following their respective licenses.

Turn off Myo

The protocol provides the deep_sleep command (see myohw), according to the release notes, the armband will go into a state with basically everything off and can stay in that state for months. The only way to turn it back on is plugging it via USB (as MyoConnect would).

You can start a procedure for finding devices and the turning them all off with the -s (--shutdown) command. Using it with -n <amount> will find and turn off given amount of myos.

Issues

Thalmic Labs rebrand

Thalmic Labs is no longer selling Myo Armbands and has their website (https://www.myo.com/) is now unreachable. The developer forums (https://developer.thalmic.com/forums/) are also down and we should not expect any future support from Thalmic, but the community may gather in another website (maybe https://www.reddit.com/r/thalmic/)

This is actually a rebrand, they have become "North" and released Smart Glasses powered by Alexa (website: https://www.bynorth.com/).

Details here https://venturebeat.com/2018/10/23/thalmic-labs-rebrands-as-north-launches-999-alexa-powered-holographic-glasses/.

References