I wonder if there may be any problems using the pins that the UART are using as GPIOs, if now I want to be able to reprogram the circuit? (Of course I will detach the ESP12-E from the mainboard before so)

  • 1
    flash mode is achieved using a combination of GPIO 0, 2 and 15 ... so, since UART is on 1 and 3, it will be flashable if powered up with 0-LOW, 2-HIGH and 15-LOW - since your sketch won't be running in this mode – Jaromanda X May 6 '19 at 10:09
  • keep in mind that this pins are the only way to change the application in esp8266 in any case. (OTA is the other way, but it must be supported by the running application) – Juraj May 6 '19 at 11:14

Sure, you can use the UART pins as general purpose IO pins - however, it's far from ideal - for one simple reason:

  • The ROM issues messages on the UART at boot time.

This means that when you power the chip up whatever is connected to the UART TX pin will receive pulses of HIGH and LOW.

That may or may not be a problem, depending on what is connected. It's something you need to bear in mind though.

  • Is the UART TX pin the only pin of this concern then? – Anton Ingemarson May 6 '19 at 11:03
  • Yeah. The RX pin is an input, and during normal boot isn't actually used for anything. – Majenko May 6 '19 at 11:04
  • However, the RX (gpio3) pin is apparently pulled HIGH on boot, just like pins 12, 13 and 14 - also, driving gpio 1 (TX) low on boot will prevent boot - one common use for RX is i2s - it's the SD pin for i2s output – Jaromanda X May 7 '19 at 1:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.