Вы находитесь на странице: 1из 38

Designing IoT Systems

Design Expectations
• Fulfil all operational requirements
• Simplicity
• Usability and Flexibility
• Secure
• Easy upgrade
Design Thinking
• Empathise
• Define (the problem)
• Ideate
• Prototype
• Test
IoT Design Methodology
Purpose & Requirements
Define Purpose & Requirements of IoT system

Process Model Specification


Define the processes / use cases

Domain Model Specification


Define Physical Entities, Virtual Entities, Devices, Resources and Services in the IoT System

Information Model Specification


Define the structure (e.g. relations, attributes) of all the information in the IoT system
Service Specifications
Map process and information Model to services and define service specification
IoT Level Specification
Define the IoT Level for the system
Functional View Specification
Map IoT Level to functional groups
Operational View Specification
Define communication options, service hosting options, storage options, device options

Device & Component Integration


Integrate devices, develop and integrate the components
Application Development
Develop Applications
Purpose and Requirements
Specification
Problem Definition
• Purpose and Requirement Specification
• Purpose : Home light automation system that allows controlling of
lights in home remotely using web app
• Behaviour : have Auto and Manual modes
• Auto mode : System measures lights level – switch on light if it is below a level
or stitch off light if it is above level
• Manual mode : Option of manually and remotely switching on / off the light
• System Management Requirement : System should provide remote
monitoring and control functions
Continued..
• Data Analysis requirement : Local analysis of data
• Application Development requirement : Application should be
deployed locally on device , should be accessed remotely
• Security Requirement : Basic authentication capability
Process Diagram : Notation
c Start of the process

Decision Box

State
Process Diagram

Mode

Auto Manual

Light-level Light-state

Level:Low Level:High state:On state:Off

state:On state:Off state:On state:Off


Domain Model
• Conceptual Model of System
• Describes the various entities ( Physical / Virtual) and other concepts
/ components (like Services, Resources etc.)
• Relationships between Entities and components
Physical Entity
• Real, discrete and Identifiable object.
• Information about Physical Entity can be provided (through sensors)
• Some actions can be performed on Physical Entity (through actuators)
• In this example
• Room
• Light Appliance (to be controlled)
Virtual Entity
• Representation of Physical entity in Digital Domain
• For each Physical entity will have virtual entity
• In the given example virtual entities are
• Room (that is being monitored for temperature)
• Light Appliance ( to be controlled)
Devices
• Used to gather information about Physical Entities (Sensors)
• Perform action / actuation upon Physical entities (Actuators)
• Used to identify Physical Entities (using tags)
• Medium for Interaction between Physical Entities and Virtual Entities
• In the given example
• A single board is mini computer is device having Light Sensors
Actuator (relay switch ) attached to it
Resource
• Software components
• On Device – Hosted on device (OS loaded on Mini Computer)
• Provide information
• Enable Actuation
• Network resources – Like Databases
• Stores / Inform the state of entities
Service
• Implementation of Process (action)
• Provides interface for interacting with Physical Entity
• Service access the resources hosted on the devices
• Access Network resources to obtain
• information about Physical Entity
• Perform actuation upon the Physical Entity
• In the given model
• Service 1 : Sets mode to auto or manual / retrieves current mode
• Service 2 : Sets the light appliance state to on-off / retrieves the current
light state
Continued…
• Service 3 : A controller service that runs as a native service on device.
• Auto mode : controller service monitors light level switches light on-off and
update the status in Database
• Manual Mode : Controller service retrieves the current state from the
database and switches light on/off.
• Services are derived through process specification and information
model
User
Interacts with
Domain Model

Active Digital
Human User
Artefact
App
Invokes/subscribes

Virtual Entry relates to Physical Entity monitors

Room Room
Service associated with

associated with
Virtual Entry relates to Physical Entity
exposes Appliance Appliance
acts on
Resource associated with

hosts Device
Minicomputer
attached to attached to Type
Network OnDevice
Resource Resource Object
Sensor Actuator
LDR Relay Type: Entity, service, resource
One way Association
Object : device, attribute
Generalization/Specification
Aggregation Relationship
Information Model
• Defines the structure of all the information in IoT system
• Attributes of virtual entities
• Relation etc.
• Does not describes how information is represented or stored
• Adds more details to the Virtual Entities by defining their attributes
and relations
• In the given example …………….
Information Model

Virtual Entity Virtual Entity:


:Room LightAppliance

EntityType:Room EntityType:Appliance
EntityType:Room
ID:Room1 ID:Light1
ID:Room1
RoomID:Room1

Attribute:
Light-level Attribute:state

AttributeName: lightlevel AttributeName:lightState


AttributeName: lightstate
AttributeType: level AttributeType:state
AttributeType: state

has light-level has light-level Is in state Is in state

Level:high Level:Low State:ON State:OFF


Service Specifications
• It defines the services in IoT system
• Service types
• Service inputs / outputs
• Service endpoints
• Service schedules
• Service preconditions and service effects
Process Specification
Mode Service: Sets mode to auto
Mode manual or retrieves the current mode
auto manual

Light-level Light-State

state:On state:Off State on state:Off


Information Model State Service: Sets the light
appliance state to on/off or retrieves
Virtual Entity Virtual Entity: the current light state
:Room LightAppliance
EntityType:Room EntityType:Appliance
In room ID:Light1
ID:Room1
RoomID:Room1

Attribute:
Attribute:state
Light-level
AttributeName: lightlevel AttributeName:lightState
AttributeType: level AttributeType:state

has light-level has light-level Is in state Is in state

Level:HIGH Level:Low State:ON State:OFF


Controller Service: In auto mode, the controller service monitors the light level and switches the light
on/off and updates the status in the status databases. In manual mode, the controller service retrieves
the current state from the databases and switches the light on/off
Input Schedule

has schedule
Mode: Auto/Manual Interval:
has input
State: On/Off Every 5 sec

Service

Name: Controller
Type: Native

has output

Output

State: On/Off
Output

Current Mode:
has output
Auto/Manual

Service

Name: Mode
Type: Rest

has input
has service Endpoint

Input
Endpoint

Set Mode: Endpoint:/home/mode/


Auto/Manual Protocol:HTTP
Output

State: On/Off has output

Service

Name: State
Type: Rest

has input
has service Endpoint

Input
Endpoint

State:On/Off Endpoint:/home/State/
Protocol:HTTP
Deployment Design of home automation IoT System Local Cloud

App

REST
services

Database

Controller Service

Resources

Device

Monitoring Node
performs analysis, stores data
IoT Level Specification
• Which level of design
• The given example is Level -1
Functional View
• Defines various functional groups of IoT System
• Device Group : All the devices - Single board mini computer, light
sensor, relay switch
• Communication Group : Handles all the communications of IoT
System like
• REST API (with HTTP) for exchange of data over network ( at application layer)
• TCP at transport layer
• IPV4 (at network layer)
• 802.11 at Link layer
Application Layer
HTTP CoAP WebSockets

MQTT XMPP DDS AMQP

Transport Layer

TCP UDP

Network Layer

IPV4 IPV6 6LoQPAN

Link Layer
802.3-Ethernet 802.16-WiMax 2G/3G/LTE-
Cellular
802.11-WiFi 802.15.4-LR-WPAN
Function Groups Continued..
• Services Group :
• Two REST services (Mode and State service)
• One native service (Controller service)
• Management : In the given example Database maps to this FG
• Security : All security protocols and procedures
What next ?

• Operational View, Device and component integration, Application


Development
• Identify the specific hardwares
• Softwares
• Specific technical details
Weather Monitoring
Problem Statement
• Collect data from environment for
• Temperature
• Pressure
• Humidity
• Light
• Sensors reads in fix intervals and data is stored
• Data will be send to cloud for aggregation and analysis
• (Read and used by some human user at cloud)
Process Diagram

Read Sensor

Store Value

Wait
User

Active Digital
Human User
Artefact
App
Invokes/subscribes

Virtual Entry relates to Physical Entity monitors

Environment Environment
Service associated with

exposes

Resource associated with

hosts
Device
Minicomputer
attached to attached to
Network OnDevice
Resource Resource Sensor Sensor Sensor
Sensor
Temperature Pressure Humidity
Light Sensor
One way Association Sensor sensor Sensor
Generalization/Specification
Aggregation Relationship
Virtual Entity:
Environment
EntityType:
Environment

Attribute: Attribute: Attribute: Attribute:


State State State State
AttributeName : AttributeName : AttributeName : AttributeName :
temperature pressure humidity light

has value has value has value has value

Temperature: val Pressure: val Humidity: val Light: val


Process Specification

Read Sensor

Store Value

Wait
Information Model
Virtual Entity:
Environment
EntityType:
Environment

Attribute: Attribute: Attribute: Attribute:


State State State State
AttributeName : AttributeName : AttributeName : AttributeName :
temperature pressure humidity light

has value has value has value has value

Temperature: val Pressure: val Humidity: val Light: val

Controller Service: Runs as a native service on the device. Gets the current temperature,
pressure, humidity and light readings and sends to the cloud database.
Service

Name: Controller
Type: Native

has output has schedule

Output Schedule

Temperature Interval
Pressure Every 15 sec
Humidity
Light
Local Cloud

Observer
Node App Observer
REST Node
Communication

Controller Controller Centralized Analytics


REST
Service Service controller Component
Services
(IoT Intelligence)

Resource Resource

Database
Device Device

Multiple Monitoring Nodes

Centralized Cloud Storage &


Controller Analysis

Вам также может понравиться