# AND circuit

Discussion in 'General Electronics Chat' started by chrischrischris, Sep 9, 2012.

1. ### chrischrischris Thread Starter Active Member

Feb 18, 2012
295
11
Hi.
I've been able to find circuits to test creating a NOR gate - via an NPN 547 and a few diodes - connected to an LED.

What I haven't been able to find is a good example of creating an AND gate with 2 diodes and a pull up resistor (along with an LED).

When I try the circuit above (applying voltage to both "A" and "B"), when I measure between "out" and "ground", I can't get this circuit to make any difference when I turn off the voltage say at "A". I'm just seeing voltage drops across the diodes. Can someone tell me how I can do this as a test.

File size:
5.6 KB
Views:
84
2. ### MrChips Moderator

Oct 2, 2009
18,340
5,796
This circuit should work.
Vout = V only when both A AND B are set to V.
When A or B is set to GND, Vout = 0.6V
What is your applied voltage V and the value of the resistor R?

3. ### ErnieM AAC Fanatic!

Apr 24, 2011
7,977
1,838
And where is that LED? If you have it in series with the resistor the LED will be on as long as the NOT AND condition is being met: either input low turns the LED ON.

If the LED doesn't come on for either input low... you aren't making the input truly low: are you leaving it open and assuming that is low?

Not for this circuit. Low means grounded to zero volts.

4. ### JMac3108 Active Member

Aug 16, 2010
349
67
How about posting the complete circuit showing how you've connected the LED. I'm sure someone will spot the problem immediately for you.

5. ### BillB3857 AAC Fanatic!

Feb 28, 2009
2,480
382
Turning OFF the voltage is not the same as GROUNDING the input. Try it... You'll like it.

6. ### chrischrischris Thread Starter Active Member

Feb 18, 2012
295
11
Sorry for not replying queries earlier - got caught up.
Via a transistor I'm trying to setup a NOR gate. I then wanted to put this signal into an AND gate (2 diodes) along with a signal from an IC. With 2 high's I wanted a signal to be sent. With 1 high and 1 low - no signal. With 2 lows no signal.

I have an existing circuit, so the "easiest" for me would have been to add just a couple of diodes and transistor instead of another IC.

The AND circuit I've shown above, was giving the following results:

• * "OUT" was high when "A", "B" and "V" were high
* "OUT" was 0.7V when "A" and "V" were high and "B" was low
* "OUT" was 0.7V when "B" and "V" were high and "A" was low
* "OUT" was low when "A" and "V" were high and "B" was low

I'm guessing I'd have to add a pull-down resistor somehow to fix the problem? Or a diode or 2 on the "out" point?

7. ### BillB3857 AAC Fanatic!

Feb 28, 2009
2,480
382
I'm confused. (normal state) You have a 2 input gate and are listing 3 values (A, B, V)+ an output. Where does V come in? Do you now have a 3 input gate? It really won't make much difference. What you are seeing is the forward drop of the diode that has the input side grounded. The gate works by the pull up trying to make the output HIGH. If any diode has its anode grounded, it will conduct, pulling the junction of the resistor and all diodes toward ground. It is quite normal for a simple diode/resistor gate to see a 0.7 volt output to represent LOW state.

8. ### chrischrischris Thread Starter Active Member

Feb 18, 2012
295
11
Sorry. V is the supply voltage.
It's A and B that I was testing turn on and off.
Yes, the 0.7V I guessed was from the diodes.
However I'm thinking this value may be enough to trigger a false switching for what I'm trying to do.

I just found on the net a method of doing the same with 2 NPNs:

The above I assume would give an out of zero voltage?

File size:
11.3 KB
Views:
41

Oct 2, 2009
18,340
5,796
Looks good.

10. ### BillB3857 AAC Fanatic!

Feb 28, 2009
2,480
382
DUH...... All I needed to do is look more closely to your original drawing. Normally, it is assumed that power will always be applied, not necessarily listed as another condition.

11. ### ErnieM AAC Fanatic!

Apr 24, 2011
7,977
1,838
This circuit:

Makes a very poor AND gate because the B input works as an emitter follower to the emitter resistor, and even with A low it can still drive the output thru the base with no gain from the transistor.

I know, I thought of this circuit when I was a kid and built and tested it and it taught me some things about transistors.

12. ### Wendy Moderator

Mar 24, 2008
21,592
2,977
It is possible to make a AND gate with diodes and a resistor, but generally I use it as a stop gap method for CMOS logic. However, it will work with a LED, though not perfectly....

File size:
1.9 KB
Views:
26
13. ### Austin Clark Active Member

Dec 28, 2011
412
47
Yay! TRL is, for whatever reason, my favorite type of logic thus far (though I feel as though CMOS will be better for me, whenever I decide to order some MOSFETs). I've ran into this exact same issue with B driving a HIGH output even when A isn't HIGH. To fix this issue, I would use PNP transistors instead, in a different configuration, where the output would be driven LOW only when both inputs were LOW. Another solution could be using a NAND with another NOT gate after. It'd have the added benefit of potentially greater fan-out too, as the additional NOT stage could add gain. In general I like pull-up configurations better.