Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FR] Add Drive Strength parameter to GPIO boot state config #5139

Open
TD-er opened this issue Oct 9, 2024 · 0 comments
Open

[FR] Add Drive Strength parameter to GPIO boot state config #5139

TD-er opened this issue Oct 9, 2024 · 0 comments
Labels
Platform: ESP32 ESP32 classic and ESP32-xx based devices Type: Enhancement Improve something already present

Comments

@TD-er
Copy link
Member

TD-er commented Oct 9, 2024

Olimex has reported some issue with the clock pin of their GateWay board: espressif/arduino-esp32#9623

This mentions the drive strength of a GPIO pin.

After some searching, I found these 2 posts describing the actual max. current for sourcing and sinking a GPIO pin per drive strength.
https://esp32.com/viewtopic.php?p=25550#p25550

image

The measurements were made with the following resistances: infinite, 2kΩ, 1kΩ, 470Ω, 220Ω, 150Ω, 100Ω, 47Ω and 0Ω. But for strengths 2 and 3 the minimum resistance was 100Ω.

By measuring into a capacitor, I can confirm that the source and sink current limits for drive strength 2 are about 40mA and for drive strength 3 they are about 80mA. Actually source current limits are a little higher than the sink current limits.

The drive capabilities of the digital-to-analogue converters are very different.

The post below also has a lot of hard to find information on which pin is connected to which power domain:

There are three "power domains" on the chip, i.e. three separate power input sections.
Domain VDD3P3_CPU in on pin 37 (NOT GPIO 37) supplies power to GPIO5; GPIO18; GPIO23; GPIO19; GPIO22; GPIO3; GPIO1; and GPIO21.
This domain can SOURCE up to 40mA and SINK up to 28mA on STRENGTH 3

Domain VDD3P3_RTC in on pin 19 (NOT GPIO 19) supplies power to GPIO36; GPIO37; GPIO38; GPIO39 ; GPIO34; GPIO35; GPIO32; GPIO33; GPIO25; GPIO26; GPIO27;GPIO14; GPIO12; GPIO13; GPIO15; GPIO2; GPIO0; and GPIO4.
Remember GPIO34..GPIO39 are inputs only, so cannot be used to source or sink current meaningfully.
This domain can SOURCE 40mA and SINK up to 28mA on STRENGTH 3

Domain VDD_SDIO in on pin 26 (NOT GPIO 26) is a special bidirectional power pin which can be driven by 3.3V externally, route VDD3P3_RTC via an internal network, or supply 1.8V via a LDO regulator. The LDO regulator can only supply 40mA. If using power through VDD3P3_RTC, the internal network will cause a voltage drop; the higher the current drawn, the more voltage will be lost in the chip and more heat generated.
Domain VDD_SDIO supplies power to GPIO16; GPIO17; GPIO9; GPIO10; GPIO11; GPIO6; GPIO7; and GPIO8
This domain can SOURCE up to 20mA and SINK up to 28mA on STRENGTH 3 (Remember the 40mA total limit at 1.8V)

The sum of all the I/O current may not exceed 1200mA

And as a bonus hard-to-find figure, the internal pull-up and pull-down resistors are 45kOhms each.

@TD-er TD-er added Type: Enhancement Improve something already present Platform: ESP32 ESP32 classic and ESP32-xx based devices labels Oct 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Platform: ESP32 ESP32 classic and ESP32-xx based devices Type: Enhancement Improve something already present
Projects
None yet
Development

No branches or pull requests

1 participant