Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Open Circuit Problem with Logic Gates

  1. Jan 23, 2013 #1
    I wonder how can I make the logic gate read 0V when it is open?

    For instance, the AND logic gate. If one of its input pin has 5V supply, and the other don't have, the output signal given to me is 5V. How can I make it 0V? Well, theoretically, it should be 0V, but in reality, it appears that it is 5V.

    Same goes with OR logic gate. If one of the inputs is 0V, and the other is not connected with any supply (not grounded - the wire is hanging), it gives an output value of 5V.

    We need this for our project. We have our own long equation (it involves 16 variables, ANDed to make it simplier - 8 inputs).

    We will be using this as a contact sensor. A insulator will be placed in between two conductors. One of the conductors will be connected with the 5V supply, and the other one will be to the logic gate input itself. If the two conductors does not make contact, the output remains high (5V).
     
  2. jcsd
  3. Jan 23, 2013 #2
    Use a pulldown resistor.
     
  4. Jan 23, 2013 #3
    Are you sure your and gate is not a nand? Or have you just left an input floating as suggested by the prior comment - if so, that's a big no-no.
     
    Last edited: Jan 23, 2013
  5. Jan 23, 2013 #4
    sounds like floating inputs to me as well.

    use pulldown resistor to tie an input at zero volts, use a pullup resistor to tie an input to 5 volts depending on the logic needed at that gate.
     
  6. Jan 24, 2013 #5
    Yes, I just left the input floating.

    I did research about this pull-down resistor. And based on this, its just a normal resistor with values raging from 10K-47K, am I right?

    I also created a schematic of how I imagine the circuit would be. I have no simulators installed in this computer so I used paint instead. (See attached image)

    So what I think would happen is, I will let the input1 pin of the logic gate connected to the ground with the resistor. Once the two conductors make contact, the signal that will be received by the logic gate will become 1, otherwise, it is 0. Is that right?
     

    Attached Files:

  7. Jan 24, 2013 #6
    On an AND gate if you want the input condition on the open leg use a pull up resistor. same principle just tie the resistor to the 5 volt and one input leg. This will set a constant condition of 1 on that leg. so that when the other input goes to logical 1 the output will be logical 1.
    On an OR gate if you want a logic 1 on output when one input goes high you will need a pulldown resistor to tie the floating input to logical zero.
    All floating (open) inputs should either be tied high or low depending on the condition you wish to set. The range of resistors you mentioned will work. Its usually recommended to use a larger resistor for pullup than on the pulldown, but using the same value on both is fine.
     
  8. Feb 14, 2013 #7
    I would like to bring this up again. I've tried placing a 47K resistor in series with the input gates and let the input floating. Unfortunately, it does not give a low logic input.

    I really need to set the input to 0 because my circuit will always have a floating input. The insulator between the two conductors will make the circuit always open.

    Edit: Just kidding. My logic was messed up a while ago. Was able to work on this matter already. Sorry.
     
    Last edited by a moderator: Feb 14, 2013
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook




Similar Discussions: Open Circuit Problem with Logic Gates
  1. Logic Gates (Replies: 2)

  2. Logic gates. (Replies: 6)

Loading...