Top Banner
THE SMART DEVICE SPECIFICATION FOR REMOTE LABS Christophe Salzmann, Sten Govaerts, Wissam Halimi, & Denis Gillet Anjo Anjewierden, Lars Bollen, Augustín Caminero, Manuel Castro, German Carro, Gabriel Díaz, Danilo Garbi Zutin, Miguel Latorre, Irene Lequerica Zorrozua, Pablo Orduna, Antonio Robles, Elio San Crístobal, and Simon Schwantzer
79

The Smart Device Specification for Remote Labs

Jul 14, 2015

Download

Education

Sten Govaerts
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: The Smart Device Specification for Remote Labs

THE SMART DEVICE SPECIFICATION

FOR REMOTE LABSChristophe Salzmann, Sten Govaerts,

Wissam Halimi, & Denis GilletAnjo Anjewierden, Lars Bollen, Augustín Caminero, Manuel Castro, German Carro, Gabriel Díaz, Danilo Garbi Zutin, Miguel Latorre, Irene Lequerica Zorrozua, Pablo Orduna, Antonio Robles, Elio San Crístobal, and Simon Schwantzer

Page 2: The Smart Device Specification for Remote Labs

AGENDA

• What are Smart Devices?• What do we want to achieve?• The specification• An example• Implementation• Conclusion

Page 3: The Smart Device Specification for Remote Labs

SMART DEVICES?

Internet of Things

Page 4: The Smart Device Specification for Remote Labs

SMART DEVICES?

Internet of Things

Page 5: The Smart Device Specification for Remote Labs

SMART DEVICES?

Internet of Things

Page 6: The Smart Device Specification for Remote Labs

SMART DEVICES?

Internet of Things

Page 7: The Smart Device Specification for Remote Labs

SMART DEVICES?

1. communication2. sensing & actuating3. reasoning & learning4. identity & kind5. memory & status tracking

Smart Devices are connected to the internet with some or all of these capabilities:

Thompson, C.W., "Smart devices and soft controllers," Internet Computing, IEEE , 2005.

Page 8: The Smart Device Specification for Remote Labs

…we extended this idea for remote labs.

Page 9: The Smart Device Specification for Remote Labs

client server

CLASSIC CLIENT-SERVER

Page 10: The Smart Device Specification for Remote Labs

client server

CLASSIC CLIENT-SERVERclient often tightly linked to server

Page 11: The Smart Device Specification for Remote Labs

client server

CLASSIC CLIENT-SERVERclient often tightly linked to server clients cannot

be reused

Page 12: The Smart Device Specification for Remote Labs

client server

CLASSIC CLIENT-SERVERclient often tightly linked to server

server updates often require client updates

clients cannot be reused

Page 13: The Smart Device Specification for Remote Labs

client server

CLASSIC CLIENT-SERVERclient often tightly linked to server

server updates often require client updates

clients cannot be reused

Page 14: The Smart Device Specification for Remote Labs

client server

CLASSIC CLIENT-SERVERclient often tightly linked to server

server updates often require client updates

clients cannot be reused

Page 15: The Smart Device Specification for Remote Labs

client server

SMART DEVICE

Page 16: The Smart Device Specification for Remote Labs

client server

SMART DEVICE

Page 17: The Smart Device Specification for Remote Labs

client serversmart device speci-

fication

SMART DEVICE

Page 18: The Smart Device Specification for Remote Labs

client serversmart device speci-

fication

SMART DEVICE

Page 19: The Smart Device Specification for Remote Labs

client serversmart device speci-

fication

data viewer

app

SMART DEVICE

Page 20: The Smart Device Specification for Remote Labs

client serversmart device speci-

fication

data viewer

app

learning analytics

client

SMART DEVICE

Page 21: The Smart Device Specification for Remote Labs

client serversmart device speci-

fication

data viewer

app

learning analytics

client

metadata repository

SMART DEVICE

Page 22: The Smart Device Specification for Remote Labs

client serversmart device speci-

fication

data viewer

app

learning analytics

client

metadata repository

SMART DEVICE

implementation agnostic

Page 23: The Smart Device Specification for Remote Labs

SMART DEVICES IN

Page 24: The Smart Device Specification for Remote Labs

THE SPECIFICATION

• services, e.g. to control actuators & sensors

• service description and metadata

…consists of:

and:• internal functionality best practices & guidelines• easily extensible with new services

Page 25: The Smart Device Specification for Remote Labs

TECHNOLOGY

WebSocket Swaggerhttp://swagger.io/

https://github.com/go-lab/smart-device-metadata

Page 26: The Smart Device Specification for Remote Labs

TECHNOLOGY

WebSocket Swaggerhttp://swagger.io/

https://github.com/go-lab/smart-device-metadata

🔧

Page 27: The Smart Device Specification for Remote Labs

TECHNOLOGY

WebSocket Swagger

the specification is programming language agnostic

http://swagger.io/

https://github.com/go-lab/smart-device-metadata

🔧

Page 28: The Smart Device Specification for Remote Labs

METADATA CHARACTERISTICS

• lab info & lab owner• concurrency & authorization• provided services & API info

• sensor & actuator metadata is a service

The metadata describes:

…and:

Page 29: The Smart Device Specification for Remote Labs

SERVICES & FUNCTIONALITYSERVICES

Page 30: The Smart Device Specification for Remote Labs

SERVICES & FUNCTIONALITY

getSensorMetadata

getSensorData

getActuatorMetadata

sendActuatorData

getLoggingInfo

getClients

getModels

SERVICES

Page 31: The Smart Device Specification for Remote Labs

SERVICES & FUNCTIONALITY

getSensorMetadata

getSensorData

getActuatorMetadata

sendActuatorData

getLoggingInfo

getClients

getModels

SERVICES FUNCTIONALITY

Page 32: The Smart Device Specification for Remote Labs

SERVICES & FUNCTIONALITY

getSensorMetadata

getSensorData

getActuatorMetadata

sendActuatorData

getLoggingInfo

getClients

getModels

SERVICES FUNCTIONALITYauthentication

self and known state*

security and local control*

logging and alarms

local simulation

Page 33: The Smart Device Specification for Remote Labs

AN EXAMPLEclient smart device

… …

Page 34: The Smart Device Specification for Remote Labs

AN EXAMPLEclient smart device

Hey! What can you do?http://serverIP/metadata

… …

Page 35: The Smart Device Specification for Remote Labs

AN EXAMPLEclient smart device

Hey! What can you do?http://serverIP/metadata

{ name…, “services”: […], …}Here is what I do!

… …

Page 36: The Smart Device Specification for Remote Labs

AN EXAMPLEclient smart device

Hey! What can you do?http://serverIP/metadata

{ name…, “services”: […], …}Here is what I do!

services=[…]

… …

Page 37: The Smart Device Specification for Remote Labs

AN EXAMPLEclient smart device

Hey! What can you do?http://serverIP/metadata

{ name…, “services”: […], …}Here is what I do!

Which sensors do you have?{“method”: “getSensorMetadata”}

services=[…]

… …

Page 38: The Smart Device Specification for Remote Labs

AN EXAMPLEclient smart device

Hey! What can you do?http://serverIP/metadata

{ name…, “services”: […], …}Here is what I do!

Which sensors do you have?{“method”: “getSensorMetadata”}

services=[…]

{“method”:“getSensorMetadata”, “sensors": [ { "sensorId": “disc pos”, "values": [

{…"rangeMinimum": 0, "rangeMaximum": 10,…} ],…}

These are my sensors:

… …

Page 39: The Smart Device Specification for Remote Labs

AN EXAMPLEclient smart device

Hey! What can you do?http://serverIP/metadata

{ name…, “services”: […], …}Here is what I do!

Which sensors do you have?{“method”: “getSensorMetadata”}

services=[…]

{“method”:“getSensorMetadata”, “sensors": [ { "sensorId": “disc pos”, "values": [

{…"rangeMinimum": 0, "rangeMaximum": 10,…} ],…}

These are my sensors:sensors=[{ id:“disc pos”,min:0,max:10}]; … …

Page 40: The Smart Device Specification for Remote Labs

AN EXAMPLE CONTINUED

client

… …

smart device

Page 41: The Smart Device Specification for Remote Labs

AN EXAMPLE CONTINUED

clientWhich actuators do you have?

{“method”: “getActuatorMetadata”}

… …

smart device

Page 42: The Smart Device Specification for Remote Labs

AN EXAMPLE CONTINUED

clientWhich actuators do you have?

{“method”: “getActuatorMetadata”}

{“method”:“getActuatorMetadata”, “actuators": [{ ”actuatorId": “motor”, …"values": [

{…"rangeMinimum": -5, "rangeMaximum": 5,…} ]}

These are my actuators:

… …

smart device

Page 43: The Smart Device Specification for Remote Labs

AN EXAMPLE CONTINUED

clientWhich actuators do you have?

{“method”: “getActuatorMetadata”}

{“method”:“getActuatorMetadata”, “actuators": [{ ”actuatorId": “motor”, …"values": [

{…"rangeMinimum": -5, "rangeMaximum": 5,…} ]}

These are my actuators:actuators=[{id:“motor”,min:-5,max:5}];

… …

smart device

Page 44: The Smart Device Specification for Remote Labs

AN EXAMPLE CONTINUED

clientWhich actuators do you have?

{“method”: “getActuatorMetadata”}

{“method”:“getActuatorMetadata”, “actuators": [{ ”actuatorId": “motor”, …"values": [

{…"rangeMinimum": -5, "rangeMaximum": 5,…} ]}

These are my actuators:actuators=[{id:“motor”,min:-5,max:5}];

Yay! I can make a UI!

… …

smart device

Page 45: The Smart Device Specification for Remote Labs

AN EXAMPLE CONTINUED

clientWhich actuators do you have?

{“method”: “getActuatorMetadata”}

{“method”:“getActuatorMetadata”, “actuators": [{ ”actuatorId": “motor”, …"values": [

{…"rangeMinimum": -5, "rangeMaximum": 5,…} ]}

These are my actuators:actuators=[{id:“motor”,min:-5,max:5}];

Yay! I can make a UI!

motor:

disc pos:

… …

smart device

Page 46: The Smart Device Specification for Remote Labs

AN EXAMPLE CONTINUED

clientWhich actuators do you have?

{“method”: “getActuatorMetadata”}

{“method”:“getActuatorMetadata”, “actuators": [{ ”actuatorId": “motor”, …"values": [

{…"rangeMinimum": -5, "rangeMaximum": 5,…} ]}

These are my actuators:actuators=[{id:“motor”,min:-5,max:5}];

Yay! I can make a UI!

motor:

disc pos:

… …

Give me the current disc pos…{“method”:“getSensorData”, “sensorId”: “disc pos”}

smart device

Page 47: The Smart Device Specification for Remote Labs

AN EXAMPLE CONTINUED

client

… …

smart device

Page 48: The Smart Device Specification for Remote Labs

AN EXAMPLE CONTINUED

client

… …

Here is the current position:{“method”:“getSensorData”, “sensorId”: “disc pos”,

“data”:[6.2], “lastMeasured”:[“18:28”]…}

smart device

Page 49: The Smart Device Specification for Remote Labs

AN EXAMPLE CONTINUED

client

… …

Here is the current position:{“method”:“getSensorData”, “sensorId”: “disc pos”,

“data”:[6.2], “lastMeasured”:[“18:28”]…}motor:

disc pos:6.2

smart device

Page 50: The Smart Device Specification for Remote Labs

AN EXAMPLE CONTINUED

client

… …

Here is the current position:{“method”:“getSensorData”, “sensorId”: “disc pos”,

“data”:[6.2], “lastMeasured”:[“18:28”]…}

Here is the current position:{“method”:“getSensorData”, “sensorId”: “disc pos”,

“data”:[7.1], “lastMeasured”:[“18:30”]…}

motor:

disc pos:6.2

smart device

Page 51: The Smart Device Specification for Remote Labs

AN EXAMPLE CONTINUED

client

… …

Here is the current position:{“method”:“getSensorData”, “sensorId”: “disc pos”,

“data”:[6.2], “lastMeasured”:[“18:28”]…}

Here is the current position:{“method”:“getSensorData”, “sensorId”: “disc pos”,

“data”:[7.1], “lastMeasured”:[“18:30”]…}

motor:

disc pos:6.2

motor:

disc pos:7.1

smart device

Page 52: The Smart Device Specification for Remote Labs

AN EXAMPLE CONTINUED

client

… …

Here is the current position:{“method”:“getSensorData”, “sensorId”: “disc pos”,

“data”:[6.2], “lastMeasured”:[“18:28”]…}

Here is the current position:{“method”:“getSensorData”, “sensorId”: “disc pos”,

“data”:[7.1], “lastMeasured”:[“18:30”]…}

motor:

disc pos:6.2

motor:

disc pos:7.1

smart device

Page 53: The Smart Device Specification for Remote Labs

AN EXAMPLE CONTINUED

client

… …

Set the motor to 3{“authToken”:”42FE36”, method”:“sendActuatorData”,

“actuatorId”: “motor”,…“data”:[3], …}

Here is the current position:{“method”:“getSensorData”, “sensorId”: “disc pos”,

“data”:[6.2], “lastMeasured”:[“18:28”]…}

Here is the current position:{“method”:“getSensorData”, “sensorId”: “disc pos”,

“data”:[7.1], “lastMeasured”:[“18:30”]…}

motor:

disc pos:6.2

motor:

disc pos:7.1

smart device

Page 54: The Smart Device Specification for Remote Labs

AN EXAMPLE CONTINUED

client

… …

Set the motor to 3{“authToken”:”42FE36”, method”:“sendActuatorData”,

“actuatorId”: “motor”,…“data”:[3], …}

Here is the current position:{“method”:“getSensorData”, “sensorId”: “disc pos”,

“data”:[6.2], “lastMeasured”:[“18:28”]…}

Here is the current position:{“method”:“getSensorData”, “sensorId”: “disc pos”,

“data”:[7.1], “lastMeasured”:[“18:30”]…}

motor:

disc pos:6.2

motor:

disc pos:7.1

smart device

Page 55: The Smart Device Specification for Remote Labs

AN EXAMPLE CONTINUED

client

… …

Set the motor to 3{“authToken”:”42FE36”, method”:“sendActuatorData”,

“actuatorId”: “motor”,…“data”:[3], …}

Here is the current position:{“method”:“getSensorData”, “sensorId”: “disc pos”,

“data”:[6.2], “lastMeasured”:[“18:28”]…}

Here is the current position:{“method”:“getSensorData”, “sensorId”: “disc pos”,

“data”:[7.1], “lastMeasured”:[“18:30”]…}

motor:

disc pos:6.2

motor:

disc pos:7.1

auth

entic

ate(

42FE

36)

smart device

Page 56: The Smart Device Specification for Remote Labs

AN EXAMPLE CONTINUED

client

… …

Set the motor to 3{“authToken”:”42FE36”, method”:“sendActuatorData”,

“actuatorId”: “motor”,…“data”:[3], …}

Here is the current position:{“method”:“getSensorData”, “sensorId”: “disc pos”,

“data”:[6.2], “lastMeasured”:[“18:28”]…}

Here is the current position:{“method”:“getSensorData”, “sensorId”: “disc pos”,

“data”:[7.1], “lastMeasured”:[“18:30”]…}

motor:

disc pos:6.2

motor:

disc pos:7.1

auth

entic

ate(

42FE

36)

YES!

smart device

Page 57: The Smart Device Specification for Remote Labs

AN EXAMPLE CONTINUED

client

… …

Set the motor to 3{“authToken”:”42FE36”, method”:“sendActuatorData”,

“actuatorId”: “motor”,…“data”:[3], …}

Here is the current position:{“method”:“getSensorData”, “sensorId”: “disc pos”,

“data”:[6.2], “lastMeasured”:[“18:28”]…}

Here is the current position:{“method”:“getSensorData”, “sensorId”: “disc pos”,

“data”:[7.1], “lastMeasured”:[“18:30”]…}

motor:

disc pos:6.2

motor:

disc pos:7.1

auth

entic

ate(

42FE

36)

set motor to 3

YES!

smart device

Page 58: The Smart Device Specification for Remote Labs

BUT…IS IT A SMART DEVICE?

1. communication2. sensing & actuating3. reasoning & learning4. identity & kind5. memory & status tracking

Smart Devices are connected to the internet with some or all of these capabilities:

Page 59: The Smart Device Specification for Remote Labs

BUT…IS IT A SMART DEVICE?

1. communication2. sensing & actuating3. reasoning & learning4. identity & kind5. memory & status tracking

Smart Devices are connected to the internet with some or all of these capabilities:

Page 60: The Smart Device Specification for Remote Labs

BUT…IS IT A SMART DEVICE?

1. communication2. sensing & actuating3. reasoning & learning4. identity & kind5. memory & status tracking

Smart Devices are connected to the internet with some or all of these capabilities:

✔✔

Page 61: The Smart Device Specification for Remote Labs

BUT…IS IT A SMART DEVICE?

1. communication2. sensing & actuating3. reasoning & learning4. identity & kind5. memory & status tracking

Smart Devices are connected to the internet with some or all of these capabilities:

✘✔

Page 62: The Smart Device Specification for Remote Labs

BUT…IS IT A SMART DEVICE?

1. communication2. sensing & actuating3. reasoning & learning4. identity & kind5. memory & status tracking

Smart Devices are connected to the internet with some or all of these capabilities:

✘✔

Page 63: The Smart Device Specification for Remote Labs

BUT…IS IT A SMART DEVICE?

1. communication2. sensing & actuating3. reasoning & learning4. identity & kind5. memory & status tracking

Smart Devices are connected to the internet with some or all of these capabilities:

✘✔

✔✔✘

Page 64: The Smart Device Specification for Remote Labs

IMPLEMENTATION

https://github.com/go-lab/smart-device

Page 65: The Smart Device Specification for Remote Labs

IMPLEMENTATION

https://github.com/go-lab/smart-device

Page 66: The Smart Device Specification for Remote Labs

IMPLEMENTATION

https://github.com/go-lab/smart-device

Page 67: The Smart Device Specification for Remote Labs

http

://go

labz.e

u

Page 68: The Smart Device Specification for Remote Labs

http

://go

labz.e

u

Page 69: The Smart Device Specification for Remote Labs

http

://go

labz.e

u

Page 70: The Smart Device Specification for Remote Labs

http

://go

labz.e

u

Page 71: The Smart Device Specification for Remote Labs

http

://go

labz.e

u

Page 72: The Smart Device Specification for Remote Labs

…WHAT IF YOU DO NOT WANT TO REIMPLEMENT YOUR LAB?

client legacy lab server

Page 73: The Smart Device Specification for Remote Labs

…WHAT IF YOU DO NOT WANT TO REIMPLEMENT YOUR LAB?

then go with Gateway4Labs!

https://github.com/gateway4labs

client legacy lab server

Page 74: The Smart Device Specification for Remote Labs

…WHAT IF YOU DO NOT WANT TO REIMPLEMENT YOUR LAB?

then go with Gateway4Labs!

https://github.com/gateway4labs

client legacy lab server

smart gateway

Page 75: The Smart Device Specification for Remote Labs

…WHAT IF YOU DO NOT WANT TO REIMPLEMENT YOUR LAB?

then go with Gateway4Labs!

https://github.com/gateway4labs

client legacy lab server

smart gateway

Page 76: The Smart Device Specification for Remote Labs

…WHAT IF YOU DO NOT WANT TO REIMPLEMENT YOUR LAB?

then go with Gateway4Labs!

https://github.com/gateway4labs

client legacy lab server

smart gateway

acts as a smart device!

Page 77: The Smart Device Specification for Remote Labs

CONCLUSION• the Smart Device specification decouples client-

server through well-defined services & metadata, creating:• interoperability between clients and other Smart Devices• a machine readable specification that allows

the generation of simple client UIs

• platform agnostic & implementationsare available

Page 78: The Smart Device Specification for Remote Labs

STANDARDISATION• the specification is taken up by the IEEE working

group P1876 as a candidate for the final spec.

http://ieee-sa.centraldesktop.com/1876public/

Page 79: The Smart Device Specification for Remote Labs

2

slides will appear on http://www.slideshare.net/stengovaertsslides will appear on http://www.slideshare.net/stengovaerts 22

contact: [email protected]