change uart pins without restart

This commit is contained in:
MichaelDvP
2025-11-28 09:08:53 +01:00
parent 056cf3cbd6
commit 5ed4970d62
2 changed files with 3 additions and 2 deletions

View File

@@ -106,6 +106,7 @@ void EMSuart::start(const uint8_t tx_mode, const uint8_t rx_gpio, const uint8_t
xTaskCreatePinnedToCore(uart_event_task, "uart_event_task", EMSESP_UART_STACKSIZE, NULL, EMSESP_UART_PRIORITY, &xHandle, EMSESP_UART_RUNNING_CORE);
#endif
} else {
uart_set_pin(EMSUART_NUM, tx_gpio, rx_gpio, UART_PIN_NO_CHANGE, UART_PIN_NO_CHANGE);
vTaskResume(xHandle);
}
tx_mode_ = tx_mode;