Some pins are in HIGH mode after reboot

All ESP32 boards running MicroPython.
Target audience: MicroPython users with an ESP32 board.
Post Reply
ParaPashka
Posts: 4
Joined: Tue Apr 20, 2021 6:18 pm

Some pins are in HIGH mode after reboot

Post by ParaPashka » Wed Apr 21, 2021 10:28 am

I have a ESP32 WROOM-32 DEVKIT V1 board. No software installed, just flashed with micropython (esp32spiram-idf4-20210202-v1.14).
I have measured the voltage on the pins and foud that some pins are ON.
They are: D14, TX0, RX0, D5, RX2, D15
When I flashed the board with another vertion of micropython (esp32-idf4-20210202-v1.14)
pin RX2 became OFF.
Why so?
Do I need to swich them off using

Code: Select all

Pin(14, Pin.OUT).off()

for example, in boot.py, if i need them in LOW state after reboot?

While writing this post, i have been measuring the voltage many times, and I noticed, that mostly i get 0-0.1v on the OFF pins, but sometimes all pins of one side from D27 to VP (d27 d26 d25 d33 d32 d35 d34 VN VP) show about 1v or 0,8v.
What's that?

User avatar
Roberthh
Posts: 2642
Joined: Sat May 09, 2015 4:13 pm
Location: Rhineland, Europe

Re: Some pins are in HIGH mode after reboot

Post by Roberthh » Wed Apr 21, 2021 11:28 am

but sometimes all pins of one side from D27 to VP (d27 d26 d25 d33 d32 d35 d34 VN VP) show about 1v or 0,8v.
What's that?
Just floating pins in input mode.

User avatar
pythoncoder
Posts: 5146
Joined: Fri Jul 18, 2014 8:01 am
Location: UK
Contact:

Re: Some pins are in HIGH mode after reboot

Post by pythoncoder » Thu Apr 22, 2021 7:11 am

Yes. In general microcontrollers boot up with pins floating: any other option would be potentially unsafe to connected peripherals. If you want a pin to start at a defined level, an external resistor is the solution.
Peter Hinch

Post Reply