diff --git a/src/main/drivers/uart_inverter.c b/src/main/drivers/uart_inverter.c index b815883df79..5168831b471 100644 --- a/src/main/drivers/uart_inverter.c +++ b/src/main/drivers/uart_inverter.c @@ -145,7 +145,12 @@ void uartInverterSet(USART_TypeDef *USARTx, uartInverterLine_e line, bool enable // UART4 #if defined(INVERTER_PIN_UART4_RX) || defined(INVERTER_PIN_UART4_TX) - if (USARTx == USART4) { +#if defined(STM32F4) + if (USARTx == UART4) +#else + if (USARTx == USART4) +#endif + { #if defined(INVERTER_PIN_UART4_RX) rx_pin = IOGetByTag(IO_TAG(INVERTER_PIN_UART4_RX)); #endif diff --git a/src/main/target/TUNERCF405/target.h b/src/main/target/TUNERCF405/target.h index f193377c6ea..b359545e697 100644 --- a/src/main/target/TUNERCF405/target.h +++ b/src/main/target/TUNERCF405/target.h @@ -103,6 +103,8 @@ #define USE_UART4 #define UART4_RX_PIN PA1 #define UART4_TX_PIN PA0 +#define USE_UART_INVERTER +#define INVERTER_PIN_UART4_RX PC14 #define USE_UART5 #define UART5_RX_PIN PD2