WS_Bluetooth.h 913 B

123456789101112131415161718192021222324252627
  1. #ifndef _WS_BLUETOOTH_H_
  2. #define _WS_BLUETOOTH_H_
  3. #include <BLEDevice.h>
  4. #include <BLEUtils.h>
  5. #include <BLEServer.h>
  6. #include "WS_GPIO.h"
  7. #define SERVICE_UUID "ce6c0b18-8df3-4bb8-ad41-350525ac1cd5"
  8. #define INFO_CHARACTERISTIC_UUID "eef4182c-f870-4785-9fb1-635182936e54"
  9. //#define ADDRESS_CHARACTERISTIC_UUID "a8b8b6ff-1b1f-46f7-a590-cee5f3e88037"
  10. //#define STATUS_CHARACTERISTIC_UUID "9bb2f9fa-7e59-43a4-9c43-736bb508e096"
  11. #define COMMAND_CHARACTERISTIC_UUID "447c1982-77ef-49be-a39a-2920f33c31e5"
  12. #define Bluetooth_Mode 2
  13. extern std::string GetRelays();
  14. extern std::string GetContactInfo();
  15. extern std::string GetMacAddress();
  16. extern void SetContactInfo(std::string info);
  17. extern void SetRelays(std::string value);
  18. void SetStatus(char * Data);
  19. // Send data using Bluetooth
  20. void Bluetooth_Init();
  21. #endif