+ All Categories
Home > Documents > Device Management for OSGi IoT Gateways · Agenda Introduction to IoT Gateways and Kura Device...

Device Management for OSGi IoT Gateways · Agenda Introduction to IoT Gateways and Kura Device...

Date post: 01-Sep-2018
Category:
Upload: vuongkhue
View: 225 times
Download: 0 times
Share this document with a friend
25
+ Device Management for OSGi IoT Gateways Luca Dazi @ Eurotech Julien V ermillard @ Sierra Wireless
Transcript
Page 1: Device Management for OSGi IoT Gateways · Agenda Introduction to IoT Gateways and Kura Device Management for OSGi Which Protocols? MQTT LwM2M/CoAP Demo Next Steps

+

Device Management

for OSGi IoT Gateways

Luca Dazi @ Eurotech

Julien Vermillard @ Sierra Wireless

Page 2: Device Management for OSGi IoT Gateways · Agenda Introduction to IoT Gateways and Kura Device Management for OSGi Which Protocols? MQTT LwM2M/CoAP Demo Next Steps

+Agenda

Introduction to IoT Gateways and Kura

Device Management for OSGi

Which Protocols?

MQTT

LwM2M/CoAP

Demo

Next Steps

Page 3: Device Management for OSGi IoT Gateways · Agenda Introduction to IoT Gateways and Kura Device Management for OSGi Which Protocols? MQTT LwM2M/CoAP Demo Next Steps

+

Business

Application

IoT GatewaysRevolution: Towards Real-time Actionable Data

MQTT

Broker

Page 4: Device Management for OSGi IoT Gateways · Agenda Introduction to IoT Gateways and Kura Device Management for OSGi Which Protocols? MQTT LwM2M/CoAP Demo Next Steps

+Eclipse Open IoT Stack for JavaEclipse Kura

Java SE 7 / 8 (OpenJDK)

OSGi Application Container (Eclipse Equinox, Concierge)

Device Abstraction

javax.comm

Basic Gateway Services

DB Service

Clock Service

Device Profile

Watchdog

Network Configuration

Field ProtocolsConnectivity and Delivery

Data Services MQTT Paho

Ad

min

istr

ati

on

GU

I

Applications

Your Application

Re

mo

te M

an

ag

em

en

t

Co

nfi

gu

rati

on

Ma

na

ge

me

nt

javax.usb

w/ udev access

Cloud Services

Your Application

Firewall, Port

Forwarding

Link

Monitors

Cellular, Wi-Fi,

Ethernet

GPS PositionGPIO / SPI / I2C

jdk.dio

Modbus

CANBus

Custom Protocols

Up

da

tes

Ma

na

ge

me

nt

Re

mo

te A

cc

ess

Java HID APIs javax.bluetooth / BLE

...

Your Application

Page 5: Device Management for OSGi IoT Gateways · Agenda Introduction to IoT Gateways and Kura Device Management for OSGi Which Protocols? MQTT LwM2M/CoAP Demo Next Steps

+Device Management

Manage the OSGi application software

Remote OSGi Bundle Updates

Remote OSGi Service Configuration

Remote OSGi Control

Management of the Device

Firmware Updates

Monitor and Diagnostics

Remote Access

Page 6: Device Management for OSGi IoT Gateways · Agenda Introduction to IoT Gateways and Kura Device Management for OSGi Which Protocols? MQTT LwM2M/CoAP Demo Next Steps

+Device ManagementWhich protocol?

Usual suspects

TR-069

OMA-DM

LwM2M

Can we have a Device Management over the telemetry protocol?- Single protocol- Single security- Simplified deployment- Simplified management

Kura Case Study

MQTT

CoAP/LwM2M

Page 7: Device Management for OSGi IoT Gateways · Agenda Introduction to IoT Gateways and Kura Device Management for OSGi Which Protocols? MQTT LwM2M/CoAP Demo Next Steps

+M2M Integration TechnologiesMessage Queue Telemetry Transport (MQTT)

M2M Messaging Protocol

Low Bandwidth / Low Power

2-way Communication

Publish and Subscribe

Hierarchical Topic Namespaces

Data Payload Agnostic

Device Initiated Connection

Firewall-friendly

SSL and Authenticated

Large ecosystem

Page 8: Device Management for OSGi IoT Gateways · Agenda Introduction to IoT Gateways and Kura Device Management for OSGi Which Protocols? MQTT LwM2M/CoAP Demo Next Steps

+Kura MQTT Topic NamespaceIntroduction

Data Topics

Used for push of sensor data, metrics, or other data

Example: [account_id]/[client_id]/...

Control Topics

Used for dynamic request/response interactions between clients

Example: CTL/[account_id]/[client_id]/[app_id]/…

Separate data from control topics

Provides increased granularity on ACLs

Allows for segregation of persistent and transient data

Page 9: Device Management for OSGi IoT Gateways · Agenda Introduction to IoT Gateways and Kura Device Management for OSGi Which Protocols? MQTT LwM2M/CoAP Demo Next Steps

+Kura MQTT Resource ManagementREST like

Request

CTL/[account_id]/[client_id]/[app_id]/GET/[resource_id]

CTL/[account_id]/[client_id]/[app_id]/POST/[resource_id]

CTL/[account_id]/[client_id]/[app_id]/PUT/[resource_id]

CTL/[account_id]/[client_id]/[app_id]/DEL/[resource_id]

CTL/[account_id]/[client_id]/[app_id]/EXEC/[resource_id]

Response

CTL/[account_id]/[requester_client_id]/[app_id]/REPLY/[req_id]

Page 10: Device Management for OSGi IoT Gateways · Agenda Introduction to IoT Gateways and Kura Device Management for OSGi Which Protocols? MQTT LwM2M/CoAP Demo Next Steps

+MQTT Request/Response

Responder

(device1)

Requester

(manager1)

Responder

Subscribes on request topic:

CTL/kura/device1/CONF-V1/GET/configurations

Page 11: Device Management for OSGi IoT Gateways · Agenda Introduction to IoT Gateways and Kura Device Management for OSGi Which Protocols? MQTT LwM2M/CoAP Demo Next Steps

+MQTT Request/Response

Responder

(device1)

Requester

(manager1)

Requester

Generates request metadata (for request payload):

request_id: 1363603920892

request_client_id: manager1

Subscribes on reply topic:

CTL/kura/manager1/CONF-V1/REPLY/1363603920892

Page 12: Device Management for OSGi IoT Gateways · Agenda Introduction to IoT Gateways and Kura Device Management for OSGi Which Protocols? MQTT LwM2M/CoAP Demo Next Steps

+MQTT Request/Response

Responder

(device1)

Requester

(manager1)

Requester

Sends MQTT request

CTL/kura/device1/CONF-V1/GET/configurations

Page 13: Device Management for OSGi IoT Gateways · Agenda Introduction to IoT Gateways and Kura Device Management for OSGi Which Protocols? MQTT LwM2M/CoAP Demo Next Steps

+MQTT Request/Response

Responder

(device1)

Requester

(manager1)

Responder

Handles request and generates response using request

specific parameters in the payload of the request

• [request_id] and [request_client_id] included in

request payload

• Manditory response code

• Optional application specific parameters

• Optional logs, exceptions, stacktraces, etc

Page 14: Device Management for OSGi IoT Gateways · Agenda Introduction to IoT Gateways and Kura Device Management for OSGi Which Protocols? MQTT LwM2M/CoAP Demo Next Steps

+MQTT Request/Response

Responder

(device1)

Requester

(manager1)

Responder

Sends response to requesting client

CTL/kura/manager1/CONF-V1/REPLY/1363603920892

Page 15: Device Management for OSGi IoT Gateways · Agenda Introduction to IoT Gateways and Kura Device Management for OSGi Which Protocols? MQTT LwM2M/CoAP Demo Next Steps

+MQTT Request / ResponseResponse Codes: HTTP Like

response_code

200 (RESPONSE_CODE_OK)

400 (RESPONSE_CODE_BAD_REQUEST)

404 (RESPONSE_CODE_NOTFOUND)

500 (RESPONSE_CODE_ERROR)

response_exception_message

Optional and contains error message if an error occurred

response_stacktrace_message

Optional and contains a stacktrace

Page 16: Device Management for OSGi IoT Gateways · Agenda Introduction to IoT Gateways and Kura Device Management for OSGi Which Protocols? MQTT LwM2M/CoAP Demo Next Steps

+Kura OSGi Management via MQTT

Bundle management

Retrieve Bundle information for installed bundles

Start/Stop currently installed bundles

Deployment packages

Install new deployment packages (collections of OSGi Bundles)

Update/Uninstall existing deployment packages

Configuration Management

Retrieve, review, update Service Configuration

Support OSGi MetaType service descriptors

Remote Access

Page 17: Device Management for OSGi IoT Gateways · Agenda Introduction to IoT Gateways and Kura Device Management for OSGi Which Protocols? MQTT LwM2M/CoAP Demo Next Steps

+CoAP

RESTful protocol designed from scratch IETF

Transparent mapping to HTTP:

GET, POST, PUT, DELETE and URLs

Features for M2M scenario (observe & sms)

Based on UDP, draft for using TCP

Page 18: Device Management for OSGi IoT Gateways · Agenda Introduction to IoT Gateways and Kura Device Management for OSGi Which Protocols? MQTT LwM2M/CoAP Demo Next Steps

+

Open Mobile Alliance standard

Device management on top of CoAP

Object model: for D.M. or Applications

(IPSO)

OMA Lightweight M2M

Page 19: Device Management for OSGi IoT Gateways · Agenda Introduction to IoT Gateways and Kura Device Management for OSGi Which Protocols? MQTT LwM2M/CoAP Demo Next Steps

+

Security

Device

Location

Firmware

Connectivity monitoring & management

Lock & wipe

You can provide your own object to OMA

Standard Objects

Page 20: Device Management for OSGi IoT Gateways · Agenda Introduction to IoT Gateways and Kura Device Management for OSGi Which Protocols? MQTT LwM2M/CoAP Demo Next Steps

+

/{object}/{instance}/{resource}

Example:

“/6/0” : get the whole GPS position instance

“/6/0/2” : get only the altitude resource

URL Example

Page 21: Device Management for OSGi IoT Gateways · Agenda Introduction to IoT Gateways and Kura Device Management for OSGi Which Protocols? MQTT LwM2M/CoAP Demo Next Steps

+LwM2M in KuraDraft

Kura Service LwM2M Object

System Service Device

Position Service Location

Kura Firmware

Modem Monitor Connectivity Monitoring

Cloud/Data/Transport Service (TBD) Connectivity Statistics

Kura Deployment Package Software Management

Kura Component Meta-Type Custom: Software

Configuration Definition

Kura Configurable Component Custom: Software

Configuration Values

Page 22: Device Management for OSGi IoT Gateways · Agenda Introduction to IoT Gateways and Kura Device Management for OSGi Which Protocols? MQTT LwM2M/CoAP Demo Next Steps

+LwM2M Software Configuration

Kura Data Service Component LwM2M Objects

/90 – Custom Object for Kura Component

/90/7 – LwM2M Object Instance

/90/7/0 – String Resource (name)

Data Service

/90/7/3 – Multiple String Resource (Value list)

‘false’,’60’,’10’, ...

/91 – Custom Object for Kura Metatype Definitions

...

\\

/91/20 – LwM2M Object Instance

/91/20/0 – String Resource (id)

disconnect.quiesce-timeout

/91/18/2 – Integer Resource (type)

1

/90/7/4 – Multiple Integer Resource (AD list)

0x012, 0x013, 0x014, ...

...

Page 23: Device Management for OSGi IoT Gateways · Agenda Introduction to IoT Gateways and Kura Device Management for OSGi Which Protocols? MQTT LwM2M/CoAP Demo Next Steps

+Demo

Page 24: Device Management for OSGi IoT Gateways · Agenda Introduction to IoT Gateways and Kura Device Management for OSGi Which Protocols? MQTT LwM2M/CoAP Demo Next Steps

+Next Steps

https://github.com/eclipse/kura/tree/lwm2m

CoAP as alternative DataTransport in Kura

LwM2M over MQTT

Join the discussion:

kura-dev mailing list

iot-dev mailing list

Page 25: Device Management for OSGi IoT Gateways · Agenda Introduction to IoT Gateways and Kura Device Management for OSGi Which Protocols? MQTT LwM2M/CoAP Demo Next Steps

+1 0 -1

Sign in: www.eclipsecon.org

Evaluate the sessions


Recommended