Top Banner
Towards the Web of Things: Web Mashups for Embedded Devices Dominique Guinard and Vlad Trifa Institute for Pervasive Computing, ETH Zurich and SAP Research Zurich [email protected] www.guinard.org 1
31

Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

Jan 15, 2015

Download

Technology

Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

Towards the Web of Things:Web Mashups for Embedded DevicesDominique Guinard and Vlad TrifaInstitute for Pervasive Computing, ETH Zurich and SAP Research [email protected] www.guinard.org

1

Page 2: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

Discussing the Web of Things

2Dominique Guinard, ETH / SAP Research Zurich, webofthings.com

[http://www.flickr.com/photos/sharynmorrow/]

MEM @ WWW 2009, Madrid

Page 3: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

Embedded Devices Invade us!

3Dominique Guinard, ETH / SAP Research Zurich, webofthings.com

Emergence of the physical Web Embedded devices get more

powerful. They are also getting connected to the

Web.

MEM @ WWW 2009, Madrid

Page 4: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

From a Large Ecosystem to a Large Playground

4Dominique Guinard, ETH / SAP Research Zurich, webofthings.com

Huge eco-system of devices. About 1000 smart objects / person:

and… about 1000 systems to use them and build applications on top of them.

How do we enable people to create applications on top of this great eco-system?

“re-think the way we design computing

systems in order to take into account the

>1000 smart objects per people we will soon

have to deal with.” David Orban

“re-think the way we design computing

systems in order to take into account the

>1000 smart objects per people we will soon

have to deal with.” David Orban

MEM @ WWW 2009, Madrid

Page 5: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

Web 2.0 Mashups

5Dominique Guinard, ETH / SAP Research Zurich, webofthings.com

Mashups are a nice example of « easily » building new applications on top of a virtual eco-system of services.

Not the universal answer but seemingly adapted to dynamic and moderately big use-cases involving end-users.

How about creating real-world mashups?

MEM @ WWW 2009, Madrid

Page 6: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

Web of Things (WOT) in a Nutshell

Fully integrating embedded devices to the Web, by designing “web-oriented” APIs for embedded devices: A Web-page for each “service”. A RESTful API to access and consume them.

As a result: Embedded devices are easier to build upon. We get the goodies of the web almost for free (caching, linking,

searching, authenticating, etc.) And enable physical mashups, i.e. small, ad-hoc composite

applications involving real-world embedded devices.

MEM @ WWW 2009, Madrid 6Dominique Guinard, ETH / SAP Research Zurich, webofthings.com

Page 7: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

Our 5 Courses Menu

Discussing the Web of Things A Web Oriented Architecture for the Real-World

Building RESTful APIs for Real-World Devices Integration Patterns: Gateway vs Direct Integration

Implementation and Prototypes RESTful Sun SPOTs RESTful Ploggs

Real-World Mashups Energie Visible Google Web Toolkit UI Ambient Meter

7Dominique Guinard, ETH / SAP Research Zurich, webofthings.comMEM @ WWW 2009, Madrid

Page 8: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

A Web Oriented Architecture for the Real-World

Dominique Guinard, ETH / SAP Research Zurich, webofthings.com

8

[http://www.flickr.com/photos/julianbleecker]

MEM @ WWW 2009, Madrid

Page 9: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

Our 5 Courses Menu

Discussing the Web of Things A Web Oriented Architecture for the Real-World

Building RESTful APIs for Real-World Devices Integration Patterns: Gateway vs Direct Integration

Implementation and Prototypes RESTful Sun SPOTs RESTful Ploggs

Real-World Mashups Energie Visible Google Web Toolkit UI Ambient Meter

9Dominique Guinard, ETH / SAP Research Zurich, webofthings.comMEM @ WWW 2009, Madrid

Page 10: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

1. Resource Design

Thanks to their atomicity services on embedded devices are quite adapted to Resource-Oriented Architectures.

Root: http://webofthings.com/ Resources:

Spots: http://webofthings.com/spots Spot 2: http://webofthings.com/spots/2 Light Sensor: http://webofthings.com/spots/2/sensors/light Led Actuator:

http://webofthings.com/spots/2/actuators/led/

10Dominique Guinard, ETH / SAP Research Zurich, webofthings.comMEM @ WWW 2009, Madrid

Page 11: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

XHTML as default, ideal for browsing: http://webofthings.com/spots

JSON, ideal for parsing: http://webofthings.com/spots.json

XML, ideal for integration http://webofthings.com/spots.xml

2. Representation Design

11Dominique Guinard, ETH / SAP Research Zurich, webofthings.comMEM @ WWW 2009, Madrid

Page 12: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

3. Uniform Interface

12Dominique Guinard, ETH / SAP Research Zurich, webofthings.com

[HTTP: http://en.wikipedia.org/wiki/Hypertext_Transfer_Protocol]

MEM @ WWW 2009, Madrid

Page 13: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

3. Uniform Interface

• HTTP Verbs: What do you want to do?– GET: retrieve the representation of a resource.– PUT: create or update a resource.– DELETE: remove a resource.– POST: create a subordinate (or custom: RPC!)

• HTTP Headers: What type of data are you sending me?– Metadata:

• Content type: application/json, text/html, etc.

– Status:• 200 OK, 201 Create, 400 Bad Request, 401 Unauthorized

• HTTP Body: The actual data.– The content in its representation.

13Dominique Guinard, ETH / SAP Research Zurich, webofthings.comMEM @ WWW 2009, Madrid

Page 14: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

Integration Patterns: Gateway vs Direct

14Dominique Guinard, ETH / SAP Research Zurich, webofthings.com

IPv6(lowpan)

Web CloudWeb Cloud

ComposeCompose VisualizeVisualizeSearchSearch PhysicalMashups

Smart GatewaySmart Gateway

RESTful API

BTBT ZigbeeZigbee ……API1 API2

Web CloudWeb Cloud

ComposeCompose VisualizeVisualizeSearchSearch PhysicalMashups

Web Server

RESTful API

Web ServerRESTful API

Web ServerEventing

MEM @ WWW 2009, Madrid

Page 15: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

Implementation and Prototypes

15Dominique Guinard, ETH / SAP Research Zurich, webofthings.com

[http://www.flickr.com/photos/sharynmorrow/47086098/]

MEM @ WWW 2009, Madrid

Page 16: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

Our 5 Courses Menu

Discussing the Web of Things A Web Oriented Architecture for the Real-World

Building RESTful APIs for Real-World Devices Integration Patterns: Gateway vs Direct Integration

Implementation and Prototypes RESTful Sun SPOTs RESTful Ploggs

Real-World Mashups Energie Visible Google Web Toolkit UI Ambient Meter

16Dominique Guinard, ETH / SAP Research Zurich, webofthings.comMEM @ WWW 2009, Madrid

Page 17: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

Direct Integration

17Dominique Guinard, ETH / SAP Research Zurich, webofthings.com

IPv6(lowpan)

Web CloudWeb Cloud

ComposeCompose VisualizeVisualizeSearchSearch PhysicalMashups

Smart GatewaySmart Gateway

RESTful API

BTBT ZigbeeZigbee ……API1 API2

Web CloudWeb Cloud

ComposeCompose VisualizeVisualizeSearchSearch PhysicalMashups

Web Server

RESTful API

Web ServerRESTful API

Web ServerEventing

MEM @ WWW 2009, Madrid

Page 18: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

The RESTful SunSPOTs Project

Create a « SmartLogger » that can be attached to shipments.

www.webofthings.com/tag/smartlogger/

18Dominique Guinard, ETH / SAP Research Zurich, webofthings.comMEM @ WWW 2009, Madrid

Page 19: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

Architecture

MEM @ WWW 2009, Madrid 19Dominique Guinard, ETH / SAP Research Zurich, webofthings.com

Page 20: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

Integration using Gateways

20Dominique Guinard, ETH / SAP Research Zurich, webofthings.com

IPv6(lowpan)

Web CloudWeb Cloud

ComposeCompose VisualizeVisualizeSearchSearch PhysicalMashups

Smart GatewaySmart Gateway

RESTful API

BTBT ZigbeeZigbee ……API1 API2

Web CloudWeb Cloud

ComposeCompose VisualizeVisualizeSearchSearch PhysicalMashups

Web Server

RESTful API

Web ServerRESTful API

Web ServerEventing

MEM @ WWW 2009, Madrid

Page 21: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

The « Energie Visible » Project

21Dominique Guinard, ETH / SAP Research Zurich, webofthings.com

• Aim:• Monitor and control

your energy consumption at home.

• Fully integrate the monitoring and control to the web.

• www.webofthings.com/energievisible/

Gateway and Mini Webserver

Sensors(Ploggs)

Devices

Web / Mobile Interface

MEM @ WWW 2009, Madrid

Page 22: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

RESTful Plogg Gateway

22Dominique Guinard, ETH / SAP Research Zurich, webofthings.comMEM @ WWW 2009, Madrid

Page 23: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

Talk to devices: The WEB Way

23Dominique Guinard, ETH / SAP Research Zurich, webofthings.comMEM @ WWW 2009, Madrid

Page 24: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

Demo

24Dominique Guinard, ETH / SAP Research Zurich, webofthings.comMEM @ WWW 2009, Madrid

Page 25: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

Examples of Real-World Mashups

25Dominique Guinard, ETH / SAP Research Zurich, webofthings.com

[http://www.flickr.com/photos/kevlar]

MEM @ WWW 2009, Madrid

Page 26: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

Our 5 Courses Menu

Motivation Discussing Real-World Integration Schemes

WS-* Web Services RESTful APIs

A Web Oriented Architecture for the Real-World Building RESTful APIs for Real-World Devices Integration Patterns: Gateway vs Direct Integration

Implementation and Prototypes RESTful Sun SPOTs RESTful Ploggs

Real-World Mashups Energie Visible Google Web Toolkit UI Ambient Meter

26Dominique Guinard, ETH / SAP Research Zurich, webofthings.comMEM @ WWW 2009, Madrid

Page 27: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

Enable Real-World Mashups

27Dominique Guinard, ETH / SAP Research Zurich, webofthings.com

URL

URL

URL

URL

MEM @ WWW 2009, Madrid

Page 28: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

Physical-Virtual Mashup:Energy Visualizer for RESTful Ploggs

28Dominique Guinard, ETH / SAP Research Zurich, webofthings.comMEM @ WWW 2009, Madrid

Page 29: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

Physical-Physical Mashup:Ambient Energy Meter

Create an ambient device that can assess the energy consumption of the current place it is in.

Mashup of: The RESTful Ploggs

The RESTful Sun Spots

The Smart Gateways.

29Dominique Guinard, ETH / SAP Research Zurich, webofthings.comMEM @ WWW 2009, Madrid

Page 30: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

Outlook

REST is quite suitable for composing small, ad-hoc applications [1], why not for small embedded applications?

Need to go beyond REST: Need for asynchronous mechanisms. Currently exploring systems such as XMPP and Twitter.

Need to provide mashup editors for physical mashups (à la “yahoo pipes” or “rooftop”).

MEM @ WWW 2009, Madrid 30Dominique Guinard, ETH / SAP Research Zurich, webofthings.com

[1] Pautasso, Cesare, Olaf Zimmermann, and Frank Leymann. “Restful web services vs. "big"' web services: making the right architectural decision.” In WWW '08: Proceeding of the 17th international conference on World Wide Web, 805―814. New York, NY, USA: ACM, 2008.

Page 31: Towards the Web of Things: Web Mashups for the Real-World @ MEM 2009

Thanks a lot for your attention

31Dominique Guinard, ETH / SAP Research Zurich, webofthings.com

www.webofthings.comMEM @ WWW 2009, Madrid