Proper use of Open-Drain Output pins

Discussion in 'General Electronics Chat' started by Marquis, Sep 5, 2016.

  1. Marquis

    Thread Starter New Member

    Jan 18, 2015
    16
    0
    I'm a little confused about open-drain outputs. In my case I have a microprocessor that will be running on a battery so I'm trying to save power. I have a few components, a sensor and a large draw light that draw a fair bit of power. I want to use the pin to turn power to them on and off. How do I go about that using the open-drain pin?

    I'm more used to working with arduinos where I can just turn off the pin to disable the component and save power. How do I go about the same thing using an open-drain pin?

    Thanks
     
  2. ericgibbs

    AAC Fanatic!

    Jan 29, 2010
    2,503
    380
    hi M,
    Which type of MCU is it.??
    E
     
  3. Papabravo

    Expert

    Feb 24, 2006
    10,138
    1,786
    Using an external pullup with an open-drain output only consumes power when the output is LOW. When you turn the output off, it goes to the value of the voltage on the other side of the pullup resistor and no current flows.
     
  4. Marquis

    Thread Starter New Member

    Jan 18, 2015
    16
    0
    I am using an arduino for some of it, but to extend things I'm using the Maxim DS2408. It's a 1-wire switch that turn on and off some of the other items.
     
  5. Marquis

    Thread Starter New Member

    Jan 18, 2015
    16
    0
    I should also add that some of the things I want to control will likely draw more current than the chip can sink. So I take it I need to use it control a larger transistor.
     
  6. hp1729

    Well-Known Member

    Nov 23, 2015
    1,948
    219
    What are you having trouble with? Did you do the "Blink the LED" exercise on the Arduino? when the output goes low the output turns on. Turn on a PNP transistor to drive something of higher power.
     
  7. Marquis

    Thread Starter New Member

    Jan 18, 2015
    16
    0
    I'm sorry, obviously I have not been clear enough in my question.

    I am using an arduino to run a DS2408 which is a one-wire switch. The switch needs to activate a few items. The arduino is running on 3.3 votes and powers the DS2408. The item that the switch turns on is a 5 volt item that draws a fair bit of current. It's basically a small 5 volt bulb for heat.

    Screen Shot 2016-11-02 at 12.47.34 PM.png
    Is my circuit correct? I don't think so. The DS2408 can be input or output. I am using it as an output switch. It is an open-drain type switch. So this should work, but I am not sure if I can sink that kind of current through the switch. I suspect I need to use the switch to run a larger transitor that will actually control the bulb, but I'm not sure of the configuration for that.

    Any thoughts? Thanks.
     
  8. MrChips

    Moderator

    Oct 2, 2009
    12,432
    3,360
    Why are you using the DS2408S in the first place?
    Why not use a single NPN transistor or a logic-level N-Channel MOSFET?
     
  9. Marquis

    Thread Starter New Member

    Jan 18, 2015
    16
    0
    I'm using the DS2408S because I need to run a few different items. Basically, because I have run out of ports on my arduino. The arduino is busy doing the inputs so I'm using the DS2048 to handle turning things on and off.
     
  10. MrChips

    Moderator

    Oct 2, 2009
    12,432
    3,360
    Fair enough.

    The max sink current is 20mA. Will your bulb turn on at 20mA?
    With a series resistance of 300Ω plus an ON resistance of 100Ω, the most you will get is 5V/400Ω = 12mA.
    With a bulb in series you will get a current much less than 12mA depending on the resistance of the bulb.
     
  11. Marquis

    Thread Starter New Member

    Jan 18, 2015
    16
    0
    I am pretty sure that I will be drawing more than 20mA. And I assume that the 20mA is total for all the items being controlled by the DS2408. So that is my issue. How do I set this up so that the circuit isn't running the power through the control switch?
     
  12. AnalogKid

    Distinguished Member

    Aug 1, 2013
    4,528
    1,248
    Look up the continuous current rating for the switch part and divide that by 2.
    Calculate or look up the current through the load device if the switch were zero ohms.
    Compare the two numbers.
    If the load current is greater than the reduced switch part current, you need a different part.

    ak
     
Loading...