Loading...
Searching...
No Matches
devices.h
1#pragma once
2
3#include "types.h"
4
5#ifdef __cplusplus
6extern "C" {
7#endif
8
9typedef struct SubGhzDevice SubGhzDevice;
10
11void subghz_devices_init(void);
12void subghz_devices_deinit(void);
13
14const SubGhzDevice* subghz_devices_get_by_name(const char* device_name);
15const char* subghz_devices_get_name(const SubGhzDevice* device);
16bool subghz_devices_begin(const SubGhzDevice* device);
17void subghz_devices_end(const SubGhzDevice* device);
18bool subghz_devices_is_connect(const SubGhzDevice* device);
19void subghz_devices_reset(const SubGhzDevice* device);
20void subghz_devices_sleep(const SubGhzDevice* device);
21void subghz_devices_idle(const SubGhzDevice* device);
22void subghz_devices_load_preset(
23 const SubGhzDevice* device,
24 FuriHalSubGhzPreset preset,
25 uint8_t* preset_data);
26uint32_t subghz_devices_set_frequency(const SubGhzDevice* device, uint32_t frequency);
27bool subghz_devices_is_frequency_valid(const SubGhzDevice* device, uint32_t frequency);
28void subghz_devices_set_async_mirror_pin(const SubGhzDevice* device, const GpioPin* gpio);
29const GpioPin* subghz_devices_get_data_gpio(const SubGhzDevice* device);
30
31bool subghz_devices_set_tx(const SubGhzDevice* device);
32void subghz_devices_flush_tx(const SubGhzDevice* device);
33bool subghz_devices_start_async_tx(const SubGhzDevice* device, void* callback, void* context);
34bool subghz_devices_is_async_complete_tx(const SubGhzDevice* device);
35void subghz_devices_stop_async_tx(const SubGhzDevice* device);
36
37void subghz_devices_set_rx(const SubGhzDevice* device);
38void subghz_devices_flush_rx(const SubGhzDevice* device);
39void subghz_devices_start_async_rx(const SubGhzDevice* device, void* callback, void* context);
40void subghz_devices_stop_async_rx(const SubGhzDevice* device);
41
42float subghz_devices_get_rssi(const SubGhzDevice* device);
43uint8_t subghz_devices_get_lqi(const SubGhzDevice* device);
44
45bool subghz_devices_rx_pipe_not_empty(const SubGhzDevice* device);
46bool subghz_devices_is_rx_data_crc_valid(const SubGhzDevice* device);
47void subghz_devices_read_packet(const SubGhzDevice* device, uint8_t* data, uint8_t* size);
48void subghz_devices_write_packet(const SubGhzDevice* device, const uint8_t* data, uint8_t size);
49
50#ifdef __cplusplus
51}
52#endif
Gpio structure.
Definition furi_hal_gpio.h:161
Definition devices/types.h:88