Merge branch 'master' into change-to-sending-expresslrs_RFrates_e-in-sync-packet
[ExpressLRS.git] / src / lib / RFAMP / RFAMP_hal.h
blob34a9824aceec575bc03fbb192283f38fea91ed98
1 #pragma once
3 #include "SX12xxDriverCommon.h"
4 #include <targets.h>
6 class RFAMP_hal
8 public:
9 static RFAMP_hal *instance;
11 RFAMP_hal();
13 void init();
14 void ICACHE_RAM_ATTR TXenable(SX12XX_Radio_Number_t radioNumber);
15 void ICACHE_RAM_ATTR RXenable();
16 void ICACHE_RAM_ATTR TXRXdisable();
18 private:
19 #if defined(PLATFORM_ESP32)
20 uint64_t txrx_disable_clr_bits;
21 uint64_t tx1_enable_set_bits;
22 uint64_t tx1_enable_clr_bits;
23 uint64_t tx2_enable_set_bits;
24 uint64_t tx2_enable_clr_bits;
25 uint64_t tx_all_enable_set_bits;
26 uint64_t tx_all_enable_clr_bits;
27 uint64_t rx_enable_set_bits;
28 uint64_t rx_enable_clr_bits;
29 #else
30 bool rx_enabled;
31 bool tx1_enabled;
32 bool tx2_enabled;
33 #endif