Use Tx as digital IO while using Rx to receive data?

Good plan.

Yes i think so, but in that order. The initialization of the Serial object sets the pinMode of the TX pin to OUTPUT, and as far as i know, doesn't touch it after that. (unless maybe during a Serial.write() , although it should just fail if the pin is not set to OUTPUT by that time)

Yes that will be fine, just make sure you don't change the pinMode of the RX pin.
You can also initialize the UART manually, to only use RX (or only TX) and disable one or the other completely.

1 Like