4
\$\begingroup\$

I am trying to make a very simple AND Logic gate with the help of a breadboard. This is my first time using all this. I have referred to the video http://www.youtube.com/watch?v=x9R9KAtTyWA

It said that IC 7408 is for AND Gate and I bought that only. The code on this chip that I bought is PO148SD MM74HC08N MC74HC08N

So I did everything that was in that video but still my LED didn't lit on 1 1 output. What am I doing wrong? Breadboard_Positive_Voltage_Top

\$\endgroup\$
3
  • \$\begingroup\$ Some more i.sstatic.net/Pgwq6.jpg i.sstatic.net/JsMEs.jpg \$\endgroup\$
    – mr-karan
    Commented Jan 4, 2013 at 3:46
  • \$\begingroup\$ Try taking a picture right side up and in focus. \$\endgroup\$ Commented Jan 4, 2013 at 13:33
  • \$\begingroup\$ Try to extract a schematic from your breadboard. (Note: Picture rotated so it displays nicely. \$\endgroup\$
    – zebonaut
    Commented Jan 4, 2013 at 23:02

2 Answers 2

7
\$\begingroup\$

Things to check:

  • You have the IC the right way round (pin 1 will have a small dot next to it, or an indent/marking at that side of the case of some sort) If the indent is at the top in the picture in your question then it appears you have the wiring correct (pins 1 and 2 are the inputs to the first AND gate, and pin 3 is the output)
  • Your wiring is all correct and supply voltage is present.
  • The LED is the right way round - the flat side of the case is the cathode -this is the side that should go to ground. The also cathode usually has a shorter lead.

Also, it's possible you destroyed your LED - you need a current limiting resistor in series with it. I'm assuming it's a red LED, and the supply voltage is 9V from the pictures, so try 360Ω (or anywhere between 360Ω and 2.2kΩ if you don't have this value)

EDIT - the datasheet provided by Mike says the absolute maximum supply is 7V, nominal 5V. This means it's quite likely your IC is dead. Unless you have a higher voltage variant of the chip, you need a lower supply voltage (e.g. 5V) With 5V the calculations for the LED resistor range below will be out, but the LED will still be visible (just a bit dimmer)

If my above assumptions are incorrect, do a search for "LED resistor" on here and you should find plenty of advice on why the resistor is needed and how to calculate it's value.

To test whether your LED is dead, try measuring it with a multimeter on the diode/continuity range - it's should read around 2V for a red LED with red probe to anode and black probe to cathode (note - some cheap multimeters cannot measure LED forward voltages, especially if it's an LED with a higher Vf, e.g. a white or blue LED)
Or just simply try another one (hopefully you have a few ;-) )

LED resistor

A diode has a very steep I-V curve, which basically means it passes almost no current up to a certain voltage (forward voltage - Vf) and then the current rises very sharply. This means you can't control the current just by setting the voltage at the right level, since with the tiniest change (e.g supply, temperature) the current will vary hugely.

So we use a resistor to limit the maximum current that the LED can pass. Most 5mm LEDs are rated for 20mA maximum, but will be clearly visible at 10mA. In the datasheet they will have a Vf spec mentioned above. I'll assume your LED is red, has a Vf of 2V, and we want it to pass 10mA - here's how to calculate:

(V_supply - LED_Vf) / desired_current = resistor value

So, with a 5V supply, and your LED_Vf of 2V:

(5V - 2V) / 0.010A = 300Ω

Simply place the resistor in series with the LED (cathode or anode side, it doesn't matter) If your LED is a different colour, check it's datasheet, find the Vf and run the calculations again.

Here is an example of how the LED and resistor should be arranged (assume the voltage source is your AND gate output pin):

LED example schematic

Here's an example on a breadboard (taken from one of my recent blogs, so it's a microcontroller, not an AND gate, but the principle is exactly the same. I annotated it a bit to help clarify things)

LED Breadboard Example

\$\endgroup\$
9
  • \$\begingroup\$ Well thanks for your response! And I haven't done any of this before so can you tell me how will I connect a resistor? (noob here) BTW I tried to connect the LED starightwaway with the battery and it lit. ! Thanks much \$\endgroup\$
    – mr-karan
    Commented Jan 4, 2013 at 4:48
  • \$\begingroup\$ I added a bit on the LED resistor calculation, hope this helps. \$\endgroup\$
    – Oli Glaser
    Commented Jan 4, 2013 at 4:59
  • \$\begingroup\$ Thanks. So I'll go the shop today and get a new 7408 chip, a new LED and a 500 ohm resistor. Will that be fine? \$\endgroup\$
    – mr-karan
    Commented Jan 4, 2013 at 5:12
  • \$\begingroup\$ Yep, that sounds fine (I'd grab a few of each if you can, just in case...) If you tested the LED with the battery, and it's definitely in the right way, then it does sound like your IC is dead. Let us know how it goes when you try again. \$\endgroup\$
    – Oli Glaser
    Commented Jan 4, 2013 at 5:37
  • \$\begingroup\$ Need some clarification. The pin having a circular indent is Pin 1 yeah ? And have I done the wiring properly here? That D is semicircular indent and the o is circular indent in the image imgur.com/HQRVn \$\endgroup\$
    – mr-karan
    Commented Jan 4, 2013 at 8:19
4
\$\begingroup\$

It looks you have it hooked up wrong according to the 7408 schematic http://www.ti.com/lit/ds/symlink/sn74ls08.pdf - The output is on pin 8 and the input is pin 9 and 10. You are using 10 as the output, 8 and 9 as the input.

On the LED are you sure the anode (the longer leg) is connected to the yellow wire?

Regarding the battery, you should be supplying it with 5V max. It looks as though you are using a 9V supply. The IC is rated for 5.25V max so that may ruin the chip.

I would switch your pins, 8, 9 and 10 and try that. It may work with the higher voltage.

:edit: You also have the LEDs cathode going to the positive voltage, you want it going to ground.

\$\endgroup\$
7
  • \$\begingroup\$ I'm thinking the white lead is going to ground, and the "dot" at the bottom right of the IC is a red herring (e.g. a bit of dust or something) If you look closely it seems there is a semi-circular indent at the other side of the IC (top in the picture) It also makes sense because the two yellow leads are coming from what would be the positive supply if the the white lead is going to ground. \$\endgroup\$
    – Oli Glaser
    Commented Jan 4, 2013 at 4:20
  • \$\begingroup\$ I see what you are saying with pin 1. Scratch that.. \$\endgroup\$
    – Michael
    Commented Jan 4, 2013 at 4:29
  • \$\begingroup\$ ... It may just be the 9V input, it looks like it is wired correctly assuming the LED is the right polarity. \$\endgroup\$
    – Michael
    Commented Jan 4, 2013 at 4:36
  • \$\begingroup\$ Yes I think it does too, so I'm thinking the LED is the wrong way round, or it and/or the IC are blown (it has a absolute max supply of 7V according to the datasheet, so the chances are good..) Hopefully the OP will clarify shortly. \$\endgroup\$
    – Oli Glaser
    Commented Jan 4, 2013 at 4:38
  • 2
    \$\begingroup\$ Yes the short lead is the cathode side and should go to ground (the case also has a flat part on the cathode side) It will probably work for a while at 9V with a 9V battery as they have a pretty high internal resistance, so can't force too much current through the IC to destroy it. Either way though, it's a bad idea so you need to change it to 5V. \$\endgroup\$
    – Oli Glaser
    Commented Jan 4, 2013 at 4:47

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.