nRF LBS (LED Button Service) BLE Client

App

nRF LBS (LED Button Service) BLE Client

Von balto · vef54708

Bewertung

5.0

Bewertungen

2

Downloads

100

Preis

Kostenlos

Im Connect IQ Store ansehen

Beschreibung

Connect IQ application client for Nordic nRF LBS (LED Button Service) BLE example, full source code available on https://github.com/fabiobaltieri/ciq-nrf-blinky. This datafield acts as a Bluetooth Low Energy client for the Nordic nRF LBS example application. The source code is on GitHub, this is meant to be provided as an example on how to use the Toybox::BluetoothLowEnergy Connect IQ module. It's similar to the NordicThingy52CoinCollector official sample, but the code is a bit simpler (well, it is to me anyway). The Bluetooth part is self contained in a single class, and since it uses the LBS peripheral, it's compatible with all Nordic development board, either with the nRF Blinky sample for nRF SDK, or the BLE LBS peripheral sample in the nRF Connect SDK (https://developer.nordicsemi.com/nRF_Connect_SDK/doc/latest/nrf/samples/bluetooth/peripheral_lbs/README.html). The Datafield scans for available BLE devices and look for one named "Nordic_LBS" or "Nordic_Blinky", once that is found scanning is disabled and the device gets paired. After pairing, the app enables notifications on the button characteristic and starts tracking the button status on the Notification callback. The button status is immediately updated internally, but only every second on the screen, so keep it pressed to check that on the device. The LED status is set to follow the recording status: if the device is recording the LED gets turned on. The datafield shows the connection status (searching, disconnected and connected), the API seems to handle reconnection automatically and notifies the application when pairing status changes. As this is provided as an example, the code has plenty of debugging prints. NOTE: I don't actually own (yet) a device capable of BLE connectivity, so this is only tested with the emulator with an nRF52DK board with the connectivity firmware. Drop me a comment if it works for you! :-)

Bewertung

Bewertungsartikel kommt bald.

Kompatible Geräte (170)

Instinct® 2Instinct® 2XInstinct® 2Instinct® CrossoverInstinct® 2SInstinct® 2Svívoactive® 3 Musicvívoactive® 3 MusicDescent™ MK2Descent™ MK2Descent™ Mk2SDescent™ Mk2SDescent™ MK3i - 51mmDescent™ MK3 - 43mmVenu® 2Venu® 2SVenu® 2 PlusVenu® 2Venu® 2 PlusVenu® 2S+150 mehr

Berechtigungen

BluetoothLowEnergy

Ähnlich

Related items