nRF Connect SDK API 2.8.99
Loading...
Searching...
No Matches

◆ bt_lbs_init()

int bt_lbs_init ( struct bt_lbs_cb * callbacks)

#include <include/bluetooth/services/lbs.h>

Initialize the LBS Service.

This function registers a GATT service with two characteristics: Button and LED. Send notifications for the Button Characteristic to let connected peers know when the button state changes. Write to the LED Characteristic to change the state of the LED on the board.

Parameters
[in]callbacksStruct containing pointers to callback functions used by the service. This pointer can be NULL if no callback functions are defined.
Return values
0If the operation was successful. Otherwise, a (negative) error code is returned.