Request to enable or disable a connection keep-alive to the remote device.
#include <btapi/btgattsrv.h>
int bt_gatt_srv_set_keepalive(int instance, const char *addr, uint8_t type, uint8_t enabled)
BlackBerry 10.2.0
The instance number representing the local GATT service.
The address of the remote device to which the connection update request is to be sent.
The device type identifier. Refer to constants prefixed with BT_DEVICE_TYPE_.
A value of 1 will enable notification support. A value of 0 will disable notification support.
This function should only be used when the service that enables it knows that the connection to the remote device must remain active. If the keep-alive is enabled, the GATT connection will remain open until either the keep-alive is disabled or the remote device closes the connection. Caution should be used to ensure that the keep-alive is used for services that are actively used by the remote device; otherwise the connection may remain open and never disconnect.