Blogroll

Powered by Blogger.

Thursday 3 July 2014

How to Control 74HC00 / 74HCT00, NAND Gate, Using Arduino Mega?

by realfinetime  |  in TTL at  10:26

          I had already published my blog on controlling 74HC00 / 74HCT00 Quad 2-Input NAND Gate using switches. Controlling 74HC00 / 74HCT00 using Arduino is simple. Here instead of switches, those pins are connected to two digital output pins of Arduino as shown in the following image. Power supply for the working of IC ( Vcc ) is supplied from 5V pin of Arduino. Similarly GND pin of 7400 is connected to the GND pin of Arduino. Pull down resistor ( 10K ) is not relevant in this case. But its better to connect pull down resistors as shown in the following image. An LED is connected to the output of the NAND gate through a series current limiting resistor ( 1K ).


Truth table of NAND gate when connected to Arduino.

             Truth table of  NAND gate when connected to Arduino is given below. Led will turn on if any of the input is LOW. LED will turn off when both inputs are HIGH.

A simple program to control NAND gate using Arduino is given below.

void setup()
{            
  pinMode(8, OUTPUT);  
  pinMode(9, OUTPUT);
}

void loop()
{
  digitalWrite(8, LOW);
  digitalWrite(9, HIGH);
  delay(1000);            

  digitalWrite(8, HIGH);  
  digitalWrite(9, HIGH);
  delay(1000);            

  digitalWrite(8, HIGH);  
  digitalWrite(9, LOW);
  delay(1000);

  digitalWrite(8, LOW);  
  digitalWrite(9, LOW);
  delay(1000);
}

Upload the above program to your arduino board. If the circuit is correct and uploading is successfull, LED will remain off for three seconds. Then turn on for next one second. This process continues for ever.

Read more :

0 comments:

IMPORTANT NOTICE

All the circuits, published in this blog is only after testing and getting proper results in my private lab. When you try these circuits, you should check the supply voltage, polarity of components, presence of childrens nearby and shorts in the circuits. This website will not be responsible for any harm happened to you or your components caused by your carelessness.

For More Electronic Tips



Blog Archive

Proudly Powered by Blogger.