4 #define GPIO_PIN_RCSIGNAL_RX hardware_pin(HARDWARE_serial_rx)
5 #define GPIO_PIN_RCSIGNAL_TX hardware_pin(HARDWARE_serial_tx)
6 #define GPIO_PIN_SERIAL1_RX hardware_pin(HARDWARE_serial1_rx)
7 #define GPIO_PIN_SERIAL1_TX hardware_pin(HARDWARE_serial1_tx)
10 #define GPIO_PIN_BUSY hardware_pin(HARDWARE_radio_busy)
11 #define GPIO_PIN_BUSY_2 hardware_pin(HARDWARE_radio_busy_2)
12 #define GPIO_PIN_DIO0 hardware_pin(HARDWARE_radio_dio0)
13 #define GPIO_PIN_DIO0_2 hardware_pin(HARDWARE_radio_dio0_2)
14 #define GPIO_PIN_DIO1 hardware_pin(HARDWARE_radio_dio1)
15 #define GPIO_PIN_DIO1_2 hardware_pin(HARDWARE_radio_dio1_2)
16 #define GPIO_PIN_DIO2 hardware_pin(HARDWARE_radio_dio2)
17 #define GPIO_PIN_MISO hardware_pin(HARDWARE_radio_miso)
18 #define GPIO_PIN_MOSI hardware_pin(HARDWARE_radio_mosi)
19 #define GPIO_PIN_NSS hardware_pin(HARDWARE_radio_nss)
20 #define GPIO_PIN_NSS_2 hardware_pin(HARDWARE_radio_nss_2)
21 #define GPIO_PIN_RST hardware_pin(HARDWARE_radio_rst)
22 #define GPIO_PIN_RST_2 hardware_pin(HARDWARE_radio_rst_2)
23 #define GPIO_PIN_SCK hardware_pin(HARDWARE_radio_sck)
24 #define USE_HARDWARE_DCDC
25 #define OPT_USE_HARDWARE_DCDC hardware_flag(HARDWARE_radio_dcdc)
26 #define USE_SX1276_RFO_HF
27 #define OPT_USE_SX1276_RFO_HF hardware_flag(HARDWARE_radio_rfo_hf)
28 #define LR1121_RFSW_CTRL hardware_u16_array(HARDWARE_radio_rfsw_ctrl)
29 #define LR1121_RFSW_CTRL_COUNT hardware_int(HARDWARE_radio_rfsw_ctrl_count)
32 #define GPIO_PIN_ANT_CTRL hardware_pin(HARDWARE_ant_ctrl)
33 #define GPIO_PIN_ANT_CTRL_COMPL hardware_pin(HARDWARE_ant_ctrl_compl)
36 #define GPIO_PIN_PA_ENABLE hardware_pin(HARDWARE_power_enable)
37 #define GPIO_PIN_RFamp_APC1 hardware_pin(HARDWARE_power_apc1)
38 #define GPIO_PIN_RFamp_APC2 hardware_pin(HARDWARE_power_apc2)
39 #define GPIO_PIN_RX_ENABLE hardware_pin(HARDWARE_power_rxen)
40 #define GPIO_PIN_TX_ENABLE hardware_pin(HARDWARE_power_txen)
41 #define GPIO_PIN_RX_ENABLE_2 hardware_pin(HARDWARE_power_rxen_2)
42 #define GPIO_PIN_TX_ENABLE_2 hardware_pin(HARDWARE_power_txen_2)
43 #define LBT_RSSI_THRESHOLD_OFFSET_DB hardware_int(HARDWARE_power_lna_gain)
44 #define MinPower (PowerLevels_e)hardware_int(HARDWARE_power_min)
45 #define MaxPower (PowerLevels_e)hardware_int(HARDWARE_power_max)
46 #define DefaultPower (PowerLevels_e)hardware_int(HARDWARE_power_default)
48 // default value 0 means direct!
49 #define POWER_OUTPUT_DACWRITE (hardware_int(HARDWARE_power_control)==3)
50 #define POWER_OUTPUT_VALUES hardware_i16_array(HARDWARE_power_values)
51 #define POWER_OUTPUT_VALUES_COUNT hardware_int(HARDWARE_power_values_count)
52 #define POWER_OUTPUT_VALUES2 hardware_i16_array(HARDWARE_power_values2)
53 #define POWER_OUTPUT_VALUES_DUAL hardware_i16_array(HARDWARE_power_values_dual)
54 #define POWER_OUTPUT_VALUES_DUAL_COUNT hardware_int(HARDWARE_power_values_dual_count)
57 #define GPIO_PIN_BUTTON hardware_pin(HARDWARE_button)
58 #define GPIO_PIN_BUTTON2 UNDEF_PIN
61 #define GPIO_PIN_LED_RED hardware_pin(HARDWARE_led)
62 #define GPIO_LED_RED_INVERTED hardware_pin(HARDWARE_led_red_invert)
63 #define GPIO_PIN_LED_BLUE UNDEF_PIN
64 #define GPIO_LED_BLUE_INVERTED false
65 #define GPIO_PIN_LED_GREEN UNDEF_PIN
66 #define GPIO_LED_GREEN_INVERTED false
68 #define GPIO_PIN_LED_WS2812 hardware_pin(HARDWARE_led_rgb)
69 #define OPT_WS2812_IS_GRB hardware_flag(HARDWARE_led_rgb_isgrb)
70 #define WS2812_STATUS_LEDS hardware_i16_array(HARDWARE_ledidx_rgb_status)
71 #define WS2812_STATUS_LEDS_COUNT hardware_int(HARDWARE_ledidx_rgb_status_count)
72 #define WS2812_VTX_STATUS_LEDS hardware_i16_array(HARDWARE_ledidx_rgb_vtx)
73 #define WS2812_VTX_STATUS_LEDS_COUNT hardware_int(HARDWARE_ledidx_rgb_vtx_count)
74 #define WS2812_BOOT_LEDS hardware_i16_array(HARDWARE_ledidx_rgb_boot)
75 #define WS2812_BOOT_LEDS_COUNT hardware_int(HARDWARE_ledidx_rgb_boot_count)
78 #define GPIO_PIN_SCL hardware_pin(HARDWARE_i2c_scl)
79 #define GPIO_PIN_SDA hardware_pin(HARDWARE_i2c_sda)
82 #define GPIO_PIN_PWM_OUTPUTS hardware_i16_array(HARDWARE_pwm_outputs)
83 #define GPIO_PIN_PWM_OUTPUTS_COUNT hardware_int(HARDWARE_pwm_outputs_count)
86 #define USE_ANALOG_VBAT
87 #define GPIO_ANALOG_VBAT hardware_pin(HARDWARE_vbat)
88 #define ANALOG_VBAT_OFFSET hardware_int(HARDWARE_vbat_offset)
89 #define ANALOG_VBAT_SCALE hardware_int(HARDWARE_vbat_scale)
91 #if defined(PLATFORM_ESP32)
95 #define OPT_HAS_VTX_SPI (hardware_pin(HARDWARE_vtx_nss) != UNDEF_PIN)
96 #define GPIO_PIN_RF_AMP_PWM hardware_pin(HARDWARE_vtx_amp_pwm)
97 #define GPIO_PIN_RF_AMP_VPD hardware_pin(HARDWARE_vtx_amp_vpd)
98 #define GPIO_PIN_RF_AMP_VREF hardware_pin(HARDWARE_vtx_amp_vref)
99 #define GPIO_PIN_SPI_VTX_NSS hardware_pin(HARDWARE_vtx_nss)
100 #define GPIO_PIN_SPI_VTX_MISO hardware_pin(HARDWARE_vtx_miso)
101 #define GPIO_PIN_SPI_VTX_MOSI hardware_pin(HARDWARE_vtx_mosi)
102 #define GPIO_PIN_SPI_VTX_SCK hardware_pin(HARDWARE_vtx_sck)
103 #define VPD_VALUES_25MW hardware_u16_array(HARDWARE_vtx_amp_vpd_25mW)
104 #define VPD_VALUES_100MW hardware_u16_array(HARDWARE_vtx_amp_vpd_100mW)
105 #define PWM_VALUES_25MW hardware_u16_array(HARDWARE_vtx_amp_pwm_25mW)
106 #define PWM_VALUES_100MW hardware_u16_array(HARDWARE_vtx_amp_pwm_100mW)
109 #define GPIO_PIN_FAN_EN hardware_pin(HARDWARE_misc_fan_en)