Physical Design of Iot: Things/Device
Physical Design of Iot: Things/Device
Physical Design of Iot: Things/Device
Things/Device
for example temperature sensor that is used to analyze the temperature generates the data
from a location and then determined by algorithms.
Connectivity
Devices like USB host and ETHERNET are used for connectivity between the devices and
server.
Processor
A processor like a CPU and other units are used to process the data. these data are further
used to improve the decision quality of an IoT system.
Audio/Video Interfaces
An interface like HDMI and RCA devices is used to record audio and videos in a system.
Input/Output interface
To giving input and output signals to sensors, and actuators we use things like UART, SPI,
CAN, etc.
Storage Interfaces
Things like SD, MMC, SDIO are used to store the data generated from an IoT device.
IoT Protocols
These protocols are used to establish communication between a node device and server
over the internet. it helps to send commands to an IoT device and receive data from
an IoT device over the internet. we use different types of protocols that present on both the
server and client-side and these protocols are managed by network layers like application,
transport, network, and link layer.
HTTP
Hypertext transfer protocol is a protocol that presents in an application layer for transmitting
media documents. it is used to communicate between web browsers and servers. it makes a
request to a server and then waits till it receives a response and in between the request
server does not keep any data between two requests.
WebSocket
This protocol enables two-way communication between a client and a host that can be run
on an untrusted code in a controlled environment. this protocol is commonly used by web
browsers.
MQTT
It is a machine-to-machine connectivity protocol that was designed as a publish/subscribe
messaging transport. and it is used for remote locations where a small code footprint is
required.
Transport Layer
This layer is used to control the flow of data segments and handle the error control. also,
these layer protocols provide end-to-end message transfer capability independent of the
underlying network.
TCP:The transmission control protocol is a protocol that defines how to establish and
maintain a network that can exchange data in a proper manner using the internet protocol.
UDP:a user datagram protocol is a part of internet protocol called the connectionless
protocol. this protocol not required to establish the connection to transfer data.
Network Layer
This layer is used to send datagrams from the source network to the destination network. we
use IPv4 and IPv6 protocols as a host identification that transfers data in packets.
IPv4:This is a protocol address that is a unique and numerical label assigned to each
device connected with the network. an IP address performs two main functions host and
location addressing. IPv4 is an IP address that is 32 bit long.
IPv6:it is a successor of IPv4 that uses 128 bits for an IP address. it is developed by the
IETF task force to deal with the long-anticipated problems.
Link Layer
Link-layer protocols are used to send data over the network's physical layer. it also
determines how the packets are coded and signaled by the devices.
Ethernet
It is a set of technologies and protocols that are used primarily in LANs. it defines the
physical layer and the medium access control for wired ethernet networks.
WiFi
It is a set of LAN protocols and specifies the set of media access control and physical layer
protocols for implementing wireless local area networks.
Cloud Computing
Cloud computing is a trans-formative computing paradigm that involves delivering
applications and services over the Internet Cloud computing involves provisioning of
computing, networking and storage resources on demand and providing these resources as
metered services to the users, in a “pay as you go” model. C loud computing resources can
be provisioned on demand by the users, without requiring interacyions with the cloud service
Provider. The process of provisioning resources is automated. Cloud computing resources
can be accessed over The network using standard access mechanisms that provide platform
independent access through the use of heterogeneous client platforms such as the
workstations, laptops, tablets and smartphones.
Communication protocols
Communication protocols form the backbone of IoT systems and enable network
connectivity and coupling to applications. Communication protocols allow devices to
exchange data over the network. Multiple protocols often describe different aspects of a
single communication. A group of protocols designed to work together are known as a
protocol suite; when implemented in software they are a protocol stack.
Internet communication protocols are published by the Internet Engineering Task Force
(IETF). The IEEE handles wired and wireless networking, and the International Organization
for Standardization (ISO) handles other types. The ITU-T handles telecommunication
protocols and formats for the public switched telephone network (PSTN). As the PSTN and
Internet converge, the standards are also being driven towards convergence.
Embedded Systems
As its name suggests, Embedded means something that is attached to another thing. An
embedded system can be thought of as a computer hardware system having software
embedded in it. An embedded system can be an independent system or it can be a part of a
large system. An embedded system is a controller programmed and controlled by a real-time
operating system (RTOS) with a dedicated function within a larger mechanical or electrical
system, often with real-time computing constraints. It is embedded as part of a complete
device often including hardware and mechanical parts. Embedded systems control many
devices in common use today. Ninety-eight percent of all microprocessors are manufactured
to serve as embedded system component.
An embedded system has three components −
It has hardware.
It has application software.
It has Real Time Operating system (RTOS) that supervises the application software and provide
mechanism to let the processor run a process as per scheduling by following a plan to control the
latencies. RTOS defines the way the system works. It sets the rules during the execution of
application program. A small scale embedded system may not have RTOS.
So these are some IoT Enabling Technologies.
IoT Level-1
• A level-1 IoT system has a single node/device that performs sensing and/or actuation, stores
data, performs analysis and hosts the application • TIt is suitable for modeling low- cost and
low-complexity solutions where the data involved is not big and the analysis requirements are
not computationally intensive.
IoT Level-2
• It has a single node that performs sensing and/or actuation and local analysis (IoT Device
and collected data).
• It is useful for solutions where the data involved is big, however, the primary analysis
requirement is not computationally intensive and can be done locally itself.
IoT Level-3
• It has has a single node. Database and application establish in the cloud.
• It is suitable for solutions where the data involved is big and the analysis requirements are
computationally intensive.
IoT Level-4
• It has multiple nodes that perform local analysis. It has Cloud based application and
database. These IoT System contains local and cloud- based observer nodes which can
subscribe to and receive information collected in the cloud from IoT node devices.
• It is suitable for solutions where we are using multiple nodes, the data involved is big and
the analysis requirements are computationally intensive.
IoT Level-5
• It has multiple end nodes and one coordinator node. The end nodes use for sensing and/or
actuation.
• In this model Coordinator node collects data from the end nodes and transfer to the cloud.
In this model we used Cloud-based Database for store and Analyze data.
• It is suitable for solutions based on wireless sensor networks, in which the data involved is
big and the analysis requirements are computationally intensive.
IoT Level-6
• It has multiple independent end nodes that used for sensing and/or actuation and transfer
data to the cloud. We used Cloud-based database.
• The analytics component analyzes the data and stores the results in the cloud database and
results are visualized with the cloud-based application.
• The centralized controller is aware of the status of all the end nodes and sends control
commands to the nodes
2. Gateway
IoT Gateway manages the bidirectional data traffic between different networks
and protocols. Another function of gateway is to translate different network
protocols and make sure interoperability of the connected devices and sensors.
IoT gateway offers certain level of security for the network and transmitted data
with higher order encryption techniques. It acts as a middle layer between
devices and cloud to protect the system from malicious attacks and
unauthorized access.
3. Cloud
Internet of things creates massive data from devices, applications and users
which has to be managed in an efficient way. IoT cloud offers tools to collect,
process, manage and store huge amount of data in real time. Industries and
services can easily access these data remotely and make critical decisions when
necessary.
Basically, IoT cloud is a sophisticated high performance network of servers
optimized to perform high speed data processing of billions of devices, traffic
management and deliver accurate analytics. Distributed database management
systems are one of the most important components of IoT cloud.
Cloud system integrates billions of devices, sensors, gateways, protocols, data
storage and provides predictive analytics. Companies use these analytics data
for improvement of products and services, preventive measures for certain
steps and build their new business model accurately.
4. Analytics
Analytics is the process of converting analog data from billions of smart devices
and sensors into useful insights which can be interpreted and used for detailed
analysis. Smart analytics solutions are inevitable for IoT system for
management and improvement of the entire system.
One of the major advantages of an efficient IoT system is real time smart
analytics which helps engineers to find out irregularities in the collected data
and act fast to prevent an undesired scenario. Service providers can prepare for
further steps if the information is collected accurately at the right time.
Big enterprises use the massive data collected from IoT devices and utilize the
insights for their future business opportunities. Careful analysis will help
organizations to predict trends in the market and plan ahead for a successful
implementation.
5. User interface
User interfaces are the visible, tangible part of the IoT system which
can be accessible by users. Designers will have to make sure a well designed
user interface for minimum effort for users and encourage more interactions.
Modern technology offers much interactive design to ease complex tasks into
simple touch panels controls. Multicolor touch panels have replaced hard
switches in our household appliances and the trend is increasing for almost
every smart home devices.
6 Describe 10
IoT Functional Block
IoT Communication Models
IoT Communication API’s
These functional blocks consist of devices that provide monitoring control functions,
handle communication between host and server, manage the transfer of data,
secure the system using authentication and other functions, and interface to control
and monitor various terms.
Application
It is an interface that provides a control system that use by users to view the status
and analyze of system.
Management
This functional block provides various functions that are used to manage an IoT
system.
Services
This functional block provides some services like monitoring and controlling a device
and publishing and deleting the data and restore the system.
Communication
This block handles the communication between the client and cloud-based server
and sends/receives the data using protocols.
Security
This block is used to secure an IoT system using some functions like authorization,
data security, authentication, 2 step verification, etc.
Device
These devices are used to provide sensing and monitoring control functions that
collect the data from the outer environment.
This model is a communication model in which a client sends the request for data to
the server and the server responds according to the request. when a server receives
a request it fetches the data, retrieves the resources and prepares the response, and
then sends the data back to the client.
In simple terms, we can say that in the request-response model server send the
response of equivalent on the request of the client. in this model, HTTP works as a
request-response protocol between a client and server.
Example
When we search a query on a browser then the browser submits an HTTP request to
the server and then the server returns a response to the browser(client).
Example
On the website many times we subscribed to their newsletters using our email
address. these email addresses managed by some third-party services and when a
new article published on the website it directly sends to the broker and then the
broker send these new data or post to all the subscribers.
It is a communication model in which the data push by the producers in a queue and
the consumers pull the data from the queues. here also producers are not aware of
the consumers.
Example
When we visit a website we saw a number of posts that published in a queue and
according to our requirements, we click on a post and start reading it.
These APIs like REST and WebSocket are used to communicate between the server
and system in IoT.
Client-server
Here the client is not aware of the storage of data because it is concerned about the
server and similarly the server should not be concerned about the user interface
because it is a concern of the client. and this separation is needed for independent
development and updating of server and client. no matter how the client is using the
response of the server and no matter how the server is using the request of the
client.
Stateless
It means each request from the client to the server must contain all the necessary
information to understand by the server. because if the server can't understand the
request of the client then it can't fetch the request data in a proper manner.
Cacheable
In response, if the cache constraints are given then a client can reuse that response
in a later request. it improves the efficiency and scalability of the system without
loading the extra data.
This type of API allows bi-directional full-duplex communication between server and
client using the exclusive pair communication model. this API uses full-duplex
communication so it does not require a new connection setup every time when it
requests new data. WebSocket API begins with a connection setup between the
server and client and if the WebSocket is supported by the server then it responds
back to the client with the successful response and after setup of a connection
server and client can send data to each other in full-duplex mode.
this type of API reduces the traffic and latency of data and makes sure that each
time when we request new data it cannot terminate the request.
UNIT-2
Write a architecture of Embedded System 8
Typical embedded system mainly has two parts i.e., embedded hardware
and embedded software.
Embedded hardwares are based around microprocessors and
microcontrollers , also include memory, bus, Input/Output, Controller, where
as embedded software includes embedded operating systems, different
applications and device drivers. Basically these two types of architecture
i.e., Havard architecture and Von Neumann architecture are used in
embedded systems.
Architecture of the Embedded System includes Sensor, Analog to Digital
Converter, Memory, Processor, Digital to Analog Converter, and Actuators
etc.
The below figure illustrates the overview of basic architecture of embedded
systems :
The embedded system’s components are basically divided into two parts:
Hardware Components
Software Components
Power Supply
The power supply circuit can be designed with the help some little knowledge of
electronics. For that, we need a bridge rectifier circuit, capacitor as a filter and a
voltage regulator that provides constant output supply.
Processor
A processor is the main brain inside any embedded systems. This is a major factor
that affects the performance of the system. There are different processors available
in the market. An embedded system may use microprocessor or microcontroller.
The processor comes in different architecture like 8-bit, 16-bit and 32-bit. The 8-bit
processor is generally used in a small application where we need some basic
computation like input and output no heavy processing.
Speed
Unit Price
Packaging
Performance
Peripheral Set
Timer on the Chip
Operating Voltage
Number of I/O Pins
Power Consumption
Amount of RAM and ROM
Specialized Processing Units
Architecture 8-bit, 16-bit, or 32-bit
Availability of Supplier for a given core
Easy to upgrade to higher or lower power consumption mode
Availability of Software tools like assembler, debugger, compiler, emulator and technical
support
Memory
Read-Only memory(RAM)
Random Access Memory(ROM)
Electrically Erasable Programmable Read-Only Memory (EEPROM)
RAM memory is volatile memory and used for temporary storage of the data. And
the selection of it depends on the user need and the application.
The ROM memory or Code Memory. This is used for the storage of the program.
Once system powered, the system fetches the code from the ROM memory.
Communication Ports
UART
CAN
SPI
I2C
USB
Ethernet
RS-232
RS-423
RS-485
For example, popular Arduino UNO board has ATmega328 IC and it has following
communication port:
UART
I2C
SPI
For sending data from one board to other we can use these serial protocols. But for
that, we need to program it.
To interact with the embedded systems we need input. The input may be provided
by the user or by some sensor. Sometimes some systems need more input or
output. So the processor selection will be based on I/O.
These input and output are generally divided into ports like P0, P1, P2 and P3 in
8051microcontrollersr. And PA, PB, PC and PD in ATmega series of the
microcontroller.
Some hardware components are common while designing the embedded systems.
But some are different and depends on the application need. Like a temperature
sensor need a temperature sensor for sensing the temperature. While others hand
an alcohol detector has a sensor to detect the alcohol level.
Power Supply
Processor
Display Device
Buzzer for Alert
Software Components
Once the hardware is completed we need to build the software for the embedded
devices. There are different software tools for programming and coding. These
software tools are referred to as software components.
These are the tools that are generally used in embedded system development
Assembler
Emulator
Debugger
Compiler
Assembler
Emulator
An emulator is hardware or software tool that has a similar functionality to the target
system or guest system. It enables the host system to execute the functionality and
other components. It is a replica of the target system. And used for debugging the
code and issues.
Once program or code is fixed at the host system. It is transferred to the target
system.
Debugger
Sometimes we are not getting expected results or output due to errors or bug. There
are certain tools that are specifically used for the debugging process. Where we can
see the controls flow and register value to identify the issue.
Compiler
A compiler is a software tool that converts one programming language into target
code that a machine can understand. The compiler basically used for translating the
high-level language into the low-level language like machine code, assembly
language or object code.
Microprocessor
Microprocessor is the heart of Computer system.
It is only a processor, so memory and I/O components need to be connected
externally
Memory and I/O has to be connected externally, so the circuit becomes large.
You can’t use it in compact systems
Cost of the entire system is high
Due to external components, the total power consumption is high. Therefore,
it is not ideal for the devices running on stored power like batteries.
Most of the microprocessors do not have power saving features.
It is mainly used in personal computers.
Microprocessor has a smaller number of registers, so more operations are
memory-based.
Microprocessors are based on Von Neumann model
It is a central processing unit on a single silicon-based integrated chip.
It has no RAM, ROM, Input-Output units, timers, and other peripherals on the
chip.
It uses an external bus to interface to RAM, ROM, and other peripherals.
Microprocessor-based systems can run at a very high speed because of the
technology involved.
It’s used for general purpose
applications that allow you to handle loads of data.
It’s complex and expensive, with a large number of instructions to process.
Microcontroller
Micro Controller is the heart of an embedded system.
Micro Controller has a processor along with internal memory and I/O components.
Memory and I/O are already present, and the internal circuit is small.
You can use it in compact systems.
Cost of the entire system is low
As external components are low, total power consumption is less. So it can be used with devices running on stored power like b
Most of the microcontrollers offer power-saving mode.
It is used mainly in a washing machine, MP3 players, and embedded systems.
Microcontroller has more register. Hence the programs are easier to write.
Micro controllers arc based on Harvard architecture
It is a byproduct of the development of microprocessors with a CPU along with other peripherals.
It has a CPU along with RAM, ROM, and other peripherals embedded on a single chip.
It uses an internal controlling bus.
Microcontroller based systems run up to 200MHz or more depending on the architecture.
It’s used for application-specific systems.
It’s simple and inexpensive with less number of instructions to process.
8. List and explain major parts/pins on Arduino board? 10M
Arduino in detail
Let’s learn a bit more about what is on the Arduino board. We’ll look first at the left side of the
board with the reset button, USB port, voltage regulator and power port. Remember, there are
different styles of boards, yours may look slightly different. These drawings are based on Arduino
Uno revision 3.
Reset Button: Much like turning your computer off and on again, some problems with the
Arduino can be solved by pushing the reset button. This button will restart the code currently
uploaded on your Arduino. The reset button may be in a different location on your board than in
this diagram, but it is the only button.
USB Port: The USB port takes a standard A-to-B USB cable, often seen on printers or other
computer peripherals. The USB port serves two purposes: First, it is the cable connection to a
computer which allows you to program the board. The USB cord will also provide power for the
Arduino if you’re not using the power port (described below).
Voltage Regulator: The voltage regulator converts power plugged into the power port
(described below) into the 5 volts and 1 amp standard used by the Arduino. BE CAREFUL! This
component gets very hot.
Power Port: The power port includes a barrel-style connector which allows for either power
straight from a wall source (often called a wall-wart) or from a battery. This power is used instead
of the USB cable. The Arduino can take a wide range of voltages (5V – 20V) but will be damaged
if power higher than that is connected.
We’ll take a closer look at the other side of the board now.
Built-in LEDs: The LEDS indicate that there is power, and if your Arduino is sending or receiving
data.
Digital I/O pins: The holes on this side of the board are called the digital input/output pins They
are used to either sense the outside world (input) or control lights, sounds, or motors (output).
TX/RX pins: Pin 0 and Pin 1 are special pins labeled TX and RX. We will cover this in more
detail later, but it is good practice to leave these pins empty. Any changes you make to your
program won’t load if something is plugged into Pin 0.
ATmega328P, black chip: The black chip in the middle of the board is an ATmega328P. This is
the “brains” of the Arduino: it interprets both the inputs / outputs and the programming code
uploaded onto your Arduino. The other components on the board allow you to communicate with
this chip when creating projects.
Power and ground pins: All of the pins related to power are located here. You can use these
pins to run power from your Arduino to your breadboard circuit.
Analog pins: These pins take sensor readings in a range of values (analog), rather than just
sending whether something is just on or off (digital)
Pins: