Skip to content

Commit

Permalink
Revert "Enable/disable the UART TX before changing the TX pin mode (b…
Browse files Browse the repository at this point in the history
…etaflight#13018)"

This reverts commit bd68d3d.
  • Loading branch information
haslinghuis committed Sep 25, 2023
1 parent c630700 commit 88c9115
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/main/drivers/stm32/serial_uart_hal.c
Expand Up @@ -264,10 +264,9 @@ bool checkUsartTxOutput(uartPort_t *s)
void uartTxMonitor(uartPort_t *s)
{
uartDevice_t *uart = container_of(s, uartDevice_t, port);
IO_t txIO = IOGetByTag(uart->tx.pin);

if (uart->txPinState == TX_PIN_ACTIVE) {
IO_t txIO = IOGetByTag(uart->tx.pin);

// Switch TX to an input with pullup so it's state can be monitored
uart->txPinState = TX_PIN_MONITOR;
IOConfigGPIO(txIO, IOCFG_IPU);
Expand Down

0 comments on commit 88c9115

Please sign in to comment.