Esp32

How to Power ESP32

ESP32 is an electronic microcontroller IoT based board that has a wide range of applications starting from remote monitoring to security and surveillance devices. The ESP32 has the benefit of having a low power consumption, which allows us to power it in a variety of ways and operate it on a single battery cell for more than a year. Here in this lesson, we will discuss all the ways that can be used to power ESP32.

How to Power ESP32 Using Different Ways

ESP32 boards operate in a voltage range between 2.3V to 3.6V. Normally ESP32 boards are powered with USB which is 5V. This 5V is regulated by an onboard LDO (Low dropout) voltage regulator (AMS 1117). Any voltage given to ESP32 is first regulated by this LDO regulator then fed to the on-board peripherals.


This 3.3V voltage regulator can reliably supply up to 600mA of current, however the recommended current from any GPIO is 500mA. Which is more than enough for most of the sensors and modules for controlling purposes.

Keeping in mind the requirements of voltage regulator we can power ESP32 using the following different ways:

Power ESP32 Using USB

The easiest and most common way of powering ESP32 is by using the Micro USB cable. To power ESP32 using USB connect the ESP32 board with PC or any device containing the 5V regulated USB port. Powering ESP32 with USB not only helps ESP32 to stay online but also establishes serial communication with PCs.


Here are some main highlights of powering ESP32 using USB:

    • Constant 5V supply
    • Safe current limits
    • No voltage or current fluctuation
    • Can provide power for long term without heating
    • Best power source for ESP32
    • Protect On board voltage regulator

Power ESP32 Using Vin Pin

Another way of powering ESP32 is using the Vin pin or commonly known as 5V pin. The Vin pin in ESP32 and other microcontroller boards like Arduino is connected to an on-board voltage regulator. Any voltage connected across the Vin pin goes to the regulator first which reduces it down to 3.3V and after that fed to the ESP32 board peripherals.

Using an external regulated 5V supply we can power ESP32 through the Vin pin by connecting the GND of ESP32 with external GND of supply. Any voltage between 5V to 12 V can be connected to an ESP32 Vin pin however it’s recommended to not use more than 6V or 7V. As ESP32 only needs 3.3V to operate, the rest of the voltages are dissipated by the LDO voltage regulator as heat.

Note: This Vin pin can be used as both input and output.


Here are some main highlights of using Vin pin for powering ESP32:

    • Unregulated voltage can be connected
    • Provide great range of voltage for connecting with ESP32
    • ESP32 can be power up using multiple ways through this Vin pin
    • Constant supply can be given for longer period

Power ESP32 Using Regulated 3.3V

The next on the list for powering ESP32 is using the 3.3V pin. It’s by far the most complicated method for powering ESP32. As the 3.3V pin is designed for output purposes such as to connect sensors and hardware modules however it’s also possible to power ESP32 with this pin.

Before powering ESP32 with a 3.3V pin make sure to double check the fed voltage is 3.3V coming from regulated supply. Any voltage beyond this value will burn the ESP32 board resulting in release of blue magic smoke.

This is because the 3.3V pin bypasses the on board LDO voltage regulator. Make sure to connect ESP32 GND with external supply GND.


Some main highlights of using 3.3V pin is:

    • 3V supply can be easily designed
    • Reduced the loss of excess voltage
    • Maintain safe current limit
    • Constant supply for long term
    • Portable power supply such as dry cell can be used

Power ESP32 Using External Battery

Last way on the list to power ESP32 is by using the external batteries. ESP32 runs on 3.3V so it can be easily powered using the external batteries. While powering ESP32 with an external battery, always use the Vin pin as it is connected to an onboard voltage regulator which protects from any kind of damage to ESP32.


Here is a list of all batteries that can be used to power ESP32:

    • Using a power bank
    • Using NiMH battery or standard batteries (2 x 1.5 V)
    • lithium batteries
    • LiFePO4 batteries
    • lithium polymer batteries

Warnings

Here are some warnings that need to be kept in mind while powering ESP32 with external supply:

    • Always use regulated voltage supply
    • Don’t connect devices with ESP32 that draws more current such as motors
    • Don’t use more than one power source together
    • If the voltage regulator heats up turn off the ESP32 board

Conclusion

ESP32 can be powered using different sources which increase its mobility and long-term working. By enabling the deep sleep mode in ESP32 it can last up to 1 year on a single battery. Here we discussed all possible ways of powering ESP32. Among all methods, USB is the most conventional and safest way of powering ESP32.

About the author

Kashif

I am an Electrical Engineer. I love to write about electronics. I am passionate about writing and sharing new ideas related to emerging technologies in the field of electronics.