BTZen - Bluetooh Smart sensor reading library
Project description
Library to read data from Bluetooth Smart sensors.
Features
Devices and sensor readings
SensorTag (CC2541DK, CC2650STK)
temperature
pressure
humidity
light (CC2541DK only)
gyroscope, accelerometer (CC2541DK only)
Sensor data access using asyncio coroutines.
Please update your sensor device to its latest firmware.
To use the library, run bluetoothd with -E option. Then as root:
$ hciconfig hci0 up $ hcitool lescan $ hcitool lecc <MAC>
To extend SensorTag battery life:
$ hcitool lecup --handle=<HANDLE> --min 6 --max 100 --timeout 1000 --latency 0
Please note, that above command will make single sensor read to last about 250ms. Therefore reading 4 sensors will take about 1s.
The library provides btzen script to display sensor data:
$ btzen <MAC>
Requirements
bluez 5.36
Python 3.5
Python D-Bus bindings
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.