I want to permanently attach an ESP32 module and an LTE modem/hotspot to my car. I want to power these two devices using the car's cigarette lighter socket. The socket gives 12 VDC so I will be using a buck converter to step this down to 5 VDC which can be used by the micro-controller and modem (it is USB powered).

I did some research and have heard that automotive electrical power is not clean. It dips when the starter motor attempts to start the engine and also it can have other random voltage spikes and noise. I don't want these to prematurely kill the ESP32 module or the modem. Will buck converter modules filter these out automatically? Otherwise what should I do to clean the power? Are there any pre-built solutions which I can use?

The buck converter module I plan to use will be one of those which are cheaply available like these:

enter image description here

enter image description here

I am just a tinkerer and hobbyist trying to make a small project to make my life easier - I am not an electrical engineer.

  • \$\begingroup\$ You may need to distinguish "ordinary circumstances" from "unusual failures". In an unusual failure, automotive electronics are required to tolerate over 100 volts for most of a second. In practice my understanding is that never happens in modern cars, but I wouldn't hook up anything to a car that was too expensive to ever replace. \$\endgroup\$ Sep 3 at 18:38

2 Answers 2


Yes, in general, a good automotive grade buck converter should keep the output stable and protected from the disturbances on the input side.

The problem is, you don't know if the modules you show are good or automotive grade. Or actually, you can simply assume that they are not.

At least the LM2956 chip is not an automotive grade chip, so it would need protection and filtering components on the input. And on output too.

It basically means, the module might not handle the stress of automotive environment and can damage and when it damages it can break in a way that blows the ESP32 with 12V as well.

These are cheap chinese designs quickly hacked together for selling to random hobbyists that barely know what they are buying or how to use the modules, they surely have not designed it to withstand the stress of automotive environment, not electrically, thermally or safety-wise.

If you want to just have a 12V to 5V adapter for car use, buy a cigarette plug adapter for a cell phone, and buy a good brand that's expensive enough. Cheap ones are likely unsafe garbage. An adapter you are confident enough to plug into your phone should also be good enough for your modem and ESP32.

  • \$\begingroup\$ Your last sentence, "good enough for your phone", says it all. $$phone versus a microcontroller and modem chips. +1 \$\endgroup\$
    – Marla
    Sep 3 at 13:06
  • \$\begingroup\$ All "LM2596" modules on the internet should be assumed counterfeit until proven otherwise. k6jca.blogspot.com/2018/02/… \$\endgroup\$
    – bobflux
    Sep 4 at 23:09

Automotive power is filthy. It's full of big spikes that will eventually damage the little adjustable buck module at the top of your illustration.

Do those buck modules clean up power? Somewhat, but they aren't lab supplies. It depends on your operational definition of "clean". Buck converters create ripple due to how they work, but it's small and fast.

When I built a controller for an electric start diesel water pump I faced this and other problems. I used very large bypass capacitors to calm the larger spikes before putting 14.5V through buck converters for the various voltages required by servomotors and other things.

Buck converter output is good enough to run an Arduino and probably fine for an ESP32 but it was too dirty for an LM386 sound detector module like this one

LM386 sound detector module

Ripple coming in the power rail was amplified and detected as sound.

I cleaned it up by slightly increasing the voltage and then using a linear regulator to clamp the spikes. Things I've read suggest this won't work but it did which I find more compelling than theory. I imagine a 10nF bypass capacitor would also clean up these small fast transients but by the time I thought about that it was working and you don't fix what ain't broke.

Using a linear regulator to scrape off the ripple will also protect the ESP32 in the event that a buck converter failure passes 12V through. While the buck converter is working it will dissipate very little power clamping 6V to 5V, but if it gets 12V then it will get hot so if you design this kind of protection then you also need a heatsink and a piezo alarm to clue you in that the buck converter has failed.

How hot depends on the ESP32's power. The current will be whatever current the ESP32 requires. Suppose it needs 300mA, then 300mA must pass through the regulator with a drop of 9V5. When the motor runs, the alternator voltage is high enough to charge a car battery ie 13.8V to 14.5V.

So the regulator must dump 300mA @ 9.5V or 2.85W. Which isn't colossal, but it will get warm.

Power dissipation brings me to a question you didn't ask. Tracking devices that run continuously will run your battery down faster than you might think. Comms devices use more power than you'd expect to transmit, and you did say "hotspot". I strongly suggest your design should

  • have the ESP use a MOSFET to switch power to subordinate modules like LTE
  • have its own battery circuit charged by car power only when the engine runs
  • monitor voltage and shuts down to avoid battery damage

You could also sleep the ESP32 and use a low power timer to wake it periodically.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

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