Yet another MyoConnect alternative without dongles
Project description
dl-myo (Dongle-less Myo)
dl-myo is yet another MyoConnect alternative for Myo Armband without an official Myo dongle.
If you are fed up with the dongle and still want to use Myo anyway (in Python), this is the right stuff to grab.
The GATT service naming convention reflects the official BLE specification for Myo (i.e., myohw.h); however, some services and characteristics differ for a uniform naming.
See myo/profile.py
for more detail.
Features
Compared to other Myo libraries/SDKs:
- Full-scratched in Python, no dependency from other runtime (e.g., the official cpp SDK)
- Multi-platform support based on Bleak, instead of bluepy or pybluez
- Stream EMG data (filtered/raw) and IMU data simultaneously using asyncio
- A sample docker image provided -- runs just off the shelf
Platform Support
Linux | Raspberry Pi | macOS | Windows |
---|---|---|---|
✅ | ✅ | ✅ | ✅ |
Install
pip install dl-myo
Examples
sample_client.py
The script scans a Myo device, connect to the device, prints the GATT profile from the device, collect EMG data for 5 seconds, and then disconnect.
Any Myo Armband should have the service UUID d5060001-a904-deb9-4748-2c7f4a124842
.
python examples/sample_client.py
Otherwise, you can also bind to a specific MAC address. For example,
python examples/sample_client.py --mac D2:3B:85:94:32:8E
influxdb
The examples/influxdb/influx_client.py
emits datapoints to be stored in InfluxDB.
The docker-compose.yml
lanches the required database for this by default.
docker compose up -d influxdb
then
python examples/influxdb/influx_client.py
Make use of the dashboard config examples/influxdb/myo.json
.
Try the example with Docker
NOTE: The docker example currently doesn't work on macOS.
docker compose pull
docker compose run --rm dl-myo
Build with Poetry
Install Poetry first.
poetry build
Credits
This project was first inspired by Dongleless-myo (originally created by @mamo91 and enhanced by @MyrikLD) which provides a great starting point using bluepy.
In addition to Myo Bluetooth Official Protocol, I would like to mention that the following resources on GitHub have been very helpful:
- https://github.com/Alvipe/Open-Myo/issues/5
- https://github.com/NiklasRosenstein/myo-python/releases/tag/v1.0.4
- https://github.com/PerlinWarp/Neuro-Breakout
- https://github.com/balandinodidonato/MyoToolkit/blob/master/Software%20for%20Thalmic's%20Myo%20armband.md
- https://github.com/cortinico/myonnaise
- https://github.com/dzhu/myo-raw
- https://github.com/exelban/myo-armband-nn
- https://github.com/francocruces/MioConnect
- https://github.com/hcilab/MyoStream
Author
@iomz (Iori Mizutani)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file dl_myo-1.1.4.tar.gz
.
File metadata
- Download URL: dl_myo-1.1.4.tar.gz
- Upload date:
- Size: 26.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/4.0.2 CPython/3.11.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 957ee58bc2ce852182ee76d3aa0759858140742bab822a325d9b4c5f442bbf5a |
|
MD5 | 1746d16c2ac0e2b10263bb437e28c759 |
|
BLAKE2b-256 | d1958b3d8a9ddf844ee588fbdaaac9f086d8b0b622300e941597b4ae70110bbd |
File details
Details for the file dl_myo-1.1.4-py3-none-any.whl
.
File metadata
- Download URL: dl_myo-1.1.4-py3-none-any.whl
- Upload date:
- Size: 25.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/4.0.2 CPython/3.11.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 02019f62a044002575a4f2551e202bc711b6d7410e93ee2f04e4ad8f1d8d3ed4 |
|
MD5 | a93339bc93e49d41d9706a608ee7a314 |
|
BLAKE2b-256 | 81c4078158ab1238b97ccd9584b2e60df608f82c89123caaf3ea95bc775d3298 |