Electronics > Beginners

Handling battery to wall power brick switching

(1/2) > >>

dins:
Hello all, I have been working on a Bluetooth speaker and while I have smoothed out most of the electricals I have one issue I can’t get my head around.

So I am using 3x 18650 cells to make a 12v internal battery to power this, but I also want to have it charge and run via your typical dc barrel jack with a wall power brick. I believe I have the basics covered, low and high voltage cut off, short protection and weak but at least present balancing with a cheap bms, and I will charge with a SY6912 dedicated cc-cv board that steps down the voltage itself and has safety timers and I am guessing cut off once the battery is at the right voltage.

Now my problem appears when I look at the following, I need to keep the battery and its charging circuit separate from the power of the wall power brick once its plugged in else the power brick will be forever leaking current in to the battery charging it directly which is not desired.   the dc barrel jack has the ground switching ability in it but that is useless since all the grounds are connected any way, the charger has a common ground by the looks of it so I need to switch the positive side once the power brick is plugged in.

I want to avoid having a power brick that has tip ground and jacket positive which would give me switching on the positive side using the jacks inbuilt switch. BUT since that is the complete opposite of what every power brick I have seen uses and I don’t want some one plugging in some other brick and giving it reverse polarity.

I want to switch the two supplies with the least power loss, but with the smallest size device, so fets are the best option over physical relays right?, they don’t waste much power at all so long as the gate is fully engaged right?

The other thing I need is for the battery to be connected by default when the power brick is unplugged, and it should use minimal power if none to keep that battery connected. So once again fets are the best?

Secondly I know roughly how n and p, or mosfets work, one needs high voltage at the gate to let power flow from source to drain while the other I think is open by default at low voltage, but I cant get my head around how to arrange them with the two different power supplies I have, and I think you can get some back flowing current through a mosfet so would need a diode to stop unwanted power flowing back in to the battery from the power brick ? I know diodes will drop the voltage and waste some power so it would be neat if there is a way to avoid that from happening with out wasting power from the battery, I don’t mind wasting power from the power brick side however.

Can some one tell me if I am on the right track with all the above and maybe suggest how to switch these or offer a better alternative?

Attached is a picture of how I intend to set this up and you can get an idea of what will happen if the two positive lines are just directly connected.


And the load this all powers isn’t much, it might take 2 amps at most and it can handle 12-20 volts, I have ordered a few AO4606 N+P mosfets thinking I can use either channel type and they can handle 6 amps and up to 20v by the looks of it.

soldar:
Power supplies with barrel jacks these days are almost universally connected with negative to the outside of the barrel and positive to the inside.

I thought the purpose of the battery circuitry was precisely to stop the charging when the batteries were filly charged.

mariush:
The easiest would probably be to use a simple mechanical relay.
For example, restrict the DC In voltage to 15..18v and get a matching relay ...  maybe use a buck regulator down to 12v if the speaker amp can't handle 15..18v
use a small signal relay to switch between battery and dc in / step-down regulator



alternatively, why not just a couple very low drop diodes ... and maybe a LDO after the diodes, bringing 12.6v - 15...18v (whatever) down to 12v or whatever's safe for the bluetooth.

Calambres:

--- Quote from: soldar on April 28, 2019, 02:57:47 pm ---Power supplies with barrel jacks these days are almost universally connected with negative to the outside of the barrel and positive to the inside.
--- End quote ---

One notable exception is the musical effect boxes, A.K.A. "effect pedals"... and many other appliances using their same power scheme. They are almost universally powered with both external power sources, via a barrel jack, and an internal 9V battery. The reason why they use positive barrels is to avoid the 9V battery clip to short with the already grounded and negative chassis. This is a side effect of the way the switched barrel female plugs are built: They always switch the barrel side, not the internal stud. This should render the positive terminal of the 9V battery clip always connected to + and subject of shorting easily with the surrounding chassis when a battery is not attached. With the center stud connected to the negative terminal there's no such risk.

Peabody:
I think what you need is called "load sharing".  When the mains power is used, it powers both the battery charging and the ultimate device independently.  But if there's no mains power, the battery supplies the current, with no voltage drop.  The circuit normally consists of a p-channel mosfet, a schottky diode, and a resistor.  The versions I've seen are for single LIPO cells and USB power, so yours may be more complicated.  Here are useful links that explain it:

http://blog.zakkemble.net/a-lithium-battery-charger-with-load-sharing/

http://ww1.microchip.com/downloads/en/AppNotes/01149c.pdf

Navigation

[0] Message Index

[#] Next page

There was an error while thanking
Thanking...
Go to full version
Powered by SMFPacks Advanced Attachments Uploader Mod