SlideShare ist ein Scribd-Unternehmen logo
1 von 10
SmartHome and
SmartFactory
Intelligent Systems
With .NET Micro Framework, Azure and MQTT

Lorenzo Maiorfi
Mirco Vanini
 Cloud Hosting Environment (Azure VMs)

 MQTT Network
 MQTT Broker by HiveMQ (www.hivemq.com)

 .NET MF embedded devices running as MQTT Network “nodes”

Our Reference
Application
Modules

 sensors/actuators working as publishers/subscribers of
data/commands
 MQTT-2-Z-Wave embedded bridge
 MQTT-2-ZigBee embedded bridge
 MQTT-2-ISM (2.4GHz Radio) embedded bridge
 MQTT industrial controller (ABB PLC)

 Node-red “engine”, acting as
 designer and runtime host for “flows”
 interface/protocol/API adapter among service endpoints
 simple business-logic modules hosting platform
 Application protocol over TCP layer
 Based on pub/sub messaging model

MQTT is the
de-facto
standard for
M2M / IoT
Applications

 Messages are made of two simple parts:
 Topic, a string typically expressed in hierarchical form
“/part1/part2/part3/…”
 Payload, an arbitrary content expressed as a byte-array

 3 QoS levels for message publishing
 QoS Zero (best effort)
 QoS One (broker confirms to publisher that message has been
delivered, but cannot confirm that same message wasn’t delivered
more than once)
 QoS Two (broker confirms to publisher that message has been
delivered, and just once)

 MQTT provides for both “retained” and “last will” messages
 Blazingly Fast
 Enterprise-grade security

HiveMQ
Broker
by DC2

 Clustering
 Portability
 Support
 100% MQTT compliant
 Websockets
 Scalability
 Modular
 Administration made easy
 Despite its powerful network model, real world scenarios often
require to extend such network to other communication systems
 A common requirement is radio coverage:

MQTT
Bridging

 ZigBee mesh networks for industrial environments
 Z-Wave mesh networks for smart home systems
 ISM (2.4 GHz) technology for cheap and fast data exchange

 Bridging MQTT with these technologies allows for:
 building hybrid networks whose nodes share same messaging model
 joining different MQTT networks with radio links
 greater overall reliability (by redundancy)
 “Mesh” networking model means that any node can extend
overall coverage to adjacent nodes, acting as a router
 Digi XBee modules are by far the most common chips used
worldwide

ZigBee
Networks

 Coverage is about 50-100m (1mW) for standard modules and up to
1.6km (50mW) for “Pro” modules
 They’re great to implement remote IO management (digital
inputs/outputs and analog inputs)…
 …but together with a host microcontroller board they’re great to
implement arbitrary message exchange too
 They can be configured and updated remotely
 Serial API exposed to host applications is simple but powerful
 We have extended XBee API client libraries originally coded by
Micheal Schwartz (mfsmarttoolkit.codeplex.com) in order to get
greater reliability and performance
 Licensed by Sigma Designs (formerly ZenSys), Z-Wave is
becoming the “de facto” standard for Smart Home systems
 Z-Wave is based on mesh network model (like ZigBee), but radio
modules typically require much less power to work than XBee (a
battery operated device can work for years)

Z-Wave
Networks

 There are plenty of Z-Wave enabled devices (power outlets, power
meters, sensors, thermostats, blinds motors drivers, switches, etc)
 We developed a managed Z-Wave Serial API Controller stack
targeted to .NET Micro Framework devices
 Our client lib provides support for most commons profiles (basic,
meter, multilevelsensor, multilevelswitch, wakeup, etc)
 Client API is async-only
 Works with any Z-Wave Serial API Controller device, connected
through a UART port to host application microcontroller
 Despite its great flexibility, a network infrastructure itself cannot
address real-world scenarios
 We need a way to design and run business logic flows
orchestrating message exchange among network nodes

Business Logic
Flows

 Node-red is an open project whose main purpose is that to act as
an engine that runs/hosts “flows” designed by mean of node-red
itself
 Despite being general, it fits in a natural way with MQTT
 Node components can be written in JavaScript
 It uses a visual design language using a SPA web IDE (hosted by
node-red itself)
 Many node components are built-in
 Despite it can also implement business logic of medium complexity,
node-red killer-application is no doubt “interface/API” adaptation
among “actors” in heterogeneous systems (in our reference
application we provide an example of both cases)
 Windows 8 Store App
 consumes a custom tcp socket “tunneling” in order to get and
publish MQTT messages even with no MQTT client lib support

Sample Client
Apps

 Windows Embedded Compact 2013 App
 uses µM2MQTT Library by Paolo Patierno in order to directly
interact with MQTT broker

 Windows Phone 8, iPhone Apps
 use a plain HTTP REST/JSON API
 kind of “longpolling” technique implemented by a node-red flow
changes messaging model from pub/sub to request/reply
 Mirco Vanini: Windows Store App
 Paolo Patierno: uM2MQTT Library & WEC 2013 Demo App
 Fabrizio Bernabei, Tiziano Cacioppolini: WP8 Demo App

Credits

 Daniele Galiotto: iPhone App
 Lorenzo Maiorfi: firmware, web broker spa web app, node-red
flows

Weitere ähnliche Inhalte

Was ist angesagt?

Smart Home Live: Intelligent Detection of Fire or a Break-In with MQTT and Op...
Smart Home Live: Intelligent Detection of Fire or a Break-In with MQTT and Op...Smart Home Live: Intelligent Detection of Fire or a Break-In with MQTT and Op...
Smart Home Live: Intelligent Detection of Fire or a Break-In with MQTT and Op...
Christian Götz
 

Was ist angesagt? (16)

A Short Report on MQTT protocol for Internet of Things(IoT)
A Short Report on MQTT protocol for Internet of Things(IoT)A Short Report on MQTT protocol for Internet of Things(IoT)
A Short Report on MQTT protocol for Internet of Things(IoT)
 
Getting started with MQTT - Virtual IoT Meetup presentation
Getting started with MQTT - Virtual IoT Meetup presentationGetting started with MQTT - Virtual IoT Meetup presentation
Getting started with MQTT - Virtual IoT Meetup presentation
 
Best Practices Using MQTT to Connect Millions of IoT Devices
Best Practices Using MQTT  to Connect Millions of IoT DevicesBest Practices Using MQTT  to Connect Millions of IoT Devices
Best Practices Using MQTT to Connect Millions of IoT Devices
 
M2M Protocols for Constrained Environments in the Context of IoT: A Compariso...
M2M Protocols for Constrained Environments in the Context of IoT: A Compariso...M2M Protocols for Constrained Environments in the Context of IoT: A Compariso...
M2M Protocols for Constrained Environments in the Context of IoT: A Compariso...
 
Distributed messaging with Apache Kafka
Distributed messaging with Apache KafkaDistributed messaging with Apache Kafka
Distributed messaging with Apache Kafka
 
MQTT Protocol: IOT Technology
MQTT Protocol: IOT TechnologyMQTT Protocol: IOT Technology
MQTT Protocol: IOT Technology
 
MQTT - Protocol for the Internet of Things
MQTT - Protocol for the Internet of ThingsMQTT - Protocol for the Internet of Things
MQTT - Protocol for the Internet of Things
 
Mqtt 5 meetup dortmund
Mqtt 5 meetup dortmundMqtt 5 meetup dortmund
Mqtt 5 meetup dortmund
 
Smart Home Live: Intelligent Detection of Fire or a Break-In with MQTT and Op...
Smart Home Live: Intelligent Detection of Fire or a Break-In with MQTT and Op...Smart Home Live: Intelligent Detection of Fire or a Break-In with MQTT and Op...
Smart Home Live: Intelligent Detection of Fire or a Break-In with MQTT and Op...
 
Connecting Internet of Things to the Cloud with MQTT
Connecting Internet of Things to the Cloud with MQTTConnecting Internet of Things to the Cloud with MQTT
Connecting Internet of Things to the Cloud with MQTT
 
Messaging for the Internet of Awesome Things
Messaging for the Internet of Awesome ThingsMessaging for the Internet of Awesome Things
Messaging for the Internet of Awesome Things
 
EMQ Company Deck
EMQ Company DeckEMQ Company Deck
EMQ Company Deck
 
[http://1PU.SH] Building Wireless Sensor Networks with MQTT-SN, RaspberryPi a...
[http://1PU.SH] Building Wireless Sensor Networks with MQTT-SN, RaspberryPi a...[http://1PU.SH] Building Wireless Sensor Networks with MQTT-SN, RaspberryPi a...
[http://1PU.SH] Building Wireless Sensor Networks with MQTT-SN, RaspberryPi a...
 
In search of the perfect IoT Stack - Scalable IoT Architectures with MQTT
In search of the perfect IoT Stack - Scalable IoT Architectures with MQTTIn search of the perfect IoT Stack - Scalable IoT Architectures with MQTT
In search of the perfect IoT Stack - Scalable IoT Architectures with MQTT
 
HiveMQ Webinar: Lightweight and scalable IoT Messaging with MQTT
HiveMQ Webinar: Lightweight and scalable IoT Messaging with MQTTHiveMQ Webinar: Lightweight and scalable IoT Messaging with MQTT
HiveMQ Webinar: Lightweight and scalable IoT Messaging with MQTT
 
Developing Realtime Data Pipelines With Apache Kafka
Developing Realtime Data Pipelines With Apache KafkaDeveloping Realtime Data Pipelines With Apache Kafka
Developing Realtime Data Pipelines With Apache Kafka
 

Ähnlich wie Smart home and smartfactory intelligent systems

Collaboration and Grid Technologies
Collaboration and Grid TechnologiesCollaboration and Grid Technologies
Collaboration and Grid Technologies
Videoguy
 
Using Eclipse and Lua for the Internet of Things with Eclipse Koneki, Mihini ...
Using Eclipse and Lua for the Internet of Things with Eclipse Koneki, Mihini ...Using Eclipse and Lua for the Internet of Things with Eclipse Koneki, Mihini ...
Using Eclipse and Lua for the Internet of Things with Eclipse Koneki, Mihini ...
Benjamin Cabé
 

Ähnlich wie Smart home and smartfactory intelligent systems (20)

LANSim
LANSimLANSim
LANSim
 
Industry 4.0: Building the Unified Namespace with Confluent, HiveMQ and Spark...
Industry 4.0: Building the Unified Namespace with Confluent, HiveMQ and Spark...Industry 4.0: Building the Unified Namespace with Confluent, HiveMQ and Spark...
Industry 4.0: Building the Unified Namespace with Confluent, HiveMQ and Spark...
 
Wireless notice board using zigbee
Wireless notice board using zigbeeWireless notice board using zigbee
Wireless notice board using zigbee
 
node.js is made for IoT - node.hh 07/16, Hamburg by Michael Kuehne
node.js is made for IoT - node.hh 07/16, Hamburg by Michael Kuehnenode.js is made for IoT - node.hh 07/16, Hamburg by Michael Kuehne
node.js is made for IoT - node.hh 07/16, Hamburg by Michael Kuehne
 
Everything about Internet of Things
Everything about Internet of ThingsEverything about Internet of Things
Everything about Internet of Things
 
Introduction MQTT in English
Introduction MQTT in EnglishIntroduction MQTT in English
Introduction MQTT in English
 
Designing Internet of things
Designing Internet of thingsDesigning Internet of things
Designing Internet of things
 
IOT Network architecture and Design.pptx
IOT Network architecture and Design.pptxIOT Network architecture and Design.pptx
IOT Network architecture and Design.pptx
 
Cloud Computing
Cloud ComputingCloud Computing
Cloud Computing
 
Realtime mobile&iot solutions using mqtt and message sight
Realtime mobile&iot solutions using mqtt and message sightRealtime mobile&iot solutions using mqtt and message sight
Realtime mobile&iot solutions using mqtt and message sight
 
Collaboration and Grid Technologies
Collaboration and Grid TechnologiesCollaboration and Grid Technologies
Collaboration and Grid Technologies
 
Kafka Summit 2021 - Why MQTT and Kafka are a match made in heaven
Kafka Summit 2021 - Why MQTT and Kafka are a match made in heavenKafka Summit 2021 - Why MQTT and Kafka are a match made in heaven
Kafka Summit 2021 - Why MQTT and Kafka are a match made in heaven
 
2016-09-eclipse-iot-cf-summit
2016-09-eclipse-iot-cf-summit2016-09-eclipse-iot-cf-summit
2016-09-eclipse-iot-cf-summit
 
IoT Data Streaming - Why MQTT and Kafka are a match made in heaven | Dominik ...
IoT Data Streaming - Why MQTT and Kafka are a match made in heaven | Dominik ...IoT Data Streaming - Why MQTT and Kafka are a match made in heaven | Dominik ...
IoT Data Streaming - Why MQTT and Kafka are a match made in heaven | Dominik ...
 
InduSoft Web Studio and MQTT for Internet of Things Applications
InduSoft Web Studio and MQTT for Internet of Things ApplicationsInduSoft Web Studio and MQTT for Internet of Things Applications
InduSoft Web Studio and MQTT for Internet of Things Applications
 
Internet of things unit-1
Internet of things unit-1Internet of things unit-1
Internet of things unit-1
 
Using Eclipse and Lua for the Internet of Things with Eclipse Koneki, Mihini ...
Using Eclipse and Lua for the Internet of Things with Eclipse Koneki, Mihini ...Using Eclipse and Lua for the Internet of Things with Eclipse Koneki, Mihini ...
Using Eclipse and Lua for the Internet of Things with Eclipse Koneki, Mihini ...
 
Unit 4
Unit 4Unit 4
Unit 4
 
Chapter-2.pdf
Chapter-2.pdfChapter-2.pdf
Chapter-2.pdf
 
DEVELOPMENT AND IMPLEMENTATION OF LOW COST IIOT GATEWAY WITH EDGE COMPUTING F...
DEVELOPMENT AND IMPLEMENTATION OF LOW COST IIOT GATEWAY WITH EDGE COMPUTING F...DEVELOPMENT AND IMPLEMENTATION OF LOW COST IIOT GATEWAY WITH EDGE COMPUTING F...
DEVELOPMENT AND IMPLEMENTATION OF LOW COST IIOT GATEWAY WITH EDGE COMPUTING F...
 

Kürzlich hochgeladen

Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
Joaquim Jorge
 

Kürzlich hochgeladen (20)

Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024
 
Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation Strategies
 
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 

Smart home and smartfactory intelligent systems

  • 1. SmartHome and SmartFactory Intelligent Systems With .NET Micro Framework, Azure and MQTT Lorenzo Maiorfi Mirco Vanini
  • 2.  Cloud Hosting Environment (Azure VMs)  MQTT Network  MQTT Broker by HiveMQ (www.hivemq.com)  .NET MF embedded devices running as MQTT Network “nodes” Our Reference Application Modules  sensors/actuators working as publishers/subscribers of data/commands  MQTT-2-Z-Wave embedded bridge  MQTT-2-ZigBee embedded bridge  MQTT-2-ISM (2.4GHz Radio) embedded bridge  MQTT industrial controller (ABB PLC)  Node-red “engine”, acting as  designer and runtime host for “flows”  interface/protocol/API adapter among service endpoints  simple business-logic modules hosting platform
  • 3.  Application protocol over TCP layer  Based on pub/sub messaging model MQTT is the de-facto standard for M2M / IoT Applications  Messages are made of two simple parts:  Topic, a string typically expressed in hierarchical form “/part1/part2/part3/…”  Payload, an arbitrary content expressed as a byte-array  3 QoS levels for message publishing  QoS Zero (best effort)  QoS One (broker confirms to publisher that message has been delivered, but cannot confirm that same message wasn’t delivered more than once)  QoS Two (broker confirms to publisher that message has been delivered, and just once)  MQTT provides for both “retained” and “last will” messages
  • 4.  Blazingly Fast  Enterprise-grade security HiveMQ Broker by DC2  Clustering  Portability  Support  100% MQTT compliant  Websockets  Scalability  Modular  Administration made easy
  • 5.  Despite its powerful network model, real world scenarios often require to extend such network to other communication systems  A common requirement is radio coverage: MQTT Bridging  ZigBee mesh networks for industrial environments  Z-Wave mesh networks for smart home systems  ISM (2.4 GHz) technology for cheap and fast data exchange  Bridging MQTT with these technologies allows for:  building hybrid networks whose nodes share same messaging model  joining different MQTT networks with radio links  greater overall reliability (by redundancy)
  • 6.  “Mesh” networking model means that any node can extend overall coverage to adjacent nodes, acting as a router  Digi XBee modules are by far the most common chips used worldwide ZigBee Networks  Coverage is about 50-100m (1mW) for standard modules and up to 1.6km (50mW) for “Pro” modules  They’re great to implement remote IO management (digital inputs/outputs and analog inputs)…  …but together with a host microcontroller board they’re great to implement arbitrary message exchange too  They can be configured and updated remotely  Serial API exposed to host applications is simple but powerful  We have extended XBee API client libraries originally coded by Micheal Schwartz (mfsmarttoolkit.codeplex.com) in order to get greater reliability and performance
  • 7.  Licensed by Sigma Designs (formerly ZenSys), Z-Wave is becoming the “de facto” standard for Smart Home systems  Z-Wave is based on mesh network model (like ZigBee), but radio modules typically require much less power to work than XBee (a battery operated device can work for years) Z-Wave Networks  There are plenty of Z-Wave enabled devices (power outlets, power meters, sensors, thermostats, blinds motors drivers, switches, etc)  We developed a managed Z-Wave Serial API Controller stack targeted to .NET Micro Framework devices  Our client lib provides support for most commons profiles (basic, meter, multilevelsensor, multilevelswitch, wakeup, etc)  Client API is async-only  Works with any Z-Wave Serial API Controller device, connected through a UART port to host application microcontroller
  • 8.  Despite its great flexibility, a network infrastructure itself cannot address real-world scenarios  We need a way to design and run business logic flows orchestrating message exchange among network nodes Business Logic Flows  Node-red is an open project whose main purpose is that to act as an engine that runs/hosts “flows” designed by mean of node-red itself  Despite being general, it fits in a natural way with MQTT  Node components can be written in JavaScript  It uses a visual design language using a SPA web IDE (hosted by node-red itself)  Many node components are built-in  Despite it can also implement business logic of medium complexity, node-red killer-application is no doubt “interface/API” adaptation among “actors” in heterogeneous systems (in our reference application we provide an example of both cases)
  • 9.  Windows 8 Store App  consumes a custom tcp socket “tunneling” in order to get and publish MQTT messages even with no MQTT client lib support Sample Client Apps  Windows Embedded Compact 2013 App  uses µM2MQTT Library by Paolo Patierno in order to directly interact with MQTT broker  Windows Phone 8, iPhone Apps  use a plain HTTP REST/JSON API  kind of “longpolling” technique implemented by a node-red flow changes messaging model from pub/sub to request/reply
  • 10.  Mirco Vanini: Windows Store App  Paolo Patierno: uM2MQTT Library & WEC 2013 Demo App  Fabrizio Bernabei, Tiziano Cacioppolini: WP8 Demo App Credits  Daniele Galiotto: iPhone App  Lorenzo Maiorfi: firmware, web broker spa web app, node-red flows