Connect with us

Auto Input Power Switch Circuit

Discussion in 'General Electronics Discussion' started by Maximilian, Dec 30, 2014.

Scroll to continue with content
  1. Maximilian

    Maximilian

    2
    0
    Dec 30, 2014
    Hi everyone.

    I'm trying to make my circuit switch automatically between internal battery and USB. Using a circuit simulator (free/open source/online or offline) I've played with a few methods I've seen online, but none work the way I really want. This seems like it would be a pretty common task, so I'm hoping there is an industry solution and it's just my googling-skills that suck. Onwards!

    Specs:
    USB: 5v (obviously)
    Battery: >4v (I'm looking for a method that works regardless of battery voltage above a minimum threshold)
    Load: ~50 ohms, or 100mA @ 5v

    Operation:
    USB disconnected: Battery supplying load with minimal voltage/current drop across switching mechanism
    USB connected: Battery COMPLETELY cut off, USB supplying load, again minimal voltage/current drop.

    Methods:
    1. Diode on each input (LINK)
    This method is the most basic, but only works if your battery voltage is lower than USB voltage, otherwise when you connect the USB, the load draws from both supplies.

    2. USB driving a relay (LINK)
    This is also very easy, and works regardless of battery voltage. The problem is that the relay wastes juice (at least it is from USB and not battery though) and relays are just messy. I can clean it up with a capacitor and a Shotkky diode, making this solution un-sexy but usable.

    3. MOSFET/JFET (LINK)
    My only experience with FETs is in simulators, and I can't trust that they always model correctly. My program just yells at me 90% of the time I use JFETs. With an enhancement mode P-channel MOSFET I was able to have success, but it fails at higher battery voltages, drawing from both sources. Although realistically I'll probably be using 4AAs in series and the voltage from fresh to dead will be within 6v - 4v this solution still drops way too much voltage across the FET. Is it just a matter of using a different rating/type/configuration, or will this never reach the same effectiveness as the stupid relay? I feel like a depletion mode MOSFET might work, but my program doesn't model them and it's not like I have a bunch sitting in a drawer.

    So, does anyone have some insight? I don't know why I'm struggling with this, I imagine every phone/laptop/etc uses some version of this and you can bet your ass they don't use relays. I know I can make this work with the relay, but I'm more curious as to what the industry standard method of doing this is.

    Thanks!
     
  2. garublador

    garublador

    111
    43
    Oct 14, 2014
    Those types of devices have rechargeable batteries in them. This is probably a bit simplified, but the external power source goes to a battery charging circuit and the output of that circuit connects to both the battery positive terminal and the rest of the system. So when external power is applied it powers the system and charges the battery. When external power is gone the battery powers the system.

    One option might be a power switching mux like the Texas Instruments TPS2115A:

    http://www.ti.com/lit/ds/symlink/tps2115a.pdf

    It seems to be a lot closer to what you're looking for.
     
  3. Maximilian

    Maximilian

    2
    0
    Dec 30, 2014
    Thanks for the reply. I'll have to read more into the data sheet but I think that ic or similar may do the trick. Now that I know the technical name for that sort of device hopefully I can research what goes on inside it and see how it overcomes the limitions I was experiencing.

    I had considered going with a rechargeable battery but I have to do more research. I want to be able to swap batteries if no power is available so that means rechargeable AAs not a lipo pack. Since you must supply a battery with greater voltage in order to charge it, here are the possibilities I see. (Rough numbers)
    1. No regulation:Vcc USB = 5v, Vcc Bat = 4v, Charging V = 5v
    2. USB boost: Vcc USB = 5v, Vcc Bat = 5v, Charging V = 6v (via boost conv)
    3. USB regulation. Vcc USB = 4v (via regulator), Vcc Bat = 4v, Charging V = 5v

    I'll have to look at charging ICs and see how they work, but again I'm sure they have the same issue as my base circuit since when the battery is full they still have to cut it off somehow. It would certainly bring my project to the next level though if I went that route, but I was hoping to make that a v2 sorta deal. This is as much about learning for me as it is the end product.

    Thanks again!
     
  4. garublador

    garublador

    111
    43
    Oct 14, 2014
    As long as you get a charging IC that matches the chemistry of the battery you're using, they generally handle that for you.

    Tackling the project in steps isn't a bad idea, especially if the power system isn't the only unknown. I've found that the power system for mobile devices can be at least as complicated as the rest of the system.
     
Ask a Question
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.
Electronics Point Logo
Continue to site
Quote of the day

-