mirror of
https://github.com/lemmingDev/ESP32-BLE-Gamepad.git
synced 2026-03-06 08:14:46 +01:00
25 lines
622 B
C++
25 lines
622 B
C++
#ifndef ESP32_BLE_CONNECTION_STATUS_H
|
|
#define ESP32_BLE_CONNECTION_STATUS_H
|
|
#include "sdkconfig.h"
|
|
#if defined(CONFIG_BT_ENABLED)
|
|
|
|
#include "nimconfig.h"
|
|
#if defined(CONFIG_BT_NIMBLE_ROLE_PERIPHERAL)
|
|
|
|
#include <NimBLEServer.h>
|
|
#include "NimBLECharacteristic.h"
|
|
|
|
class BleConnectionStatus : public NimBLEServerCallbacks
|
|
{
|
|
public:
|
|
BleConnectionStatus(void);
|
|
bool connected = false;
|
|
void onConnect(NimBLEServer* pServer);
|
|
void onDisconnect(NimBLEServer* pServer);
|
|
NimBLECharacteristic* inputGamepad;
|
|
};
|
|
|
|
#endif // CONFIG_BT_NIMBLE_ROLE_PERIPHERAL
|
|
#endif // CONFIG_BT_ENABLED
|
|
#endif // ESP32_BLE_CONNECTION_STATUS_H
|