mirror of
https://github.com/DarkFlippers/unleashed-firmware
synced 2024-12-19 09:13:11 +00:00
26 lines
775 B
C
26 lines
775 B
C
|
#pragma once
|
||
|
|
||
|
#include <api-hal.h>
|
||
|
|
||
|
typedef struct SubGhzWorker SubGhzWorker;
|
||
|
|
||
|
typedef void (*SubGhzWorkerOverrunCallback)(void* context);
|
||
|
|
||
|
typedef void (*SubGhzWorkerPairCallback)(void* context, LevelPair pair);
|
||
|
|
||
|
void subghz_worker_rx_callback(ApiHalSubGhzCaptureLevel level, uint32_t duration, void* context);
|
||
|
|
||
|
SubGhzWorker* subghz_worker_alloc();
|
||
|
|
||
|
void subghz_worker_free(SubGhzWorker* instance);
|
||
|
|
||
|
void subghz_worker_set_overrun_callback(SubGhzWorker* instance, SubGhzWorkerOverrunCallback callback);
|
||
|
|
||
|
void subghz_worker_set_pair_callback(SubGhzWorker* instance, SubGhzWorkerPairCallback callback);
|
||
|
|
||
|
void subghz_worker_set_context(SubGhzWorker* instance, void* context);
|
||
|
|
||
|
void subghz_worker_start(SubGhzWorker* instance);
|
||
|
|
||
|
void subghz_worker_stop(SubGhzWorker* instance);
|