seos_profile.h 1.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. #pragma once
  2. #include <furi_ble/profile_interface.h>
  3. #include "seos_service.h"
  4. #ifdef __cplusplus
  5. extern "C" {
  6. #endif
  7. #define BLE_PROFILE_SEOS_PACKET_SIZE_MAX BLE_SVC_SEOS_DATA_LEN_MAX
  8. /** Seos service callback type */
  9. typedef SeosServiceEventCallback FuriHalBtSeosCallback;
  10. /** Seos profile descriptor */
  11. extern const FuriHalBleProfileTemplate* ble_profile_seos;
  12. /** Send data through BLE
  13. *
  14. * @param profile Profile instance
  15. * @param data data buffer
  16. * @param size data buffer size
  17. *
  18. * @return true on success
  19. */
  20. bool ble_profile_seos_tx(FuriHalBleProfileBase* profile, uint8_t* data, uint16_t size);
  21. /** Set Seos service events callback
  22. *
  23. * @param profile Profile instance
  24. * @param buffer_size Applicaition buffer size
  25. * @param calback FuriHalBtSeosCallback instance
  26. * @param context pointer to context
  27. */
  28. void ble_profile_seos_set_event_callback(
  29. FuriHalBleProfileBase* profile,
  30. uint16_t buff_size,
  31. FuriHalBtSeosCallback callback,
  32. void* context);
  33. #ifdef __cplusplus
  34. }
  35. #endif