Hello friends, I hope all are fine and having fun with your projects. We have covered enough Arduino commands in this Arduino Tutorial for Beginners series and now we are ready to create a simple project by interfacing an LED (Light Emitting Diode). Today, I am going to share a very Simple Arduino LED Example in Proteus ISIS. First I will blink single LED using Arduino UNO and then I will blink multiple LEDs in Proteus.
When you start working on Arduino then Arduino LED example is the first example which you must try because its the easiest one. Moreover, we all know that we have a small LED connected to pin # 13 on each Arduino so you can also check your Arduino as well that whether its working or not. So, let's get started with Simple Arduino LED Example in Proteus ISIS:
A Simple Arduino LED Example in Proteus
You can download, all the simulation files and codes for Arduino LED examples used in this tutorial, by clicking the below button:
First of all, design a simple circuit of Arduino LED in Proteus ISIS as shown in below figure:
Now as you can see in the above figure that I have used an LED on Pin # 13 of Arduino UNO.
So, now upload the below sketch in your Arduino, its the Blink Example from Arduino, which works perfect for this Arduino LED Example:
void setup() {
pinMode(13, OUTPUT);
}
// the loop function runs over and over again forever
void loop() {
digitalWrite(13, HIGH); // turn the LED on (HIGH is the voltage level)
delay(1000); // wait for a second
digitalWrite(13, LOW); // turn the LED off by making the voltage LOW
delay(1000); // wait for a second
}
The above code is quite simple and you can see first we have used the pinMode Arduino Command to make the LED pin Output.
Now get the hex file from Arduino software and add it in your Proteus Arduino board.
Once the hex file is uploaded in the Arduino then run your Arduino LED Proteus Simulation and if everything goes fine then your LED will start blinking as shown in below figure:
Now you can see in the above figure that our LED at Pin # 13 started blinking.
If you read the above code of Arduino LED exmaple then its quite simple, first of all I just make the Pin # 13 output and then I have made it HIGH and LOW with a delay of 1000 msec.
syedzainnasir
I am Syed Zain Nasir, the founder of The Engineering Projects (TEP). I am a
programmer since 2009 before that I just search things, make small projects and now I am sharing my
knowledge through this platform. I also work as a freelancer and did many projects related to
programming and electrical circuitry. My Google Profile+Follow
Get Connected
Comments on ‘’ A Simple Arduino LED Example in Proteus ‘’ ( 2 )
0
bob1
Says:
What awful code. Ever hear of a loop?
Reply
100
1
syedzainnasir1
Says:
Check the next tutorial and you will know why I didn't use loop here ... :P :D
Reply