Continue to Site

# NAND Gate problem...

Status
Not open for further replies.

#### dark_vision

##### New Member
In theory, if input 1 and 2 are low then output is high right? so when the IC has Vcc and ground properly conected and no input, the output sholud be high right?
I'm having problems with that, if I put both input 1 and 2 high, the output if low, that's ok, then if I put that output in another input 1 and 2, the output is high, that's ok too... but now if I the input 1 of the first gate drops low, the output remains low, then the second output is high... what's wrong?

dark_vision said:
so when the IC has .... no input, the output sholud be high?

Logic gates float when unconnected. Depending on the type they can float high, low or oscillate. If an input is supposed to be fixed connect it to Vcc or ground. Unused gates can save power by fixing the outputs also.

Yes but input 1 and 2 depend on other states, and it doesn't matter if they're high or low, the output remains the same, low. Is there something that I'm not taking into consideration?

Perhaps there's something we don't know. Can you post your schematic, so we know what else is happening in the circuit?

If I read your description correctly, here is the truth table of your double NAND gate circuit:

Input.......Output
0 0.............0
0 1.............0
1 0.............0
1 1.............1

You've basically designed an AND gate with NAND gates. It should be working if you've connected everything as you explained. On a side note, it's interesting to know that you can create every basic logic gate by using combinations of NAND/NOR gates, just like you did for an AND function result.

dark_vision said:
so when the IC has Vcc and ground properly conected and no input, the output sholud be high right?

nope, some gates while floating take it as high so output may be low. it depends on the family. some times they ma oscilate also. it always good practice to connect unused inputs to either GNd or Vcc.

abhishek

Well I have figured out one thing, it works as it should when either Vcc or Ground is conected directly to the inputs, so what I need is a way to give voltage to an input if the source is conected, and if it isn't conect it to ground. I can accomplish it with a 2 state switch, so when it is on it let the current flow, otherwise it conects the input to Ground.
Now I need to find a way to do it without manual interaction.

Any idea?

BTW, it's getting complex, and all I need is the gate to make a decision based on changing inputs, isn't there a site that explains how to implement this basic funcionallity on a protoboard? Because all the sites I've seen talk only about the theory of it.

This is the basic idea

(I am a NAND Gate)
|
v
_____
LPT Pin 1 ----------| \
| 7400 |--------- LED
LPT Pin 2 ----------|_____ /

Put a 1Mohm resistor between input and ground. It will pull the input to ground if no connection but will be easily overridden by a connection.

Status
Not open for further replies.

Replies
3
Views
776
Replies
20
Views
3K
Replies
54
Views
4K
Replies
5
Views
1K
Replies
4
Views
2K