inverting an AND gate without inverters?

Thread Starter

boomboomtheduckling

Joined Nov 11, 2013
3
How can you do this?

I'm using a 74ls08 AND gate, on a bread board.

Hooked up a basic AND gate, got the LED to light up.

My teacher says there is a way to make the AND gate a NAND gate without using the 74lsXX NOT gate.

Any ideas?

I know I did this by accident, but darn it, I don't remember how....

Any Ideas for good reading on this sort of stuff?

Thank you very much
 

absf

Joined Dec 29, 2010
1,968
Or you can connect the output of the AND gate to the "Base" of a Common Emitter NPN transistor and connect the LED between the "Collector" and +5V.

Allen
 

DerStrom8

Joined Feb 20, 2011
2,390
Or you can connect the output of the AND gate to the "Base" of a Common Emitter NPN transistor and connect the LED between the "Collector" and +5V.

Allen
If I am understanding you correctly, that will not invert the output. Did you mean PNP?
 

DerStrom8

Joined Feb 20, 2011
2,390
What are you thinking? A NPN common emitter amplifier circuit is an inverter.
Oops, I was thinking of something else. My mistake. :rolleyes:

I'm actually beginning to wonder if my original thought would work. It's been a while since I've worked with logic circuits....

I'd say the common emitter NPN would be your best bet.
 
Last edited:

Thread Starter

boomboomtheduckling

Joined Nov 11, 2013
3
Thank you for the replies.

I don't think it was clear from what I wrote, but I was told, (if I understood correctly) that there was a way to invert the output without adding any other IC's. ABSF, did you mean just hooking the circuit back into itself? DerStrom8, I was thinking about reversing the led and putting a current through that. So it would be on when the output was 0. Would putting a ground between the the output and the led work in inverting it? So when output is 1, it shorts to ground?

Thanks again!
 

shteii01

Joined Feb 19, 2010
4,644
Thank you for the replies.

I don't think it was clear from what I wrote, but I was told, (if I understood correctly) that there was a way to invert the output without adding any other IC's. ABSF, did you mean just hooking the circuit back into itself? DerStrom8, I was thinking about reversing the led and putting a current through that. So it would be on when the output was 0. Would putting a ground between the the output and the led work in inverting it? So when output is 1, it shorts to ground?

Thanks again!
Ok. Original setup. The AND gate.
IC-->LED + leg-->LED - leg-->current limiting resistor-->Ground
IC goes high (1), there is current flows from IC to ground, LED light up.

The reversed LED setup.
IC-->LED - leg-->LED + leg-->current limiting resistor--> + power supply
IC goes low (0) and it act as a "ground" also known as current sinking, there is current flow from + power supply to "ground", LED light up. Keep in mind that there are limits on how much current the IC can sink.
 

DerStrom8

Joined Feb 20, 2011
2,390
The current source/sink idea was the one I was originally thinking of, but I couldn't remember if AND gates could sink current. I' more used to microcontrollers (where it works), but I was unsure about regular logic gates.
 

t06afre

Joined May 11, 2009
5,934
The current source/sink idea was the one I was originally thinking of, but I couldn't remember if AND gates could sink current. I' more used to microcontrollers (where it works), but I was unsure about regular logic gates.
It does not matter then it comes to standard TTL logic gates as they almost all share the same "totem-pole" output stage.
 

ScottWang

Joined Aug 23, 2012
7,400
If your described was that you have the AND gate and NAND gate then the answer is on the NAND gate, and it's easy, you just figure out the function of NAND gate then the answer will come up.
 

WBahn

Joined Mar 31, 2012
30,060
It does not matter then it comes to standard TTL logic gates as they almost all share the same "totem-pole" output stage.
I'm not following something here.

IIRC, standard TTL (i.e., 74xx) could source up to 400μA but could sink 16mA. Also, the LO output was spec'ed to be no higher than 0.4V but the HI output could be as low as 2.4V (less than half the supply voltage) and still be in spec.

That's a factor of 40 between sink and source capabilities -- and that disparity is pretty much the same across all the TTL families such as 74H, 74L, 74LS, 74S with none of them being spec'ed to source more than a milliamp.

So driving an LED so that it is lit by an active HI output signal from a TTL gate is not a good idea.
 

Thread Starter

boomboomtheduckling

Joined Nov 11, 2013
3
Allright, Thank you again everyone. I'm REAL new to this electronics and ttl cmos, etc.. stuff. Talking with my lab partner, he came up with an idea of reversing the LED and grounding it at the output. (Like Derstrom said) So, without going too much deeper like driving outputs, etc.. I got a solution. I just need to do some catch up. I'm in a class that's within my grasp, but barely. I have to go over some basics, and this site has been excellent to search through. Thank you everyone for your answers and discussion.
 

t06afre

Joined May 11, 2009
5,934
I know very well what your teacher are looking for. Since this the homework section I will not handle the solution on a silver plate. But a hint, connect the LED to and the current limiting resitor to the +5 volt. Then think about the current flow flow then the output logical 1 and logical 0 from the gate. And also a note i think the WBahn make a quite seldom brain fart on this one. In 7374 post. This is the first from him ever I can remember.
 

DerStrom8

Joined Feb 20, 2011
2,390
I know very well what your teacher are looking for. Since this the homework section I will not handle the solution on a silver plate. But a hint, connect the LED to and the current limiting resitor to the +5 volt. Then think about the current flow flow then the output logical 1 and logical 0 from the gate.
I believe that's what the OP figured out already.

Important point though, don't forget the resistor!
 

MrChips

Joined Oct 2, 2009
30,808
And also a note i think the WBahn make a quite seldom brain fart on this one. In 7374 post. This is the first from him ever I can remember.
I am not sure what error you are referring to.
7400 series TTL is designed to source only 400μA on a logic high output, not sufficient to drive LEDs.
 

WBahn

Joined Mar 31, 2012
30,060
I know very well what your teacher are looking for. Since this the homework section I will not handle the solution on a silver plate. But a hint, connect the LED to and the current limiting resitor to the +5 volt. Then think about the current flow flow then the output logical 1 and logical 0 from the gate. And also a note i think the WBahn make a quite seldom brain fart on this one. In 7374 post. This is the first from him ever I can remember.
Oh, it wouldn't be the first one. But I'm not sure what you are referring to by the "7374 post". Please clarify.

I went back and looked the poster is using a 74LS08 AND gate. One thing I noted, but didn't comment on, when I first read the post was that the OP didn't indicate whether his LED was lighting when the output was HI or when it was LO. I inferred that he had it operating so that it was lighting when the output was HI so that the function was that the LED is ON when both inputs are HI -- or a positive logic AND gate.

But I'm not so sure of that since the 74LS family is only spec'ed to source 0.8mA, so if he is driving an LED when HI, he is probably abusing that poor gate pretty harshly if he is getting it to light at all.

It would help if the OP could clarify what their circuit actually is and also what definitions of the logic levels are. For instance, if the LED is ON, is that considered a logic TRUE output.
 

t06afre

Joined May 11, 2009
5,934
I am not sure what error you are referring to.
7400 series TTL is designed to source only 400μA on a logic high output, not sufficient to drive LEDs.
As I see it this was kind of a trick question. Then the both inputs to the AND gate is zero. The LED should be on(light) then both the inputs to AND is 1 the LED should be off
@Wbhan Your numbers postings in this furum was 7374 then I posted my answer
 

MrChips

Joined Oct 2, 2009
30,808
Don't use the Posts: ### since that changes with every post made. Use the post # in the thread.

7400 gates were not meant to drive LEDs high directly.

You can use 7400 gates to sink current through a series resistor and LED with the anode of the LED connected to +5V. In this case the LED will display the inverted logic output (LED ON with LOW output).
 
Top