Skip to main content

API for the bluetooth Attys DAQ box (www.attys.tech)

Project description

Attys is a lightweight wearable bluetooth data acquisition box which can measure anything from temperature to ECG.

It’s cross platform and runs under Linux and Windows

It has two 24 bit analogue channels, an accelerometer and a magnetometer.

http://www.attys.tech

Required packages under Linux

For Ubuntu Linux install libbluetooth-dev and swig:

sudo apt-get install libbluetooth-dev swig

Quick start guide

Here are the basic steps how to use the API:

# load the module
import pyattyscomm

# Gets the AttysScan class which scans for Attys via bluetooth
s = pyattyscomm.AttysScan()

# Scan for Attys
s.scan()

# get the 1st Attys
c = s.getAttysComm(0)

# create a datacallback
class AttysCommCallback(pyattyscomm.SampleCallback):
  def hasSample(self,t,v):
    print(t,v) # so more than just printing!

cb = AttysCommCallback()

pyattyscomm.connectCallback(c,cb)

# Start data acquisition in the background
c.start()

# sleep here or start a GUI

# end the acqu
c.quit()

API documentation

Query it via the python help system:

import pyattyscomm
help(pyattyscomm)

The Python classes have been generated with SWIG. The header files AttysComm.h, AttysCommBase,h and AttysScan.h provide detailed info about the classes:

https://github.com/glasgowneuro/attys-comm

Demos

On github are python examples which show you how to plot realtime data from the Attys: https://github.com/glasgowneuro/attys-comm/tree/master/examples

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

pyattyscomm-2.1.1.tar.gz (48.6 kB view hashes)

Uploaded Source

Built Distributions

pyattyscomm-2.1.1-py3.11-win-amd64.egg (100.7 kB view hashes)

Uploaded Source

pyattyscomm-2.1.1-py3.10-win-amd64.egg (106.0 kB view hashes)

Uploaded Source

pyattyscomm-2.1.1-cp311-cp311-win_amd64.whl (91.6 kB view hashes)

Uploaded CPython 3.11 Windows x86-64

pyattyscomm-2.1.1-cp310-cp310-win_amd64.whl (100.4 kB view hashes)

Uploaded CPython 3.10 Windows x86-64

Supported by

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