@@ -7,6 +7,10 @@ The [UART](https://en.wikipedia.org/wiki/Universal_asynchronous_receiver/transmi
...
@@ -7,6 +7,10 @@ The [UART](https://en.wikipedia.org/wiki/Universal_asynchronous_receiver/transmi
The default setup for the uart is controlled by build-time settings. The default rate is 115,200 bps. In addition, auto-baudrate detection is enabled for the first two minutes
The default setup for the uart is controlled by build-time settings. The default rate is 115,200 bps. In addition, auto-baudrate detection is enabled for the first two minutes
after platform boot. This will cause a switch to the correct baud rate once a few characters are received. Auto-baudrate detection is disabled when `uart.setup` is called.
after platform boot. This will cause a switch to the correct baud rate once a few characters are received. Auto-baudrate detection is disabled when `uart.setup` is called.
!!! important
Although there are two UARTs(0 and 1) available to NodeMCU, **UART 1 is not capable of receiving data and is therefore transmit only**.
## uart.alt()
## uart.alt()
Change UART pin assignment.
Change UART pin assignment.
...
@@ -28,6 +32,9 @@ Sets the callback function to handle UART events.
...
@@ -28,6 +32,9 @@ Sets the callback function to handle UART events.
Currently only the "data" event is supported.
Currently only the "data" event is supported.
!!! note
Due to limitations of the ESP8266, only UART 0 is capable of receiving data.