Introduction: LED BLINK WITH ARDUINO
IN THIS STEPS I WILL SHOW YOU HOW SIMPLE IT IS TO MAKE AN LED BLINK WITH ARDUINO.
LET'S GET STARTED.
Step 1: Watch YouTube Video
WATCH THE VIDEO.
Step 2: Hardware Part. Choose Your LED.
Choosing your led is very important. You should use an LED with a nominal voltage below 5 volts because the Arduino can only supply 5 volts with a maximum current of 40 milliamps. If you want to use high power LED use a transistor. This 5mm green LED only draws only 10 milliamps at 3 volts.
Step 3: Choose Your Arduino
To control the LED you need an Arduino. You can use Arduino mega, nano, Pro mini. But I will be using an Arduino UNO as it has female headers which will be easy for us to connect our led.
Step 4: Choose the Value of the Resistor
As you might have guessed that the output voltage of the Arduino UNO is 5 Volts. But the led can only take 3 Volts.So we need a resistor. when we calculate the resistance we get 200 Ohms. You can calculate the resistance of the resistor needed for your LED project from this link below:
Step 5: Solder the Resistor to the LED
Solder the Resistor to the positive terminal of the LED. you can also use female to female jumper wires if you don't have access to Soldering iron.
Step 6: Use Jumper Wires to Extend the Connection (optional)
If the length of the connections were too short use male to female jumper wires.
Step 7: Connections With Arduino
Connect the positive terminal of the LED to the digital pin 5 of the Arduino and the ground pin of the LED to the ground pin of the Arduino.
Step 8: Software Part. CODE EXPLANATION
Download this code.
Firstly, we declare the output pin as 5.
In the setup section,
we declare LED as the output and the LED to be off initially.
In the loop section,
we tell the Arduino to turn on the LED .
Then we delay for 100 milliseconds. If you want to increase the ON OFF duration of the LED increase the time in milliseconds in the bracket.
Then we tell the Arduino to turn off the LED and we delay for another 100 milliseconds.
This process continues until the power goes OFF.
Step 9: Upload the Code to the Arduino
Upload the code to the Arduino. Wait until the RX TX LED stops blinking.
Step 10: Result: Output of the LED.
We can see that the LED blinks.
Check out my channel for more upcoming videos.
THANK YOU AND HAVE A NICE DAY.