Module-6 Create Your Own IoT
Module-6 Create Your Own IoT
Arduino Nano
Arduino
Arduino LilyPad
Mega
Arduino Uno
Arduino Mini Arduino Leonardo
ARDUINO UNO
Digital pins:
🞆 14 digital IO pins
🞆 6 are PWM pins (3, 5, 6, 9,
10, and 11).
Analog pins:
🞆 6 analog pins(A0, A1, A2,
A3, A4, and A5)
🞆 Takes analog values as an
input
ARDUINO UNO
ARDUINO IDE
● Arduino IDE is an open source
software that is used to program the
Arduino controller board
● Based on variations of the C and C+
+ programming language
● It can be downloaded from Arduino’s
official website and installed into PC
ARDUINO IDE
VERIFY SERIAL
MONITOR
UPLOAD
NEW
TAB
OPEN CODE
SAVE GOES
HERE BOARD &
SERIAL
PORT
SELECTI
ONS
BASIC CODING
STRUCTURE
SET UP
🞆 Power the board by connecting it to a PC via
USB cable
▪ digitalWrite()
• Write a HIGH or a LOW value to a digital
pin.
• Eg: digitalWrite (11, HIGH);
• ie. setting pin 11 to high.
BASIC CODING STRUCTURE
▪ digitalRead()
• Reads the value from a specified digital
pin, either HIGH or LOW
• Eg: int inPin=7;
val = digitalRead(inPin);
• ie. reads the value from inPin and assigns
it to val.
▪ delay()
• Pauses the program for the amount of time
(in milliseconds) specified as parameter.
• Eg: delay(1000);
• ie. waits for a second (1000 ms = 1 s)
EXAMPLE:BLINKING LED
Requirement:
Arduino controller board, USB connector, Bread
board, LED, 1.4Kohm resistor, connecting
wires, Arduino IDE
1.Connect the LED to the Arduino using the
Bread board and the connecting wires
2.Connect the Arduino board to the PC using
the USB connector
3.Select the board type and port
4.Write the sketch in the editor, verify and
upload.
5.Connect the positive terminal of the LED to
digital pin 12 and the negative terminal to
the ground pin (GND) of Arduino Board
EXAMPLE:BLINKING LED
EXAMPLE:BLINKING LED
EXAMPLE:BLINKING LED
Component List
⮚ Arduino Uno
⮚ USB cable
⮚ LED, RGB LED
⮚ LDR
⮚ POT(10k)
⮚ Resistors
⮚ Temp sensor LM-35
⮚ Motor Driver L293D, DC Motor
⮚ Connecting wire
ARDUINO
WHAT CAN IT DO?
•Low Power
requirements
•Flexible / Open-source
“HOW MUCH MORE
ARDUINO CAN DO IS
ONLY LEFT TO YOUR
IMAGINATION”
34
WHAT IS
RASPBERRY PI?
• The Raspberry Pi is a series of small single-
board computers developed in the United
Kingdom by the Raspberry Pi Foundation to
promote the teaching of basic computer
science in schools and in developing
countries.
• The original model became far more
popular than anticipated, selling outside of
its target market for uses such as robotics.
THE TIMELINE
• The first generation (Raspberry Pi 1 Model B)
was released in February 2012. It was followed
by a simpler and inexpensive model Model A.
• In 2014, the foundation released a board with
an improved design in Raspberry Pi 1 Model B+.
These boards are approximately credit-card sized
and represent the standard mainline form-factor.
• Improved A+ and B+ models were released a
year later. A "compute module" was released in
April 2014 for embedded applications, and a
Raspberry Pi Zero with smaller size and reduced
input/output (I/O) and general-purpose
input/output (GPIO) capabilities was released in
November 2015 for US$5.
THE TIMELINE
•The Raspberry Pi 2 which added more RAM
was released in February 2015.
• Raspberry Pi 3 Model B released in
February 2016, is bundled with on-board WiFi,
Bluetooth and USB boot capabilities.
• As of January 2017, Raspberry Pi 3 Model B
is the newest mainline Raspberry Pi.
• Raspberry Pi boards are priced between
US$5–35.
• As of 28 February 2017, the Raspberry Pi
Zero W was launched, which is identical to
the Raspberry Pi Zero, but has the Wi-Fi and
Bluetooth functionality of the Raspberry Pi 3
for US$10.
RASPBERRY PI 3
MODEL B
RASPBERRY PI 2
MODEL B STATS
OPERATING SYSTEM
• The Foundation provides Raspbian, a
Debian based Linux distribution for
download, as well as third party Ubuntu,
Windows 10 IOT Core, RISC OS, and
specialised media center distributions.
• It promotes Python and Scratch as the
main programming language, with
support for many other languages.
• The default firmware is closed source,
while an unofficial open source is
available.
LINUX BASED OPERATING SYSTEMS
• Android Things
• Arch Linux
• OpenSuse
• Raspberry Pi Fedora Remix
• Pidora
• Gentoo Linux
• CentOS Raspberry Pi
• Kali Linux
• Slackware ARM
• Puppy Linux
SUMMARY
What is BeagleBone Black?