This might be a silly question but I can't find any information about this or maybe I am not asking right.

I have a AM1117 5V voltage regulator that is usually powered by a 12V to 16V battery.

Now I have certain situations where I want to just put 5V power on the board (like USB). I am pretty sure that if I put 5V into the AM1117 I won't get 5V out of it :-)

However how could I solve this issue on a simple level. Trying to avoid putting more components on the board.




Since you say you want 500mA, I suggest you use a buck switching regulator such as the AOZ1022DI that behaves like a resistor if the input is lower than regulated. It has a maximum of 0.2 ohm on resistance so the voltage drop will be 0.1V maximum plus the drop across the inductor at 500mA out and 5V in.

That is not the only one, but it's key to pick one that uses a P-channel high-side switch- ones that use bootstrapped N-channel MOSFETs will not provide 100% duty cycle. This particular one is rated up to 16V input (18V absolute maximum) which might or might not be too tight for your input.

At 14V input and 500mA, an LDO will be dissipating 4.5W, which is a lot of heat to have to get rid of. A buck regulator of the above type will dissipate maybe 0.25W, maybe 20 times better.

enter image description here


The most straightforward is to replace the AM1117 with an LDO with a very low drop out voltage.

They can have 50-100mV of voltage drop when the input is below the voltage required to regulate.

One with a MOSFET pass device will be better than a bipolar as many bipolar based LDOs (e.g LM2940) take a significant amount of current when in dropout.

I can't find a suitable one at the moment - look for Ultra Low Dropout regulator.

How much current output do you need?

  • \$\begingroup\$ This will work. For completeness, you should check that the LDO will actually work at the input voltage you're planning to use -- some LDOs are not specified to work when the input is below their regulated voltage. \$\endgroup\$ – markrages Sep 3 '15 at 1:16
  • \$\begingroup\$ Can they still produce about 500mA in current? I never worked with LDO's. \$\endgroup\$ – flyandi Sep 3 '15 at 1:20
  • \$\begingroup\$ @Andy: If the package and pass element are large enough, yes. \$\endgroup\$ – Ignacio Vazquez-Abrams Sep 3 '15 at 2:15

Kevin White's answer is a good one. If you want to do exactly what you said -- e.g. bypass the regulator when you have a 5V source from USB then you can do the following:

You can use a comparator to compare the two voltage sources and use the output of the comparator to drive a pass transistor. You'll want to use a voltage divider on the higher source (you might also want to use a divider on your Vusb depending on how you go about the design) so that across the range of possible inputs you have something that's less than 5V (you'll want to take into consideration the common mode input range). For example make your divider such that at the maximum possible Vin you have 3.3V. The other input to the comparator is your Vusb (or maybe a divided version of it depending on your comparator selection etc). You can pass the output of your regulator through the transistor such that the source and your usb 5V are connected. This way if your usb source isn't connected the gate to your p-fet will be low and you'll pass your regulated 5V to the global 5V net. If the USB source is connected then your comparator drives high and your pfet is shut off. Your USB source is now the global 5V source.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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