A
Practical activity Report submitted
For Engineering Design Project-II (UTA-014)
By
Simranjit Singh 102088007
Submitted to
Dr. Karamjeet Singh
DEPARTMENT OF COMPUTER SCIENCE and ENGINEERING
THAPAR INSTITUTE OF ENGINEERING AND TECHNOLOGY,
(A DEEMED TO BE UNIVERSITY), PATIALA, PUNJAB
INDIA
July-Dec 2020
Experiment: 2
Objective: Write a program in Arduino to blink a LED.
Software Used: Tinkercad Simulator
Hardware Component Used:
Sr. no. Component No. components
1 Arduino Uno microcontroller 1
2 Resistor 1
3 Led 3
4 Breadboard 1
Theory:
1. Arduino: It is the main component of our circuit, led is connected to it by jumper
wires. It provides electrical supply to the led and control the supply according to the
code given by the user. It has a microprocessor which decodes the code and gives
commands to its different ports whenever required (according to the code).
Arduino Uno Microcontroller
2. Resistor: Resistors are electronic components that provide resistance in the circuit or
in other words it reduces the current in the circuit. It is measured in ohm (Ω).
Different types of resistors are available in markets. We use it prevent excessive
current to led.
Resistors
3. Led: A light-emitting diode (LED) is a semiconductor light source that emits light
when current flows through it. Electrons in the semiconductor recombine with
electron holes, releasing energy in the form of photons. The colour of the light
(corresponding to the energy of the photons) is determined by the energy required for
electrons to cross the band gap of the semiconductor.
LED
4. Breadboard: A breadboard is a rectangular plastic board with a bunch of tiny holes
in it. These holes let you easily insert electronic components to prototype (meaning to
build and test an early version of) an electronic circuit, like this one with a battery,
switch, resistor, and an LED (light-emitting diode).
Breadboard
Logical Circuit diagram (Tinkercad Circuit diagram):
Coding:
int a;
void setup()
{
pinMode(a, OUTPUT);
}
void loop()
{
for(a=0; a<4; a=a+1)
{
digitalWrite(a, HIGH);
delay(1000);
digitalWrite(a, LOW);
}
}
Discussion:
In this experiment, we have learnt how to blink multiple leds with arduino using a
breadboard and resistor. During this experiment, i gain knowledge about digitalwrite
and delay commands of arduino. I use for loop in combination of digitalwrite and
delay command to blink led
Signature of Faculty member