advertising a version number

This commit is contained in:
2025-11-12 18:07:54 +00:00
parent 8a992787df
commit f7dd083992
2 changed files with 40 additions and 0 deletions

View File

@@ -1,4 +1,22 @@
#ifndef BLEOTA
#define BLEOTA
#include <Arduino.h>
#include <BLEServer.h>
#define OTA_SERVICE_UUID "71a4438e-fd52-4b15-b3d2-ec0e3e56193b"
#define VERSION_NUMBER_UUID "1978a3df-c009-4837-b295-57ef429dde8c"
#define VERSION_NUMBER_DESCRIPTOR_UUID "1e0c35d1-ba03-4f4d-a99c-bac7664d95ed"
class BLEOTAClass {
public:
BLEOTAClass();
void begin(BLEServer* server, char* versionNumber = "1.0.0");
private:
BLEServer* _pServer;
char* _vNum;
BLECharacteristic* _pVersionNumber;
BLEDescriptor* _pVersionNumberDescriptor;
};
#endif /* BLEOTA */