Author Topic: 220V -> 5V/12V buck converter (or other)  (Read 984 times)

0 Members and 1 Guest are viewing this topic.

Offline okwTopic starter

  • Frequent Contributor
  • **
  • Posts: 280
  • Country: no
220V -> 5V/12V buck converter (or other)
« on: December 18, 2021, 03:45:01 pm »
Hi guys. I have had great success powering my projects with the dirt cheap 220V to 5V or 12V buck converters from Ali/ebay/others:
https://www.amazon.com/Precision-Converter-Transformer-supply-Arduino/dp/B07FCF8YVV
I see another one that comes in 2A, but I haven't tried it:
https://www.aliexpress.com/item/33012749903.html

I usually stick with the 5V, but it's of course dependent if I run relays, radios or other (>5V) stuff.
I need 220V onboard as I'm switching heating elements, fans, compressors, etc. So a wall wart or similar isn't an option.

I've had great success with the first one, however, my final result doesn't look as sleek as it could, since I now jam a prebuilt step down module on top of my beautiful pcb.
My question is, have anyone reversed engineered the first one I linked in? Either the 5V or 12V - I think the basic design is the same, perhaps just a resistor change on the regulator(?). Or a similar with clean, strong output? The first one I linked comes in 5V 700mA, 9V 700mA or 12V 400mA, which is fine in most cases. But having >1A would also be nice.
Budget and simplicity is key, but not at the expense of supply quality.
I would of course, also like to improve it. Add isolation gaps, milling/cut-outs, comply with standards, etc.

I know there are tons of schematics out there to do the 220V->5V but as I've learned, just having 5V on the output isn't worth that much. Power supply design is often taken a little lightly.
« Last Edit: December 18, 2021, 04:52:10 pm by okw »
 

Offline Siwastaja

  • Super Contributor
  • ***
  • Posts: 8790
  • Country: fi
Re: 220V -> 5V/12V buck converter (or other)
« Reply #1 on: December 18, 2021, 04:13:26 pm »
They are not buck converters, these are transformer isolated mains supplies, possibly of flyback topology.

But do not use those cheap Chinese Alibaba supplies! They are notoriously lethally dangerous. Some are OK if you can verify their safety, but this is a real risk for a beginner. Fixing obvious issues like Y2 capacitor ratings or PCB cutouts might not be enough if the transformer itself isn't safely wound, using the right types and amounts of insulating tapes in the right places.

There is ample supply of second-hand isolated supplies in form of phone chargers etc. Supplies that originally came with routers, laptops, whatever, made by proper manufacturers and usually with certifications for electrical safety (more than just CE marking). Failing that, buy proper stuff from your preferred electronics distributor. Meanwell for example manufactures proper power supplies for acceptable prices.
 

Offline okwTopic starter

  • Frequent Contributor
  • **
  • Posts: 280
  • Country: no
Re: 220V -> 5V/12V step down
« Reply #2 on: December 18, 2021, 04:20:30 pm »
But do not use those cheap Chinese Alibaba supplies! They are notoriously lethally dangerous. Some are OK if you can verify their safety, but this is a real risk for a beginner. Fixing obvious issues like Y2 capacitor ratings or PCB cutouts might not be enough if the transformer itself isn't safely wound, using the right types and amounts of insulating tapes in the right places.

I'm not taking about "fixing" the existing module, but integrating a good ps design into my own low-voltage designs (instead of soldering in a pre-existing module). Then I'd buy properly rated transformers from reputable vendors, X/Y caps, etc.
 

Offline Ice-Tea

  • Super Contributor
  • ***
  • Posts: 3180
  • Country: be
    • Freelance Hardware Engineer
Re: 220V -> 5V/12V buck converter (or other)
« Reply #3 on: December 18, 2021, 04:42:07 pm »
They are not buck converters, these are transformer isolated mains supplies, possibly of flyback topology.

Hopefully.

I'm not taking about "fixing" the existing module, but integrating a good ps design into my own low-voltage designs (instead of soldering in a pre-existing module). Then I'd buy properly rated transformers from reputable vendors, X/Y caps, etc.

That's almost never worth it. Get a quality wallwart (or just take a leftover from a good phone charger). If you absolutely must DIY: in descending order off ease-of-use and ascending order of effort, insanity and lack of safety:

Complete supplies you can integrate:

https://bit.ly/3qbcUgy

Almost complete supplies (may require filtering, fuse,...)

https://bit.ly/3J4c9P2

From the ground up:

https://bit.ly/33whheA

Note that usually such designs don't use "off the shelf" trafos, they are custom wound. And the limited supply of off the shelf parts will probably cost you more than a complete, good quality phone charger.
 

Offline okwTopic starter

  • Frequent Contributor
  • **
  • Posts: 280
  • Country: no
Re: 220V -> 5V/12V buck converter (or other)
« Reply #4 on: December 18, 2021, 04:51:07 pm »
I forgot to mention, wall warts or external ps isn't an option, as I need 220V on-board (switching heating elements, fans, compressors, etc).
In my low voltage designs, i always use a wall wart :)
 

Offline strawberry

  • Super Contributor
  • ***
  • !
  • Posts: 1199
  • Country: lv
Re: 220V -> 5V/12V buck converter (or other)
« Reply #5 on: December 18, 2021, 05:21:46 pm »
Operating temperature -20~60 degree * 0.7W@80% for regular SO-8 ??
output range: 4.8~5.2v, * ''spectacular precision'' 4%
Output efficiency: 80% * could actually be 60..70%
Switch machine overshoot: MAX 10% * 5.5Vp that's not great
Output over voltage: 4.8-5.2V ??
 

Offline Siwastaja

  • Super Contributor
  • ***
  • Posts: 8790
  • Country: fi
Re: 220V -> 5V/12V buck converter (or other)
« Reply #6 on: December 18, 2021, 06:57:51 pm »
Designing and manufacturing safe, small, efficient mains power supply that passes EMI and other regulations everywhere is surprisingly difficult, to the point that even large players outsource it (either using an off-the-shelf PSU module, or have one custom-designed (more likely, modified from existing design) for them. Most gadgets use simple external PSU and many large players do not even bother to ask for custom labeling, so chances are high it's just Meanwell.

For example, I have never designed a "normal" DC/DC mains PSU when one exists off the shelf.

If you do that, then 99% of your work will be regarding that power supply, and 1% of that IoT gadget design (or whatever you are doing).

If you still want to do it, look at fully integrated flyback ICs that come with switching transistors, like the ST's VIPER series. Companies like Wurth Elektronik have off-the-shelf flyback transformers. Following the appnotes, you'll be able to build a decent mains supply without investing years of your time into it, and as a hobbyist you can skip all EMC and just hope it doesn't interfere your own gadget. But it still likely doesn't make much sense (your time's better spent otherwise), unless you actually want to learn about designing such supplies.

But all in all, if you still don't recognize what buck converter is, and that you don't want that one, you have a long way to go. Start by learning the most common topologies.
« Last Edit: December 18, 2021, 07:00:40 pm by Siwastaja »
 

Offline floobydust

  • Super Contributor
  • ***
  • Posts: 7473
  • Country: ca
Re: 220V -> 5V/12V buck converter (or other)
« Reply #7 on: December 18, 2021, 07:50:25 pm »
OP, you're just buying cheapest wall-wart boards, how do you even mount them, no screw holes.
These power supplies will be missing any of: Fuse, NTC, input CM choke, output filter, no TL431 or opto. If they are really noisy, it will affect your ESP8266/ESP32 RF signals.
Your Amazon 700mA one doesn't even use a proper safety rated Y-cap, or opto-coupler for regulation, or fuse, or decent HV spacings between primary and secondary side.

I bought a few different Aliexpress 110V/220V to 5V 2A power supplies, the better ones where you can see a fuse, CM choke, external mosfet. One had a bad IC, the other AiSHI electrolytic capacitors gets super hot, the last one goes unstable with some loads. Solder blobs all over the boards and the transformers looks like a drunk wound them.

I wanted something decent like Meanwell even if 10X the price, but because these are low wattage and small they are always missing parts. You have to add a fuse and CM choke usually and what was the point if you're laying out a board.

These potted modules are popular with the hobby crowd, Hi-Link HLK-PM01 5V/600mA (3W) but need to add a 1A fuse, CM choke 10-30mH and output capacitor 220uF...
https://lygte-info.dk/review/Power%20Mains%20to%205V%200.6A%20Hi-Link%20HLK-PM01%20UK.html
 

Offline Steffalompen

  • Contributor
  • Posts: 31
  • Country: no
Re: 220V -> 5V/12V buck converter (or other)
« Reply #8 on: December 20, 2021, 12:26:44 am »
I'm surprised to see that your 'dirt cheap' and frankly horrible PS from Amazon isn't much cheaper than a proper and equivalent PCB module on Digikey. And a transformer for one of these is about the same cost when buying just a handful. All in the 80-100kr (8-10$) region.

If you really want to do it yourself, watch Danyk's videos on Youtube (DiodeGoneWild). SMPS and their reverse engineering seems to be his specialty.

Why exactly do you need so much power? Can you substitute relays with solid state devices?
Will anyone be handling or come in contact with anything in this 5V potential, which may or may not be properly isolated?
« Last Edit: December 20, 2021, 01:09:24 am by Steffalompen »
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf