Introduction: Universal Portable USB Charger

Picture of Universal Portable USB Charger

Hello! In this Instructable I will show you how I built myself a universal portable USB charger. I am soon attending a weekend festival with camping and I realized that my crappy chinese "10000mAh" USB power pack won't last that long. I have my phone (Galaxy S4), a GoPro and my friends will also want to stay charged. As I fly RC multirotors, I have a handful of various LiPol batteries - so why not use them as a power source?

This charger can be powered by pretty much any source from about 7V up to 30V and can deliver 3A USB charge current. I am powering it from 3S (11.1V) LiPo's, but it should also run from 2S (7.4V) LiPo's, car batteries (both 12V and 24V) and even solar panels.

The parts are readily available and I believe you can build this under $10.

Let's get started!

Step 1: Parts List

Picture of Parts List

Here are (almost all) parts that I used in this project.

Not on the photo, I also used a 2-pin screw terminal and 2-pin male and female PCB headers.
I used a XT-60 connector for the main power connection, which is commonly used with RC LiPol batteries. However you can use anything else instead to fit your needs.

You will need a soldering iron, solder, files or sandpaper, hot glue gun and a dremel tool, along with basic tools (screwdrivers etc.).
You will also need a digital multimeter.
A USB voltage-current meter is very helpful for testing your charger.

Step 2: Initial Planning

Picture of Initial Planning

I started by cutting the PCB roughly in half and making a cutout in it, so that it will fit nicely around the central standoff. Then I freely placed most of the components inside to get an idea on the overall layout.

As the 3 USB sockets are the main feature of the entire device, I placed them first onto the PCB. They slightly extend the edge of the PCB.

The last picture is the connection diagram.

Step 3: Soldering the USB Connectors

Picture of Soldering the USB Connectors

This is a fairly easy step. Just drill slightly bigger holes for the USB connectors' tabs, push them in and solder them in place. Then solder together the GND (pin 4) and the connector case for each connector.

Here I added a 2-pin screw terminal for the power connection. You don't have to do this, but it makes the final assembly a bit easier.

Step 4: Wiring the Board

Picture of Wiring the Board

This step is not too hard, but you have to pay constant attention to the wiring. Be careful so that you don't swap or short together the 5V and GND rails.

Start by soldering the two resistors. These will tell your device that it is connected to a charger and can pull higher current. Note that the values may be different for various phone/tablet brands, so just google "<your device> DIY charger" and see what works best. I first tried just connecting the USB data pins together without any resistors. That worked, then I tried the 33K and 10K resistors and it worked as well, so I just used them. Also, this produces a 1.2V voltage on the data pins, which is the same as my original Samsung fast charger does. With this configuration my phone only draws 0.6-0.7A (although it can charge at up to 1.7A), but that's enough to keep it charging. (This might be because my battery is old now? I am not sure.)

Next step is to solder the power rails. Connect the screw terminal pins to the first USB connector. Then use some wire to connect all the +5V pins together and all the GND pins together, paying constant attention to polarity and any possible shorts. The wire I used here is 26AWG, which is not ideal - you should use at least 22AWG.

Then solder the data pins of each connector together and connect them to the resistors center point.

After checking (again!) all the voltages, polarities and possible shorts, you can now power it up from a bench supply set at 5V. Measure the voltage at USB data pins, it sould read about 1.2V. If it doesn't, check your wiring again... otherwise you can try charging a phone.

Step 5: DC-DC Module

Picture of DC-DC Module

We need to prepare the DC-DC step-down converter. Just solder some wire to the output terminals. Use thicker wire (at least 20AWG), I used wire from a computer PSU.

Then hook up the input terminals to a power supply (I used 12V) and connect your multimeter to the output. Adjust the pot with a screwdriver until you get a voltage between 5.0V and 5.1V.

Step 6: Front Panel: the USB Connectors

Picture of Front Panel: the USB Connectors

Here comes the most tedious part: doing the front panel cutouts. I first drilled a hole into the PCB for a screw, which attaches the board to a small screw standoff inside the project box. Then I slid the front panel to it's place and traced out the connectors onto it with a marker. Using 1mm drill bit I traced out the first connector, then checked if everything still aligns and repeated this for the second and third connector.

To make the actual cutouts I pre-drilled a lot of holes next to each other just on the inside of the traced lines. Then I used the same drill bit at higher rpm to route the pre-drilled holes out. Again, after checking the alignment I repeated this for the rest of the connectors.

Finally I used a square file to smooth out the edges. Notice that the holes turned out to be a bit bigger than intended, because I was drilling too close to the traced lines. Being slow and precise here pays off with nice result. A laser cutter or CNC router would be a life- (and also time-) saver.

Step 7: Front Panel: the Voltage Display and Power Switch

Picture of Front Panel: the Voltage Display and Power Switch

Next two features are the voltage display and the power switch. Once again, I decided on the layout, traced them out and used the same technique as for the USB connectors.

I added a connector to the LED voltage display, it is a 2-pin male PCB header. The voltage display has 3 leads: power (red), ground (black) and input (white), I just joined the power and input together. The other side of the connector is a female PCB header with wires going to the power input. As with the screw terminal, this is optional but makes the final assembly easier.

Before gluing the display, I slightly beveled the edges of all holes with a small file.

Then I laid down the front panel, put the display in place and secured it with hot glue.

Step 8: Wiring It Up

Picture of Wiring It Up

I soldered the female connector of the voltage display to the input of the converter module.

Then I made a input power lead from a length of wire (again from computer PSU) and a XT60 connector. I twisted the wires together. I drilled a 4mm hole into the side of the project box and fed the wires through, making a knot on the inside to prevent pulling it out.

I inserted the PCB along with the front panel. The problem was that the board wasn't pushed strongly against the front panel and inserting a USB device would push it back a bit. So I had to improvise and used a piece of stiff wire, which is bent around the center standoff, fed through the PCB and pushes it against the front panel. Works surprisingly well.

The rest was simply wiring up the power switch and input of the DC-DC module, connecting the screw terminal and screwing the box together.

Step 9: Finished!

Picture of Finished!

Well there you have it! Now you can use almost any power source to charge your device!

Some improvements I can think of would be using a regular DC power jack as the input, so that you can also plug in regular power adapters.

Also, instead of using a step-down-only converter, you could use a buck-boost converter, which can operate on lower voltage than its output voltage.

Oh and if you are too lazy to spend an afternoon making this, just grab a 12V car USB charger and wire up your battery. Problem solved :D

Thanks for reading my Instructable.

Update after initial testing:

The charger performed very well. The 5000mAh battery was enough to keep 5 phones charged throughout the weekend.


penguinoo569 (author)2017-09-01

How many prongs are on the toggle switch and what is the max voltage of the toggle switch

3zuli (author)penguinoo5692017-09-03

You can use pretty much any toggle switch. I think my switch is rated for 230V 3A and has 2 prongs, I salvaged it from some old PC power supply. Just search "toggle switch" on ebay and you'll get a lot of options.

penguinoo569 (author)2017-09-01

How many prongs on the switch and want max voltage switch should I get

gregdavid (author)2015-12-22

One tool you might find extremely useful for the front panel holes is a nibbling tool (normally used for sheet metal).

As great as dremel tools are, even with the best bits, they still don't cut very clean & square holes, esp. freehand. Once you get the hang of using a nibbling tool, you'll be able to cut sharp square holes as if they were precision die punched in a factory. Very cool and only ~$5-$10 for the tool!

3zuli (author)gregdavid2015-12-25

Thanks for the tip, I'll definitely take a look at this! Cutting nice square holes has always been a pain :)

gregdavid (author)3zuli2015-12-25

Nibblers work best in sheet metal but I have used them in soft thin plastic. Sadly, they do tend to cause cracking and shatter in hard or brittle plastics, so like you I use my little dremel, but usually with the little saw blades instead of cutoff wheels, The saw blades are a bit scary. I always feel like I might take finger off if it were to bind & jump so best to NOT do what I do & wear gloves.

amclaussen (author)gregdavid2016-01-03

I have seen terrible injuries produced by those thin and extremely Sharp small circular saw blades that can be mounted in Dremel tools. It is indeed VERY easy to mishandle them, and at high RPM's they can sever a finger or two in a very short fraction of a second, as they cannot be easily guarded. Beware of them, they can be really dangerous. The very small size of their teeth can give a false sense of harmlessness, but at speed, they slice soft flesh in a hurry. In contrast, it is almost imposible to receive harm from the nibbler. Amclaussen.

amclaussen (author)gregdavid2016-01-03

I have the same nibbler tool, bought about 25 years ago at a Radio-Shack store (when they still carried aceptable quality tools). And it still Works OK. It is easy to hancdle and while slow, it can produce precise cuts. The best tool fot electronic chassis projects, no doubt. Amclaussen.

erny1601. (author)2014-07-31

did anybody built this thing ? Does it really work with the two resistors ? I want to do this, but I cant explain it to myself how it works with the both resistors, so the current won´t got to the data Pins, because the both resistors are directly connected over + and - so can anybody explain it to me, or was i wrong to now what i knew about electricity ?!?!

M. A.G (author)erny1601.2015-12-24

I have the same or similar questions as erny1601. Why is everything connected together? With the resistors keeping them separate. Why would I want my positive and negative connected yet separated with a resistor? Can resistors blow? It would seem to be prudent to insulate not resist. Also why have power to the data ports if you're just charging?

3zuli (author)M. A.G2015-12-25

The 33K and 10K resistors form a voltage divider which creates about 1.2V. This voltage is connected to the data lines on all three connectors. When a phone detects this voltage, it knows it's connected to a high power charger (instead of a regular USB port on a PC) and can draw more current.

These resistors only draw about 0.1mA from the 5V line. Don't worry, there's no risk of these resistors shorting out and burning.

M. A.G (author)3zuli2015-12-28

Thankyou . Very illuminating. I was completely ignorant of that

paziek (author)erny1601.2015-04-07

It's a voltage divider and will provide both data pins with 3.75V of useless voltage. Some chargers did provide on those pins some voltage in order to indicate how much current can be drawn by device, but I don't think it is used any more. I have USB cable for charging only and internally it has just 2 lines, so unless they have soldered SMD resistors on both connectors - it doesn't provide any power on those pins. I'm too lazy to check them, just in case...

Arduino Tech (author)erny1601.2014-08-26

I have the same problem !!

jwarner75 (author)2015-12-22

1 Question I have. Well maybe a few.

First 1. Could you use a Double USB Say like what's on a Computer so you have a total of 6 Ports or even 3 Stacked to make 9?

If so (I assume you can), Would the Voltage be different the more that's plugged in, or will it still be the same Consistant Voltage all the time.

I'm always Finding the problem of having way to many USB Items to charge on my PC and or Outlets and it's a Pain, 1 or 2 charging while th eothers aren't, then swap them out. i could use this to Make 6 or 9 ports, giving me the Ability to just Plug in ALL of my Devices that need charges at the same time.

Tablets, Phones, Nintendo DS, PSP, etc.

3zuli (author)jwarner752015-12-25

Also there are some mains-powered multi port USB chargers available pretty inexpensively, I think that would be a better option for your purpose. My charger was intended more for being powered by batteries, but of course you can always power it with a 12V mains supply.

3zuli (author)jwarner752015-12-25

Yes, technically you can add as many USB ports as you want. The converter I used here is rated for 3A, that's enough for 3 devices at 1A or 1 device at 2A and one at 1A, and so on.

If you want more devices, you'll need a more powerful converter, such as rated for 5A or even 12A. Remember that the higher the load is, the more will it heat up and the output voltage may also drop slightly.

The other option is to use multiple 3A converters, each with 2 or 3 USB sockets and dedicated resistors.

3366carlos (author)2015-03-22

good job.

sokra (author)2015-01-30

This comes in really handy. I am trying to figure out how to keep my my cell phone charged for 6-7 hours of outdoor time lapse photography, then I saw this instructable. Thx!!!

cdezarn (author)2014-12-25

Hay question, Can i use "IMR 18650 LiMn 2500mAh Battery " in it?. i have lot of these from my ecig mod's

  • Rated Capacity: 2500mAh
  • Nominal Voltage: 3.6V
  • Voltage at end of Discharge: 2.5V
  • Max Charging Current: 4A
  • Standard Charge: 2A
  • Max. continuous discharge current: 35A
  • Continuous discharge current: 20A
  • Pulse discharging current: 50A
3zuli (author)cdezarn2014-12-25

Yes you can! However with a step-down converter, you'll need at least two (ideally 3 and more) batteries in series in order to make it work. Another option would be to use a step-up (boost) converter, to step up the 3.6V from the single battery up to 5V.

SparkySolar (author)2014-10-19

I like your Instructable

Thank you so much for sharing


noahmal (author)2014-10-11

I think I'm gonna make 1 with 2 of those litho battery's then built you think that's a good idea

noahmal (author)noahmal2014-10-11

o also...would I need to add more resistors or would it be fine

noahmal (author)2014-10-11

this seems like a very good long does it charge a simple phone?and how much did it cost

profpat (author)2014-08-18

great instructable, i would suggest a bigger box and place the lipoly battery inside..

earton (author)2014-08-02

Just so I understand correctly, without a lipo cutout it would be bad news leaving an ipad unattended charging on this. Is adding a lipo cutout feasible? As a novice I was going to follow the excellent instructions to make something to charge mine and the wife's I things at the same time (they tend to get charged overnight). Thanks

3zuli (author)earton2014-08-03

Yes, you need to shut it down when not in use, otherwise the idle-running converter and voltage display will eventually discharge the battery. The voltage alarm shown in the last step warns you when the voltage is low, but you need to be paying attention and manually unplug it.

Battery cutout - I will do some research. If I find some easy solution, I will update this Instructable.

weedy (author)2014-07-30

I've been "fixing" my Apple wired chargers for use with my Android devices.

You have wired this correctly for probably 99.9% of android devices (no one cares about the rest :D ). Primarily because you shorted the data pins, which is supposed to be the USB charging port standard. You are also correct that Samsung tweaked this standard by adding 1.2volts to the data pins to signal that it's connected to a Samnsung charger and try to pull more amps (mostly for their early tablets). With the the S4 they added another signal voltage for their new 2 amp charger.

Now for my point. The my S3 (maybe your S4) and my Nexus7 use the smb347 management IC. It is picky when it comes to input voltage, and in the case of the Nexus7 REALLY picky. The USB standard port voltage is 5.0 ±0.25, while I believe a USB3 dedicated charging port raised this to 5.3volts.

If I was you I would raise the voltage under load closer to 5.2. Use a multimeter to measure, I love the ChargerDoctor, but they used cheap connectors it drops a lot of voltage.

Before mods:

After mods (Bridged data pins, 150k+47k resistors feeding pins with 1.2):

Charging my S3


Charging my N7, note the Nexus is programmed to be even more picky. It waits up to a minute to see if the charger is crap before switches from AC into an even higher amp mode.

3zuli (author)weedy2014-07-31

Very informative, thanks! I actually tried two 82K resistors, but it somehow didn't make a lot of difference. But it is strange, because when I measure the Samsung charger, my ohmmeter reads 82K between GND and data and also 5V and data. But when it is turned on, there's 1.2V on the data lines. So which setup do you think is better? 10K and 33K or two 82K resistors?

weedy (author)3zuli2014-07-31

Well 2 82k resistors makes the divider put out 2.6 volts.

I'm not sure it's better then 33k+10k, it's just different. In your case you need to try raising the voltage underload to over 5.1v. All my Samsung charger spit out 5.3 volts, hell I have one that idles at 5.37v.

Note: I use 150k and 47k so that they drain less power. vs.

3zuli (author)weedy2014-08-03

Watch out, you forgot to add three zeroes to R1 and R2 values! You entered only 33ohm and 10ohm, three orders of magnitude less than the actual values. Actual 33Kohm and 10Kohm resistors only draw 0.1mA or so... ;)

dougstrickland (author)weedy2014-07-30

The .2 volts you are seeing dropped is the load consumed by the display in each of the ChargerDoctors. It isn't cheap connectors, just some simple Ohms Law!

weedy (author)dougstrickland2014-07-30

If you pull the connectors off and solder straight to the pads it drops less.

I realize there is going to be parasitic losses for the display and IC, but the connector loses are not negligible.

KeithM1 (author)2014-07-30

It is very dangerous to over discharge a LiPo battery. They are designed to be run from 4.2v down to 3.0v per cell. They can start fires and explode of improperly handled. Since this device doesn't have a LiPo cutoff circuit it will most likely over discharge resulting in fire!

3zuli (author)KeithM12014-07-31

This is the reason why I placed a voltmeter on the front panel... Also in the last step, there's a photo of a LiPo voltage alarm with a caption "ALWAYS use a voltage alarm".

Yes, there is no automatic cutoff, but all it takes is to check the voltage every half an hour or so and disconnect if it is starting to get too low

KeithM1 (author)3zuli2014-07-31

Well I certainly hope that's enough. If you charge like I do - over night - that would be dangerous.

stevethedeep (author)2014-07-31

After being away in Aberystwyth camping and having our phones continually run down this is just what I need. I'm an electronics engineer and your well researched circuit diagrams and explanations make perfect sense and will save me a few problems I had not even thought about. This is one of the best articles I've seen. Well done ! - and thank you.

bhermance (author)2014-07-30

very good! I may do this myself!

erny1601. (author)2014-07-30

I think in your wiring diagram is a short circiut (the connected resistors)

3zuli (author)erny1601.2014-07-30

Where exactly do you think the short is?

erny1601. (author)3zuli2014-07-30

Don't understand me wrong, but the electricity search for the shortest way. So they will "circuit" at this point and won't go to the data pins, so I think the both must be separated?! Because the device who is plugged in closes the electric circle. Is there an other way, to understand it better (at your wiring diagram).

erny1601. (author)3zuli2014-07-30

I merked it. So I also dont understand why the resistors are directly connectet with + and - and you connect the both middle pins with one cable.

3zuli (author)erny1601.2014-07-30

The resistors form a voltage divider. They divide the input voltage (5V) at the ratio of R2/(R1+R2), in this case 10/(33+10) which will produce about 1.2V at the center point. This voltage is then connected to both USB data pins. The phone can measure this voltage and it then knows that it is connected to a high power charger and pull large current. "Slow" chargers which supply less current (1A max) have different resistors, the phone can sense it and will limit its current draw.

And don't worry, these two resistors draw only 0.1mA (Ohm's law: I = U/R = 5V/43000ohm = 0.0001A), they are not a short circuit.

Valvulin (author)2014-07-30

yo creo que por seguridad y control, el voltimetro deberia estar a la salida del conversor para asegurarme que tengo 5Vcc en los USB

LuisC1 (author)2014-07-30

Very Nice..!!!Thanks for the cool USB Charger...

earton (author)2014-07-30

Would I be able to put 4 or 5 USB connectors in this? Would power it from a DC power jack. Thanks

3zuli (author)earton2014-07-30

Yes, as long as the DC-DC converter can supply the current. You can either buy a higher powered converter (5A models are available), or you can use multiple of these 3A converters, each powering 2 or 3 USB connectors separately.

fjr_scoot (author)2014-07-29

Nicely done; Thanks! (author)2014-07-28

where did you get this box/?

About This Instructable




More by 3zuli:Mini Arduino Lux MeterESP8266 Internet AlarmUniversal Portable USB Charger
Add instructable to: