//kotlin-sdk/fr.gasmartbuilding.gasmartaccessreadersdk/PeripheralManager
PeripheralManager
class PeripheralManager(flowAppSDK: GASmartAccessReaderSDK, context: Context, callbacks: GASmartAccessReaderCallbacks)
Manages BLE peripheral functionalities within the GASmartAccessReaderSDK.
Responsibilities:
- Initialize and manage BLE GATT services and characteristics.
- Handle BLE advertising start, stop, and callbacks.
- Handle incoming write requests to characteristics and respond accordingly.
- Monitor and log BLE connection state changes.
Note: Requires relevant Bluetooth permissions to function properly.
Parameters
androidJvm
flowAppSDK | Reference to the parent SDK for utility functions. |
context | Application context required for system services and permission checks. |
Constructors
PeripheralManager | [androidJvm] constructor(flowAppSDK: GASmartAccessReaderSDK, context: Context, callbacks: GASmartAccessReaderCallbacks) |
Types
Name | Summary |
---|---|
Companion | [androidJvm] object Companion |
Functions
Name | Summary |
---|---|
startAdvertising | [androidJvm] fun startAdvertising(context: Context) Starts BLE advertising and sets up the GATT server. |
stopAdvertising | [androidJvm] fun stopAdvertising(context: Context) Stops BLE advertising. |