Skip to main content

revolution-python-api

Project description

The BITalino (R)evolution Python API provides the needed tools to interact with BITalino (R)evolution using Python.

Installation

pip install bitalino

Usage Example

use your macAddress:

# This example will collect data for 5 sec.
macAddress = "00:00:00:00:00:00"
# macAddress = "/dev/tty.BITalino-XX-XX-DevB" # on Mac OS replace XX-XX by the 4 final digits of the MAC address
running_time = 5

batteryThreshold = 30
acqChannels = [0, 1, 2, 3, 4, 5]
samplingRate = 1000
nSamples = 10
digitalOutput = [1,1]

# Connect to BITalino
device = BITalino(macAddress)

# Set battery threshold
device.battery(batteryThreshold)

# Read BITalino version
print(device.version())

# Start Acquisition
device.start(samplingRate, acqChannels)

start = time.time()
end = time.time()
while (end - start) < running_time:
        # Read samples
        print(device.read(nSamples))
        end = time.time()

# Turn BITalino led on
device.trigger(digitalOutput)

# Stop acquisition
device.stop()

# Close connection
device.close()

Project details


Release history Release notifications

This version
History Node

1.1

History Node

1.0

History Node

0.6

History Node

0.5

History Node

0.1

Download files

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

Filename, size & hash SHA256 hash help File type Python version Upload date
bitalino-1.1-py2-none-any.whl (9.2 kB) Copy SHA256 hash SHA256 Wheel py2 Feb 14, 2018
bitalino-1.1-py2.py3-none-any.whl (9.2 kB) Copy SHA256 hash SHA256 Wheel py2.py3 Feb 14, 2018
bitalino-1.1.zip (10.5 kB) Copy SHA256 hash SHA256 Source None Feb 14, 2018

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging CloudAMQP CloudAMQP RabbitMQ AWS AWS Cloud computing Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page