Alll
Alll
Experiment No: 1
211260131058
TITLE: Introduction to Arduino Board, Arduino IDE and Cables.
EXERCISE:
(1) Define different types of Arduino Boards.
Arduino boards are open-source hardware and software platforms used for building digital
devices and interactive objects that can sense and control objects in the physical world.
These boards are categorized into three main categories: Entry Level boards, Enhanced boards,
and IoT boards. Each board has its own unique features and capabilities, making them suitable
for a wide range of applications. The choice of board depends on the specific requirements of
your project.
Here, are some of the commonly used Arduino boards:
• Arduino UNO R3
• Arduino Nano
• Arduino Leonardo
• Arduino Micro
• Arduino Due
• Arduino Zero
IOT( 3160716 )
6th Sem CSE D2 211260131052
3) IoT Boards
211260131058
1. Arduino Uno (R3): This is the most popular and widely used development board. It
consists of 14 Digital I/O out of which 6 pins are 8-bit PWM pins, 6 pins are 10-bit Analog
inputs, and basic communication ports like SPI, I2C, and UART.
2. Arduino Nano: This is a small breadboard-friendly version of Arduino UNO. It has more
or less functionality of the Arduino UNO but in a small form factor. The only major
differences from UNO are the lack of a DC power jack, the usage of a Mini USB port
instead of a USB B port, and the USB-TTL converter chip.
3. Arduino Mega (R3): This board is designed for projects that require more I/O lines, more
sketch memory, and more RAM. With 54 digital I/O pins, 16 analog inputs, and a larger
space for your sketch, it is the recommended board for 3D printers and robotics projects.
4. Arduino Due: This is a microcontroller board based on the Atmel SAM3X8E ARM
Cortex-M3 CPU. It is the first Arduino board based on a 32-bit ARM core microcontroller.
6. Arduino Leonardo: This board is based on the ATmega32u4. It has 20 digital input/output
pins (of which 7 can be used as PWM outputs and 12 as analog inputs), a 16 MHz crystal
oscillator, a micro-USB connection, a power jack, an ICSP header, and a reset button.
IOT( 3160716 )
6th Sem CSE D2 211260131052
1. USB Cables: An Arduino typically only requires a USB cable to be used as a power source
and to connect to a computer for programming. A USB Type B cable can be used for the
most popular Arduino model (Uno), however other Arduino boards may require Type B-
mini or micro connectors.
2. Power Adapter Cables: A power adapter cable can also be plugged into the Arduino to
power the board when separate from a USB power source.
3. Ethernet Cables: Particularly Category 6 (Cat 6) and Category 6a (Cat 6a) cables are
widely used for IoT applications. They offer high-speed data transmission, low signal
interference, and backward compatibility with older Ethernet standards.
4. Antenna Cables: These are used for wireless technologies in IoT. Among the maze of
connectors, six types stand out: SMA, RP-SMA, U.FL, MHF4, MMCX, and N-type.
5. Coaxial Cables: These are used for radio frequency signals and are commonly used in IoT
applications that require wireless connectivity.
6. Fiber Optic Cables: These are used for high-speed data transmission over long
distances. They are commonly used in IoT applications that require high bandwidth.
7. Jumper Wires: These are used for making connections between different components on
a breadboard or between an Arduino and a breadboard. Typically, the most suitable wires
to use with an Arduino are single stranded 22AWG or 0.65mm
QUIZ:
(1) Install Arduino IDE in your system.
To install Arduino IDE in your system, you need to follow these steps:
• Download the correct and latest version of Arduino IDE software from the Arduino
website according to your system’s specifications. It is available for both 32-bit and 64-
bit systems.
• After downloading the IDE software, open the .exe file. Then proceed with the
installation and please wait for the driver installation process to finish.
• Choose the components to install and the installation directory. The process will extract
and install all the required files to execute properly the Arduino Software (IDE).
• Once the installation is complete, you can launch the Arduino IDE and start coding and
uploading your sketches to your Arduino board.
IOT( 3160716 )
6th Sem CSE D2 211260131052
Here are the hardware and software requirements for installing the Arduino IDE:
Hardware Requirements:
• Arduino Board: You’ll need an Arduino board like Arduino UNO R3, etc. According, to
your requirement.
• USB Cable: A USB TTL Serial cable or a Micro-USB cable is required to connect the
Arduino board to your computer , depending on the type of Arduino board you have. You
also need a computer that meets the minimum system requirements for running the Arduino
IDE software.
Software Requirements:
• Arduino IDE: You’ll need the Arduino IDE software. The latest version can be
downloaded from the official Arduino website. India
IOT( 3160716 )
6th Sem CSE D2 211260131052
TITLE: To interface LED / Buzzer with Arduino Uno and write a program to
turn ON LED for 1 sec after every 2 seconds.
Hardware Required:
• Arduino UNO Board
• LED
• 220 ohm resistor
• USB cable ~ connect to computer
Exercise:
(1) Try to implement with different types of LED
(2) Implement it with different type of Arduino board and check the output.
I. BEFORE
CODE
void setup()
{
// initialize digital pin 9 as an output.
pinMode(9, OUTPUT);
}
IOT( 3160716 )
6th Sem CSE D2 211260131052
void loop()
211260131058
{
digitalWrite(9, HIGH); // turn the LED on (HIGH is the voltage level)
delay(1000); // wait for a second
digitalWrite(9, LOW); // turn the LED off by making the voltage LOW
delay(2000); // wait for a 2 second
}
AFTER
II. BEFORE
IOT( 3160716 )
6th Sem CSE D2 211260131052
CODE 211260131058
void setup()
{
// initialize digital pin 2 as an output.
pinMode(2, OUTPUT);
}
AFTER
IOT( 3160716 )
6th Sem CSE D2 211260131052
TITLE: To interface Push button with Arduino Uno and write a program to
turn ON LED when push button is pressed or at sensor detection.
Hardware Required:
• Arduino UNO Board
• LED
• 220 ohm resistor
• USB cable ~ connect to computer
• PUSH button
Exercise:
(1) Compare both the result i.e. before & after the PUSH button pressed, check the result of
LED.
BEFORE
CODE
int buttonState=0;
void setup()
{
pinMode(11, OUTPUT);
pinMode(4, INPUT);
}
IOT( 3160716 )
6th Sem CSE D2 211260131052
{
// read the state of the pushbutton buttonState=digitalRead(4);
// check if pushbutton is pressed. if it is, the button state is HIGH
if(buttonState == HIGH){
digitalWrite(11, HIGH);
}
else{
digitalWrite(11, LOW); //// Delay a little bit to improve simulation performance
}
delay(5);
}
AFTER
Conclusion – Arduino turn Led ON and OFF with button In this tutorial we have seen how
to build an Arduino circuit with an LED and a push button, and also how to control this circuit
to turn the LED on and off with the button. Even if it’s a rather simple application, there are
many ways to program it. You can power on the LED only when the button is pressed, or make
the LED blink when you release the button, and so on.
IOT( 3160716 )
6th Sem CSE D2 211260131052
TITLE: To interface Temp and Humidity module with Arduino Uno and note
the result.
Hardware Required:
• Arduino MEGA Board
• Temp and humidity Module Sensor
• DuPont wires (Female to Male)
• USB cable ~ connect to computer
Exercise:
(1) Measure the output with different Environment.
BEFORE
CODE
#include <math.h>
Double Thermister(int Raw ADC)
{ double Temp;
Temp = log(((10240000/Raw ADC) - 10000));
Temp = 1 / (0.001129148 + (0.000234125 + (0.0000000876741 * Temp * Temp ))* Temp );
Temp = Temp - 273.15; // Convert Kelvin to Celsius return Temp;
IOT( 3160716 )
6th Sem CSE D2 211260131052
} 211260131058
void setup()
{
Serial.begin(9600);
}
void loop()
{
Serial.print(Thermister(analogRead(0))); // display Fahrenheit
Serial.println("c");
delay(500);
}
AFTER
OUTPUT
IOT( 3160716 )
6th Sem CSE D2 211260131052
IOT( 3160716 )