1 #define TARGET_UNIFIED_RX
3 // DEVICE_NAME is not defined here because we get it from the SPIFFS file system
8 // GPIO_PIN_BLUETOOTH_EN
9 // GPIO_PIN_UART1RX_INVERT
10 // GPIO_PIN_UART1TX_INVERT
11 // GPIO_PIN_UART3RX_INVERT
14 // TARGET_RX_GHOST_ATTO_V1
16 // TARGET_TX_GHOST_LITE
17 // GPIO_PIN_RF_AMP_DET // unused
20 // GPIO_PIN_VRF1 // unused
21 // GPIO_PIN_VRF2 // unused
22 // GPIO_PIN_SWR // unused
27 // // various (unused)
34 // ====================================
38 #define GPIO_PIN_RCSIGNAL_RX hardware_pin(HARDWARE_serial_rx)
39 #define GPIO_PIN_RCSIGNAL_TX hardware_pin(HARDWARE_serial_tx)
40 #define GPIO_PIN_SERIAL1_RX hardware_pin(HARDWARE_serial1_rx)
41 #define GPIO_PIN_SERIAL1_TX hardware_pin(HARDWARE_serial1_tx)
44 #define GPIO_PIN_BUSY hardware_pin(HARDWARE_radio_busy)
45 #define GPIO_PIN_BUSY_2 hardware_pin(HARDWARE_radio_busy_2)
46 #define GPIO_PIN_DIO0 hardware_pin(HARDWARE_radio_dio0)
47 #define GPIO_PIN_DIO0_2 hardware_pin(HARDWARE_radio_dio0_2)
48 #define GPIO_PIN_DIO1 hardware_pin(HARDWARE_radio_dio1)
49 #define GPIO_PIN_DIO1_2 hardware_pin(HARDWARE_radio_dio1_2)
50 #define GPIO_PIN_DIO2 hardware_pin(HARDWARE_radio_dio2)
51 #define GPIO_PIN_MISO hardware_pin(HARDWARE_radio_miso)
52 #define GPIO_PIN_MOSI hardware_pin(HARDWARE_radio_mosi)
53 #define GPIO_PIN_NSS hardware_pin(HARDWARE_radio_nss)
54 #define GPIO_PIN_NSS_2 hardware_pin(HARDWARE_radio_nss_2)
55 #define GPIO_PIN_RST hardware_pin(HARDWARE_radio_rst)
56 #define GPIO_PIN_RST_2 hardware_pin(HARDWARE_radio_rst_2)
57 #define GPIO_PIN_SCK hardware_pin(HARDWARE_radio_sck)
58 #define USE_HARDWARE_DCDC
59 #define OPT_USE_HARDWARE_DCDC hardware_flag(HARDWARE_radio_dcdc)
60 #define USE_SX1276_RFO_HF
61 #define OPT_USE_SX1276_RFO_HF hardware_flag(HARDWARE_radio_rfo_hf)
62 #define LR1121_RFSW_CTRL hardware_u16_array(HARDWARE_radio_rfsw_ctrl)
63 #define LR1121_RFSW_CTRL_COUNT hardware_int(HARDWARE_radio_rfsw_ctrl_count)
66 #define GPIO_PIN_ANT_CTRL hardware_pin(HARDWARE_ant_ctrl)
67 #define GPIO_PIN_ANT_CTRL_COMPL hardware_pin(HARDWARE_ant_ctrl_compl)
70 #define GPIO_PIN_PA_ENABLE hardware_pin(HARDWARE_power_enable)
71 #define GPIO_PIN_RFamp_APC1 hardware_pin(HARDWARE_power_apc1)
72 #define GPIO_PIN_RFamp_APC2 hardware_pin(HARDWARE_power_apc2)
73 #define GPIO_PIN_RX_ENABLE hardware_pin(HARDWARE_power_rxen)
74 #define GPIO_PIN_TX_ENABLE hardware_pin(HARDWARE_power_txen)
75 #define GPIO_PIN_RX_ENABLE_2 hardware_pin(HARDWARE_power_rxen_2)
76 #define GPIO_PIN_TX_ENABLE_2 hardware_pin(HARDWARE_power_txen_2)
77 #define LBT_RSSI_THRESHOLD_OFFSET_DB hardware_int(HARDWARE_power_lna_gain)
78 #define MinPower (PowerLevels_e)hardware_int(HARDWARE_power_min)
79 #define HighPower (PowerLevels_e)hardware_int(HARDWARE_power_high)
80 #define MaxPower (PowerLevels_e)hardware_int(HARDWARE_power_max)
81 #define DefaultPower (PowerLevels_e)hardware_int(HARDWARE_power_default)
84 #define GPIO_PIN_PA_PDET hardware_pin(HARDWARE_power_pdet)
85 #define SKY85321_PDET_INTERCEPT hardware_float(HARDWARE_power_pdet_intercept)
86 #define SKY85321_PDET_SLOPE hardware_float(HARDWARE_power_pdet_slope)
88 // default value 0 means direct!
89 // #define POWER_OUTPUT_ANALOG (hardware_int(HARDWARE_power_control)==1) // frsky only
90 // #define POWER_OUTPUT_DAC (hardware_int(HARDWARE_power_control)==2) // stm32 only
91 #define POWER_OUTPUT_DACWRITE (hardware_int(HARDWARE_power_control)==3)
92 #define POWER_OUTPUT_FIXED -99
93 #define POWER_OUTPUT_VALUES hardware_i16_array(HARDWARE_power_values)
94 #define POWER_OUTPUT_VALUES2 hardware_i16_array(HARDWARE_power_values2)
95 #define POWER_OUTPUT_VALUES_DUAL hardware_i16_array(HARDWARE_power_values_dual)
98 #define GPIO_PIN_BUTTON hardware_pin(HARDWARE_button)
101 #define GPIO_PIN_LED hardware_pin(HARDWARE_led)
102 #define GPIO_PIN_LED_BLUE hardware_pin(HARDWARE_led_blue)
103 #define GPIO_LED_BLUE_INVERTED hardware_pin(HARDWARE_led_blue_invert)
104 #define GPIO_PIN_LED_GREEN hardware_pin(HARDWARE_led_green)
105 #define GPIO_LED_GREEN_INVERTED hardware_flag(HARDWARE_led_green_invert)
106 #define GPIO_PIN_LED_GREEN_RED hardware_pin(HARDWARE_led_green_red)
107 #define GPIO_PIN_LED_RED hardware_pin(HARDWARE_led_red)
108 #define GPIO_LED_RED_INVERTED hardware_pin(HARDWARE_led_red_invert)
109 #define GPIO_PIN_LED_RED_GREEN hardware_pin(HARDWARE_led_red_green)
110 #define GPIO_PIN_LED_WS2812 hardware_pin(HARDWARE_led_rgb)
111 // #define GPIO_PIN_LED_WS2812_FAST // stm32
112 #define WS2812_IS_GRB
113 #define OPT_WS2812_IS_GRB hardware_flag(HARDWARE_led_rgb_isgrb)
114 #define WS2812_STATUS_LEDS hardware_i16_array(HARDWARE_ledidx_rgb_status)
115 #define WS2812_STATUS_LEDS_COUNT hardware_int(HARDWARE_ledidx_rgb_status_count)
116 #define WS2812_VTX_STATUS_LEDS hardware_i16_array(HARDWARE_ledidx_rgb_vtx)
117 #define WS2812_VTX_STATUS_LEDS_COUNT hardware_int(HARDWARE_ledidx_rgb_vtx_count)
118 #define WS2812_BOOT_LEDS hardware_i16_array(HARDWARE_ledidx_rgb_boot)
119 #define WS2812_BOOT_LEDS_COUNT hardware_int(HARDWARE_ledidx_rgb_boot_count)
122 #define GPIO_PIN_SCL hardware_pin(HARDWARE_i2c_scl)
123 #define GPIO_PIN_SDA hardware_pin(HARDWARE_i2c_sda)
126 #define GPIO_PIN_PWM_OUTPUTS hardware_i16_array(HARDWARE_pwm_outputs)
127 #define GPIO_PIN_PWM_OUTPUTS_COUNT hardware_int(HARDWARE_pwm_outputs_count)
130 #define USE_ANALOG_VBAT
131 #define GPIO_ANALOG_VBAT hardware_pin(HARDWARE_vbat)
132 #define ANALOG_VBAT_OFFSET hardware_int(HARDWARE_vbat_offset)
133 #define ANALOG_VBAT_SCALE hardware_int(HARDWARE_vbat_scale)
135 #if defined(PLATFORM_ESP32)
139 #define OPT_HAS_VTX_SPI (hardware_pin(HARDWARE_vtx_nss) != UNDEF_PIN)
140 #define GPIO_PIN_RF_AMP_PWM hardware_pin(HARDWARE_vtx_amp_pwm)
141 #define GPIO_PIN_RF_AMP_VPD hardware_pin(HARDWARE_vtx_amp_vpd)
142 #define GPIO_PIN_RF_AMP_VREF hardware_pin(HARDWARE_vtx_amp_vref)
143 #define GPIO_PIN_SPI_VTX_NSS hardware_pin(HARDWARE_vtx_nss)
144 #define GPIO_PIN_SPI_VTX_MISO hardware_pin(HARDWARE_vtx_miso)
145 #define GPIO_PIN_SPI_VTX_MOSI hardware_pin(HARDWARE_vtx_mosi)
146 #define GPIO_PIN_SPI_VTX_SCK hardware_pin(HARDWARE_vtx_sck)
147 #define VPD_VALUES_25MW hardware_u16_array(HARDWARE_vtx_amp_vpd_25mW)
148 #define VPD_VALUES_100MW hardware_u16_array(HARDWARE_vtx_amp_vpd_100mW)
149 #define PWM_VALUES_25MW hardware_u16_array(HARDWARE_vtx_amp_pwm_25mW)
150 #define PWM_VALUES_100MW hardware_u16_array(HARDWARE_vtx_amp_pwm_100mW)
153 #define GPIO_PIN_FAN_EN hardware_pin(HARDWARE_misc_fan_en)