Skip to main content

Modern Python 3.7+ library for interfacing with the OpenBCI Ganglion biosensing board over BTLE.

Project description

PyPI version

ganglion-biosensing

Modern Python 3.7+ library for interfacing with the OpenBCI Ganglion biosensing board over BTLE.

The origins of this library come from my personal disagreement with some of the design and implementation choices made by the developers of the official pyOpenBCI library, as well as their slow responses to pull requests. Some of the code in this repository has been obtained and/or adapted from the official pyOpenBCI code (following the MIT License).

It should be noted that this library does not aim to be a full replacement for the official library, as it is completely focused on the Ganglion board and not on the Cyton. It should rather be looked at as an alternative which aims to target a more modern and efficient implementation from the ground up.

Installation

Simply do:

pip install ganglion-biosensing

Alternatively, install from the Github repository:

pip install git+https://github.com/molguin92/ganglion-biosensing.git

Usage

Usage is pretty straightforward - simply declare a Ganglion within a with-block for automatic connection and cleanup:

from ganglion_biosensing.board.ganglion import GanglionBoard

if __name__ == '__main__':
    with GanglionBoard(mac='FF:FF:FF:FF:FF:FF') as board:
        board.start_streaming()
        for i in range(500):
            print(board.samples.get(block=True))

The code is thread safe by design - samples are collected in an asynchronous manner and deposited in the board.samples queue.

For more details see the examples/ directory and the code itself.

License

Copyright 2019 - Manuel Olguín Muñoz.

Licensed under an MIT license, see LICENSE for details.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ganglion-biosensing-0.1.1.tar.gz (6.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ganglion_biosensing-0.1.1-py3-none-any.whl (9.1 kB view details)

Uploaded Python 3

File details

Details for the file ganglion-biosensing-0.1.1.tar.gz.

File metadata

  • Download URL: ganglion-biosensing-0.1.1.tar.gz
  • Upload date:
  • Size: 6.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.4.2 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.7.3

File hashes

Hashes for ganglion-biosensing-0.1.1.tar.gz
Algorithm Hash digest
SHA256 ddb730663d4f84a3464993815926cce5d5811ef70b3b2bc0016b2379f65c1d6d
MD5 7721e95d6d7a7b723dd3c2ad289d81f3
BLAKE2b-256 2bfa88082bed26ccb743dddd3bcc2ee0e4e18c8221675b39d687667f1bfcf904

See more details on using hashes here.

File details

Details for the file ganglion_biosensing-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: ganglion_biosensing-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 9.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.4.2 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.7.3

File hashes

Hashes for ganglion_biosensing-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 3ccc551fbff24189179592ca95c83515d4273e31e367b301e8c6282206fadeae
MD5 3487e9ab4f6840bc1b5f56ac998af071
BLAKE2b-256 cad8b38acb9c99a69347677687b4b5325236043a765d25bdf4fb8eb70b0b97bf

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page