building the web of things: frameworks and tools for fast

19
Building the Web of Things: frameworks and tools for fast prototyping Web-based physical mashups Sketching in Hardware 2011 Vlad Trifa & Dominique Guinard - ETH Zurich

Upload: others

Post on 03-Feb-2022

1 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Building the Web of Things: frameworks and tools for fast

Building the Web of Things: frameworks and tools for fast prototyping Web-based physical mashupsSketching in Hardware 2011Vlad Trifa & Dominique Guinard - ETH Zurich

Page 2: Building the Web of Things: frameworks and tools for fast

Vlad Trifa - ETH Zurich - webofthings.comSketching in Hardware 2011

Context

2

■ Embedded computers, sensors, actuators are omnipresent■ Increasingly powerful CPU and bandwidth■ Tremendous benefits in ad-hoc connectivity

■ Challenges: incompatible protocols, functionalities, interfaces, etc.

Page 3: Building the Web of Things: frameworks and tools for fast

Vlad Trifa - ETH Zurich - webofthings.comSketching in Hardware 2011

Context

2

■ Embedded computers, sensors, actuators are omnipresent■ Increasingly powerful CPU and bandwidth■ Tremendous benefits in ad-hoc connectivity

■ Challenges: incompatible protocols, functionalities, interfaces, etc.

How to combine heterogeneous, mobile devices to create

interactive, ad-hoc applications?

Page 4: Building the Web of Things: frameworks and tools for fast

We need an universal protocol that is:

simple, lightweight, loosely-coupled, scalable, flexible

and hopefully... standard

Page 5: Building the Web of Things: frameworks and tools for fast

Vlad Trifa - ETH Zurich - webofthings.comSketching in Hardware 2011

Sounds like the Web...

■ TCP/IP & Web granted, Wi-Fi routers ubiquitous■ Prototyping of simple Web apps: cheaper & faster■ Integrate real-world data on the Web■ Get features of the Web for free

Use Web standards to develop applications for networked devices - Web of Things(HTTP, HTML, XML, JSON, RSS, ATOM, MIME,...)

4

Page 6: Building the Web of Things: frameworks and tools for fast

Vlad Trifa - ETH Zurich - webofthings.comSketching in Hardware 2011

Web-enabled Devices

■ Devices run Web server ■ services RESTful resources

■ URI for each component■ hierarchy

■ Uniform Interface■ HTTP verbs & codes

■ Representations■ HTML: humans■ JSON/XML/CSV: machines

■ Stateless (hateoas)

5

GET fire/alerts.xml

PUTtv/channel/4

GET fridge/food.html

Page 7: Building the Web of Things: frameworks and tools for fast

Vlad Trifa - ETH Zurich - webofthings.comSketching in Hardware 2011

Gateways

6

Web HTTP

ZigBee

Bluetooth

X10

IEEE802.9

DPWS

HTTP

HTTP

Google

Flickr

Gateway

Page 8: Building the Web of Things: frameworks and tools for fast

DRV

1

DRV

2

...DT1

...DT2

device

services

device layer

control layer

presentation layer

REST

engine

HTTP

server

proxy application

user

services

application

services

templating

engine

messaging

services

device

drivers

device

threads pool

../devices/1

../devices/2

devices

DB

Vlad Trifa - ETH Zurich - webofthings.comSketching in Hardware 2011

Smart Gateway

7

Page 9: Building the Web of Things: frameworks and tools for fast

0 50 100 150 200 250 300 350 4000

50

100

150

200

250

300

350R

esp

on

se t

ime

[m

s]

Request number

EmbeddedSynchronization

Vlad Trifa - ETH Zurich - webofthings.comSketching in Hardware 2011 8

Page 10: Building the Web of Things: frameworks and tools for fast

distributedscalableinfrastructures

Page 11: Building the Web of Things: frameworks and tools for fast

/ethz

../CNB

../CNB/FloorD

../southWing/D48.1

../CNB/FloorEvirt

ual g

atew

ays

(can

run

anyw

here

)ph

ysic

al g

atew

ays

(mus

t be

embo

died

)

../southWing/D48.2

../floorD/southWing

Vlad Trifa - ETH Zurich - webofthings.comSketching in Hardware 2011

InfraWoT - location-aware infrastructure for WoT

10

Page 12: Building the Web of Things: frameworks and tools for fast

errr, what about eventing & streaming ?

the web wasn’t quite made for this...

Page 13: Building the Web of Things: frameworks and tools for fast

Vlad Trifa - ETH Zurich - webofthings.comSketching in Hardware 2011

Web Streams

■ Sensor data represented as sequence of messages ■ Publish/subscribe paradigm

■ Web push via Real-time Web■ Web Hooks, WebSockets, Comet, XMPP, ATOM, etc.

■ Parameterized■ devices■ sensors■ filter data■ sampling frequency

■ Messaging: bi-directional glue between components

12

Page 14: Building the Web of Things: frameworks and tools for fast

end-to-end applications framework for sensor data collection, processing, sharing, and storage

Page 15: Building the Web of Things: frameworks and tools for fast

MCDCvarious data

acquisition protocols

1. raw

2. raw data

Client SC

QC

2'. processed

5. raw & processed

Client

3. raw 4. processed

Sensors 1. Device Connector

2. Messaging Connector

3. Query Connector

4. Storage Connector

Vlad Trifa - ETH Zurich - webofthings.comSketching in Hardware 2011

WISSPR - Web Infrastructure for Sensor Stream PRocessing

14

Page 16: Building the Web of Things: frameworks and tools for fast

Vlad Trifa - ETH Zurich - webofthings.comSketching in Hardware 2011

Complete Request

15

POST streams/ HTTP/1.1Host: wisspr.net/Content-Type: application/x-www-form-urlencodedContent:devices=http://devices.wisspr.net/spot11 &data=temperature,light &frequency=2Hz &filter=light < 200 && temperature > 19 &wms.cbk=http://store.wisspr.net/stores/31

Page 17: Building the Web of Things: frameworks and tools for fast

Vlad Trifa - ETH Zurich - webofthings.comSketching in Hardware 2011

ClickScript - Physical mashup editor

16

Try it!!webofthings.com/clickscript

Page 18: Building the Web of Things: frameworks and tools for fast

Vlad Trifa - ETH Zurich - webofthings.comSketching in Hardware 2011

Conclusions

■ Huge opportunities ahead for WoT■ The Web of Things is hard because ■ People are good Web developers

XOR■ Good embedded systems developers

■ Tradeoff between performance and features■ Tools & best practices for Web-enabled things are needed■ Deployment support, runtime debugging, patterns & toolkits, etc.

■ Prototyping large-scale applications■ Stop talking, start hacking

17

Page 19: Building the Web of Things: frameworks and tools for fast

Thanks for your attention !

ありがとうございました!

T - @vladounetM - [email protected] - webofthings.com