ble_hid_svc.h 617 B

1234567891011121314151617181920212223242526272829
  1. #pragma once
  2. #include <stdint.h>
  3. #include <stdbool.h>
  4. #ifdef __cplusplus
  5. extern "C" {
  6. #endif
  7. typedef struct BleServiceHid BleServiceHid;
  8. BleServiceHid* ble_svc_hid_start();
  9. void ble_svc_hid_stop(BleServiceHid* service);
  10. bool ble_svc_hid_update_report_map(BleServiceHid* service, const uint8_t* data, uint16_t len);
  11. bool ble_svc_hid_update_input_report(
  12. BleServiceHid* service,
  13. uint8_t input_report_num,
  14. uint8_t* data,
  15. uint16_t len);
  16. // Expects data to be of length BLE_SVC_HID_INFO_LEN (4 bytes)
  17. bool ble_svc_hid_update_info(BleServiceHid* service, uint8_t* data);
  18. #ifdef __cplusplus
  19. }
  20. #endif