Powering Wemos D1 mini & 12v fan from the same PSU


This is my first post, but this forum has helped me a lot on my arduino journey.
Yesterday i burned my first Wemos & fan and i'm looking for advice on how to avoid this next time as i'm not sure what went wrong. I'll attach the schematic of how i imagined this would work. The thing started to smoke right after plugging it in at the fan and wemos. The buck converter might have survived. The wemos looks like it has a burned out diode next to the microusb. Should i try to replace the diode in hopes of bringing it back to life?
What i'm trying to achieve is pwm fan control using readings from a DS18B20. Right now it's the hardware that's causing the issue. On the software side, esphome + home assistant seem to be good enough for what i need.

Couldn't attach the wemos pic to the first post so here it is:

The yellow connection between the fan and the Wemos makes me afraid..... A clear reason for smoke and destruction.

Please post a link to the data sheet for that fan.

The fan supports pwm and i'm controlling 2 of them from a raspberry without issues.

This is the model, the specs are on the page F8 Silent | Extra Quiet 80 mm 3-Pin Case Fan | ARCTIC

I used the link and their technical data didn't tell anything about how to control the speed on the 3 cable fans.

Wait a second.... Do You input 5 volt to the WEMOS and then tap 5 volt from the WEMOS to create the 12 volt? That could likely be the reason for failure.

Connect that, for me, unknown 5 volt power supply to the buck converter. Connect the WEMOS to that 5 volt power supply. Don't run the fan power through the WEMOS.

The unknown PSU is a simple 5v 2.5A microusb charger. It was indeed connected through the WEMOS, but the board specs say the 5v from microusb is directly connected to the 5v pin so it should make no difference. I obviously cannot try to connect the things again after the burn :slight_smile: i'm interested if there is some electronics engineering principles i'm flagrantly breaking that would cause smoke:)

Okey. You used a good 5 volt power supply. However, the tiny copper strips on the WEMOS board should not be used to distribute more than some milliamps. I don't know that much about the WEMOS but I know from my UNOs that there are several 5 volt pins. The tiny connection between them should not be used to distribute any current named "power".

That makes sense.. i assumed the 0.12A draw would be fine but i might have been wrong. That would explain the wemos burn, but i still can't figure out why the fan burned. Anyway, here are the specs for the pwm of 12v pc fans:

Thanks for the data I didn't find. They are safe.
Running 120 mA is not alarming but it's in the high range in my world. I can't se any reason for the fan to get damaged even if the WEMOS 5 volt strip was burned.

Suppose You apply 12 volt to the fan and, by a test cable, apply 0 or 5 volt to then fan control cable, the yellow one, doesn't it turn? If so, I think about + and - 12 being swapped...

Or, by an accident, 12 volt was supplied to the fan control line...

Ok, maybe some kind of freak accident.. i also considered maybe the buck converter might be defective in some way...
Thanks for the input. Just wanted to make sure the general idea is ok before trying again with an esp32 :slight_smile:

Do You use breadboard? It's very easy to aim at the wrong point, make a short contact before making the right connection?

My advice is to step back to basic and check up the devices, the buck converter, controller, fan... Or buy new stuff....

If it converts 5 V to 12 V it is not a "buck" converter. :roll_eyes:

You are much better to use a 12 V supply and an actual "buck" converter to get your 5 V from 12 V.

In the lower left corner, diode "D2" between the USB connector and the "5V" pin is the diode you burnt.

Very useful info, Paul, thanks!
Can you explain a bit why buck is better than boost in this scenario? I don't really care about efficiency at this level of power usage..

I would say you have just experienced that!

We are presuming that the fan is the major consumer of the power in this situation, and it requires the higher voltage. The boost converter requires more than 2½ times as much current on its input than it is providing on its output, so you are requiring substantial current.

If you supply 12 V power in the first place, you only require as much current as the fan requires, and with a "buck" converter, it draws less than ½ the current it has to supply to the 5 V system. Current draw is - as you have demonstrated - a big problem because the voltage drops in diodes and such tend to be a limiting factor at lower operating voltages.

Great explanation. Thanks a lot! I will attempt a repair of the burned diode just for kicks :slight_smile:

I had it in mind to suggest just that. :grin:

To add to what @Paul_B said:

The power delivered to the load is current times voltage, so if you double the voltage for the same power you need half the current. When you consider the power wasted in the resistance of the wires and other components delivering the current the calculation is current squared multiplied by the resistance, so for twice the current four times the power is wasted in the wires.

So, for the same power delivered to the load twice the voltage means one quarter wasted power in the wires.

This is why the electricity distribution system operates at many tens or hundreds of thousands of volts