Turn your ARM Linux device (e.g. BeagleBone, Raspberry Pi, Orange Pi) into an iBeacon and Bluetooth Low Energy peripheral with Swift. Includes iOS app for interacting with the peripheral via Bluetooth.
Install Carthage dependencies
carthage update
- Install Swift 3.0 for ARM Linux, make sure to use 2016-09-26 build.
- Install
BluetoothLinux
dependencies. - Clone and Build (will generate errors)
git clone https://github.com/colemancda/DemoPeripheral
cd DemoPeripheral
swift build
- Patch code, in
Packages/CStatfs-1.0.0/module.modulemap
replacex86_64-linux-gnu
witharm-linux-gnueabihf
- Build and run
swift build
sudo .build/debug/Peripheral
You should see the following in your console
Starting Peripheral Daemon...
Peripheral: Started GATT Server
Initialized Peripheral 0bd6311b-d0c9-425c-928b-89cc5bc0170c
You can also explore with LightBlue.