Using Python to Store Data from many BLE Devices

BLE (Bluetooth Low Energy) sensor devices like the Hexiwear are great, but they cannot store a large amount of data. For a research project I have to collect data from many BLE devices for later processing. What I’m using is a Python script running on the Raspberry Pi which collects the data and stores it on a file:

Raspberry Pi with Python controlling a set of Hexiwear BLE Devices

Raspberry Pi with Python controlling a set of Hexiwear BLE Devices

Continue reading

Tutorial: Hexiwear Bluetooth Low Energy Packet Sniffing with Wireshark

For a university reasearch project I try to pair the Raspberry Pi 3 with a Mikroelektronika Hexiwear using BLE (Bluetooth Low Energy). Most of things worked after a lot of trial and error, but at a certain point I was stuck trying to write to send data from the Raspy to the BLE device.The Hexiwear BLE protocol description is very thin, so I ended up using a BLE sniffer to reverse engineer the protocol with Wireshark.

Sniffing BLE Packets between Raspy and Hexiwear

Hardware setup between Raspy and Hexiwear

Continue reading

Tutorial: BLE Pairing the Raspberry Pi 3 Model B with Hexiwear

The Hexiwear (see “Hexiwear: Teardown of the Hackable ‘Do-Anything’ Device“) is a small and portable sensor node with built-in BLE (Bluetooth Low Energy) transceiver. In a research project we try to use multiple Hexiwear in a classroom environment and to collect sensor data on a Raspberry Pi. The Raspberry Pi 3 Model B running Linux has an on-board BLE transceiver too, so why not binding them (wirelessly) together?

Raspberry Pi 3 connected with Hexiwear over BLE

Raspberry Pi 3 connected with Hexiwear over BLE

Well, things seemed easy at the beginning, and as always, there are many things to learn on a journey like this…

Continue reading