ble nano hid over gatt

Dependencies:   BLE_API mbed-dev nRF51822

Committer:
cho45
Date:
Thu Sep 15 09:31:05 2016 +0900
Revision:
86:e0fab77e669d
Parent:
58:64df960619ce
support consumer keys

Who changed what in which revision?

UserRevisionLine numberNew contents of line
cho45 29:ec548c473d50 1
cho45 29:ec548c473d50 2 #ifndef __HIDController_H__
cho45 29:ec548c473d50 3 #define __HIDController_H__
cho45 27:7370b8994603 4
cho45 27:7370b8994603 5 enum Status_t {
cho45 27:7370b8994603 6 DISCONNECTED,
cho45 27:7370b8994603 7 CONNECTING,
cho45 27:7370b8994603 8 CONNECTED,
cho45 32:6c0f43fda460 9 TIMEOUT,
cho45 32:6c0f43fda460 10 ADVERTISING,
cho45 32:6c0f43fda460 11 };
cho45 27:7370b8994603 12
cho45 6:f1c3ea8bc850 13 class HIDController {
cho45 6:f1c3ea8bc850 14 public:
cho45 6:f1c3ea8bc850 15 static void init();
cho45 10:1aed2481a743 16 static void waitForEvent();
cho45 20:d8840ac38434 17 static bool connected();
cho45 28:1f843a3daab0 18 static Status_t status();
cho45 32:6c0f43fda460 19 static const char* statusString();
cho45 44:916b70fd1c40 20
cho45 48:d6938de02f62 21 static void appendReportData(const uint8_t key);
cho45 48:d6938de02f62 22 static void deleteReportData(const uint8_t key);
cho45 86:e0fab77e669d 23 static void pressConsumerKey(const uint16_t key);
cho45 86:e0fab77e669d 24 static void releaseConsumerKey();
cho45 9:d1daefbf1fbd 25 static void queueCurrentReportData();
cho45 58:64df960619ce 26 static void updateBatteryLevel(const uint8_t percentage, const uint16_t voltage);
cho45 48:d6938de02f62 27 static void initializeConnection(const bool ignoreWhiteList);
cho45 6:f1c3ea8bc850 28 };
cho45 6:f1c3ea8bc850 29
cho45 44:916b70fd1c40 30 #endif