ALI SHAYAN (ME-191028)
IN-LAB TASKS
Q1) What is the difference between microcontroller and development board?
ANS) Microcontroller is a small computer on a single chip containing a processor, memory, and
input/output. A microcontroller is often small and low cost and It is typically "embedded" inside
some device that they control.
Development board is a printed circuit board designed to facilitate work with a particular
microcontroller. It includes a power circuit, programming interface, basic input which is usually
buttons and LEDs which are I/O pins.
A microcontroller board would emphasize digital and analog control interconnections to some
controlled system, whereas a development board might have only a few or no discrete or
analog input/output devices. The development board exists to showcase or train on some
particular processor family and, therefore, internal implementation is more important than
external function.
Q2) List different ports of Arduino UNO and explain their usage.
ANS)
Reset Button: This button restarts any code that is loaded to the Arduino board.
AREF: It stands for “Analog Reference” and it is used to set an external reference
voltage.
Ground Pin: There are a few ground pins on the Arduino and they all work the same.
Digital Input and Output: There are 14 pins which can be used for digital input or output.
PWM: These pins are marked with the (~) symbol can simulate analog output.
USB Connection: It is used for powering up your Arduino and uploading sketches.
TX/RX: It transmits and receives data indication LEDs.
ATmega Microcontroller: This is the brains and is where the programs are stored.
Power LED Indicator: This LED lights up anytime the board is plugged in a power source.
Voltage Regulator: This controls the amount of voltage going into the Arduino board.
DC Power Barrel Jack: This is used for powering your Arduino with a power supply.
3.3V Pin: This pin supplies 3.3 volts of power to your projects.
5V Pin: This pin supplies 5 volts of power to your projects.
Analog Pins: These pins can read the signal from an analog sensor and convert it to
digital.
Q3) What is Arduino IDE? How many times is it already downloaded?
ANS) The Arduino Integrated Development Environment (IDE) contains a text editor for writing
code, a message area, a text console, a toolbar with buttons for common functions and a series
of menus. It connects to the Arduino hardware to upload programs and communicate with
them and it has 66,239,349 downloads currently.
1
ALI SHAYAN (ME-191028)
Q4) What are the two default functions when you open the IDE?
ANS) The first default function is void setup, in this function the user inputs the setup code
which runs once.
The second default function is void loop, in this function the user inputs the main code and this
code is run repeatedly.
Schematics:
Code: