Iot With Raspberry Pi
Iot With Raspberry Pi
Architecture of Raspberry Pi
• Raspberry Pi is a small single-board computer (SBC). It
is a credit card-sized computer that can be plugged into
a monitor. It acts as a minicomputer by connecting the
keyboard, mouse, and display. Raspberry Pi has an ARM
processor and 512MB of RAM
• The following diagram shows some main blocks of
Raspberry Pi:
Raspberry Pi mainly consists of
the following blocks:
Processor: Raspberry Pi uses Broadcom BCM2835 system on chip which is an ARM
processor and Video core Graphics Processing Unit (GPU). It is the heart of the
Raspberry Pi which controls the operations of all the connected devices and handles
all the required computations.
HDMI: High Definition Multimedia Interface is used for transmitting video or digital
audio data to a computer monitor or to digital TV. This HDMI port helps Raspberry Pi
to connect its signals to any digital device such as a monitor digital TV or display
through an HDMI cable.
GPIO ports: General Purpose Input Output ports are available on Raspberry Pi which
allows the user to interface various I/P devices.
Audio output: An audio connector is available for connecting audio output devices
such as headphones and speakers.
• USB ports: This is a common port available for various peripherals such as a
mouse, keyboard, or any other I/P device. With the help of a USB port, the system
can be expanded by connecting more peripherals.
SD card: The SD card slot is available on Raspberry Pi. An SD card with
an operating system installed is required for booting the device.
Ethernet: The ethernet connector allows access to the wired network,
it is available only on the model B of Raspberry Pi.
Power supply: A micro USB power connector is available onto which a
5V power supply can be connected.
Camera module: Camera Serial Interface (CSI) connects the Broadcom
processor to the Pi camera.
• Display: Display Serial Interface (DSI) is used for connecting LCD to
Raspberry Pi using 15 15-pin ribbon cables. DSI provides a high-
resolution display interface that is specifically used for sending video
data.
The Internet of Things (IoT) is the network or interfacing of physical objects to
controlling devices, now a day’s smart vehicles,
software, sensors, and embedded electronics uses network connectivity which
enables these objects to collect and exchange data.
The IOT allows objects to be sensed and controlled remotely across existing
network infrastructure, creating opportunities for more direct integration of the
physical world into computer-based systems, and resulting in improved
efficiency, accuracy and economic benefit; when IOT is augmented with sensors
and actuators, the technology becomes an instance of the more general class of
cyberphysical systems, which also encompasses technologies such as smart
grids, smart homes, intelligent transportation and smart cities. Each thing is
uniquely identifiable through its embedded computing system but is able to
interoperate within the existing
Internet infrastructure. Experts estimate that the IoT will consist of almost 50
billion objects by 2020.
Coastal waters, automobiles with built-in sensors, DNA analysis devices for
environmental/food/pathogen monitoring or field operation devices that assist
firefighters in search and rescue operations. Legal scholars suggest to look at “Things”
as an “inextricable mixture of hardware,
software, data and service”. These devices collect useful data with the help of various
existing technologies and then autonomously
flow the data between other devices. Current market examples include smart
thermostat systems and washer/dryers that use Wi-Fi for remote monitoring.
However, the application of the IoT is not only restricted to these areas. Other
specialized use cases of the IoT may also exist.
An overview of some of the most prominent application areas is provided here. Based
on the application domain, IoT products can be classified broadly into five different
categories: smart wearable, smart home, smart city, smart environment, and smart
enterprise. The IOT products and solutions in each of these markets have different
characteristics
II. BASIC IMPLEMENTATION OF
IOT USING RASPBERRY PI
BASIC IMPLEMENTATION OF IOT USING RASPBERRY PI
The basic implementation of IOT includes usage of a host device, a Remote Controllable Device and connectivity
between
them. In this paper, the host device can be a computer or a mobile phone and the remote controllable device is a
Raspberry Pi,
• which executes the commands given by the master host. The implementation mechanism can be understood by
the following figure
HARDWARE IMPLEMENTATION
The system that implements the Internet of Things includes clusters of hardware components that we are
familiar with. Firstly,
we need a host like a Personal Computer or a mobile phone that can be used to pass commands to a remotely
operable device. As
the brain of the system we are using a Raspberry Pi that can be used to control and obtain a desired result
from a device. The
“things” that we use here are basically day-to-day objects like a bulb, a fan, a washing machine etc., Our
intention is to show the
operation of the Internet of Things in a concise way.
As the Raspberry Pi is more like a compact computer itself, it cannot control “things” directly. It needs an
interface to communicate the with them. Fortunately, Raspberry Pi comes with a 40-pin GPIO set that could
efficiently be utilized to
communicate with the “things”. As we need an interface between them, a “Daughter Board” is to be designed.
This Daughter Board will enable us to dim and glow a light source. Switch ON/OFF electrical devices and
receive feedback
from sensors.
SOFTWARE IMPLEMENTATION:
• SOFTWARE IMPLEMENTATION:
•
• Hardware without proper software is nothing but a piece a brick.
When it comes to Raspberry Pi, an OS must be installed to
• control and configure it. And in the case of the Daughter Board,
python scripts are to be coded to work with the “things”. We have,
• a communications platform for IOT devices that enables device
setup and user interaction from mobile devices and the web, can
be
used to accomplish communication between Host device and the
Raspberry Pi.
Implementation of iot with the
Raspberry Pi
• Components Required
• Raspberry Pi (any model, e.g., Raspberry Pi 4,
Raspberry Pi Zero)
• MicroSD Card (at least 16GB with Raspberry Pi OS)
• Power Supply (5V, 3A recommended)
• Sensors & Actuators (DHT11/DHT22 for temperature, HC-
SR04 for distance, etc.)
• Network Connectivity (Wi-Fi or Ethernet)
• Cloud Services (AWS IoT, Google Firebase, MQTT broker, etc.)
• Programming Language: Python (preferred), C, or Node.js
• Setting Up Raspberry Pi
• Step 1: Install Raspberry Pi OS
• Download Raspberry Pi Imager from Raspberry Pi’s
website
• Flash Raspberry Pi OS (Lite/Desktop) onto a
microSD card.
• Insert the microSD card into Raspberry Pi and boot it.
sudo apt update && sudo apt upgrade -y
• Step 3: Enable GPIO and I2C (If Required)
• Open Raspberry Pi configuration: bash
• CopyEdit
sudo raspi-config