package
0.0.0-20160220151906-b268664a3e28
Repository: https://github.com/devicehive/iot-framework.git
Documentation: pkg.go.dev
# README
Example of using BLE and cloud parts of IoT framework. This is a simple wrapper around GATT protocol. You can connect to any BLE device with GATT implementation from DeviceHive server. This demo shows how to implement it. It awaits for commands from cloud and perfoms it. This demo can be used as dedicated application if you need to control BLE device from cloud.
Building
Run go build
Usage
Run application, then you can send commands from cloud. Command list:
connect
- connect to BLE devicescan/start
- start scanning, on each found device app will sendPeripheralDiscovered
notificationscan/stop
- stop scanninggatt/read
- read characteristicgatt/write
- write characteristicgatt/notifications
- subscribe on characteristic notification. On each BLE notificationNotificationReceived
cloud notification will be sentgatt/notifications/stop
- stop watching on characteristic notificationgatt/indications
- subscribe on characteristic indication. On each BLE indicationIndicationReceived
cloud notification will be sentgatt/indications/stop
- stop watching on characteristic indication
You can receive these notfications from app to cloud:
PeripheralDiscovered
- each time when app founds new BLE device in airPeripheralConnected
- when app succefuly connects to BLE devicePeripheralDisconnected
- when app lost connection with BLE device, including normal disconnect.NotificationReceived
- on each BLE notificationIndicationReceived
- on each BLE indication
# Functions
No description provided by the author
# Constants
No description provided by the author