40
An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

  • Upload
    others

  • View
    18

  • Download
    0

Embed Size (px)

Citation preview

Page 1: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

An Introduction to Bluetooth MeshMartin WoolleyBluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

Page 2: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

point-to-point 1:1

BR/EDR

broadcast 1:m

Low Energy (LE)

many to many m:m

Mesh

Bluetooth now comes in three delicious flavours

Page 3: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

relationship between Bluetooth technologies

Bluetooth BR/EDR

Bluetooth mesh networking

Bluetooth Low EnergyRADIO

NETWORKING

Page 4: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

Bluetooth Mesh

Networks

Page 5: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

multi-hop, multi-path, multicast

Page 6: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

Bluetooth Mesh

Node Network Roles

Page 7: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

relay nodes

R

RR

R = Relay function on

Relays retransmit messages so that they can travel further, in a number of “hops”

Some nodes can act as “relays” however

Messages get sent to other nodes that are in direct radio range of the publishing node

Page 8: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

friend nodes and low power nodesLow Power Node

(sensor)FriendLow power nodes (LPNs) are highly power constrained

To avoid the need to operate at a high(er) duty cycle to receive messages from the mesh, an LPN works with a Friend

Friend nodes store messages addressed to LPNs they are friends with and forward them when the LPN occasionally polls

Page 9: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

friend nodes and low power nodesLow Power Node

(sensor)Friend

To: Sensor“set temperature thresholds”

Low power nodes (LPNs) are highly power constrained

To avoid the need to operate at a high(er) duty cycle to receive messages from the mesh, an LPN works with a Friend

Friend nodes store messages addressed to LPNs they are friends with and forward them when the LPN occasionally polls

Page 10: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

friend nodes and low power nodes

STOREDMESSAGE(S)

Low Power Node(sensor)Friend

To: Sensor“set temperature thresholds”

Low power nodes (LPNs) are highly power constrained

To avoid the need to operate at a high(er) duty cycle to receive messages from the mesh, an LPN works with a Friend

Friend nodes store messages addressed to LPNs they are friends with and forward them when the LPN occasionally polls

Page 11: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

friend nodes and low power nodes

STOREDMESSAGE(S)

“do you have any messages for me?”

Low Power Node(sensor)Friend

To: Sensor“set temperature thresholds”

Low power nodes (LPNs) are highly power constrained

To avoid the need to operate at a high(er) duty cycle to receive messages from the mesh, an LPN works with a Friend

Friend nodes store messages addressed to LPNs they are friends with and forward them when the LPN occasionally polls

Page 12: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

friend nodes and low power nodes

STOREDMESSAGE(S)

“do you have any messages for me?”

Low Power Node(sensor)Friend

To: Sensor“set temperature thresholds”

To: Sensor“set temperature thresholds”

Low power nodes (LPNs) are highly power constrained

To avoid the need to operate at a high(er) duty cycle to receive messages from the mesh, an LPN works with a Friend

Friend nodes store messages addressed to LPNs they are friends with and forward them when the LPN occasionally polls

Page 13: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

proxy nodes

P

Bluetooth low energy devices like smartphones can communicate with a mesh

network via a proxy nodeLE GATT

MESH

Page 14: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

proxy nodes

P

Bluetooth low energy devices like smartphones can communicate with a mesh

network via a proxy node

mesh monitoring and control applications

LE GATT

MESH

Page 15: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

Bluetooth Mesh

Communication and Interaction

Page 16: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

messages and state

State: OnOff = Off

State: OnOff = Off State: OnOff = Offnodes communicate with each other by sending messages

access messages operate on state values

SET - change of stateGET - retrieve state valueSTATUS - notify current stateACK vs UNACK

nodes have state values which reflect their condition (e.g. ON or OFF)

Page 17: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

messages and state

State: OnOff = Off

State: OnOff = Off State: OnOff = OffState: OnOff = On

State: OnOff = On

State: OnOff = Onnodes communicate with each other by sending messages

access messages operate on state values

SET - change of stateGET - retrieve state valueSTATUS - notify current stateACK vs UNACK

nodes have state values which reflect their condition (e.g. ON or OFF)

Page 18: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

the publish/subscribe communication model

Kitchen Dining Room Hallway Bedroom Garden

Subscribe

Publish

Page 19: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

Bluetooth Mesh

Node Composition

Page 20: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

node composition

a node consists of an arrangement of

elementsmodelsstates

each element has its own address

NODE

ELEMENT ELEMENT

MODEL

STATE

STATE

STATE

MODEL

STATE

MODEL

STATE

STATE

MODEL

STATE

note: a model is sometimes owned by multiple elements

Page 21: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

models

ServerGeneric OnOffServer

Generic OnOffClient

define node functionality

define states, messages, state transitions and behaviors

client, server and control types

generics such as onoff client and server

lighting, sensors, scenes & time

Page 22: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

node composition

single node3 elements

multiple models and states

0x0100 0x0101 0x0102

node

elements

models

states

generic onoff server

light lightness server

light lightness actual

light lightness last

light lightness range

generic onoff

Page 23: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

Bluetooth Mesh

Security

Page 24: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

devices and network membership

only members of the same network can talk to each other

Bluetooth mesh networks are secure

a security process called provisioningmakes a device a member of a network

Page 25: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

devices and network membership

Provisioner: converting a device to a nodeDevice is now a

node on the network

only members of the same network can talk to each other

Bluetooth mesh networks are secure

a security process called provisioningmakes a device a member of a network

Page 26: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

Bluetooth mesh: Security

• Mandatory, cannot be reduced• Encryption and authentication• Separate security for network and each application• Area isolation• Message obfuscation• Protection from replay and trashcan attacks• Secure device provisioning

Page 27: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

network key (netkey)origin: provisioning

use: derivation of other keys

encryption keyorigin: derived from netkey

using the k2 functionuse: secures data

at the networklayer

privacy keyorigin: derived from

netkey using the k2 function

use: obfuscationof network header

information

ref: mesh profile 1.0 section 2.3.9.1

application key (appkey)

origin: created bythe config. client

and provided to nodesafter provisioning

use: securesapplication data

at the upper transportlayer

Bound to one or more models.

device key (devkey)origin: establishedduring provisioning

use: secures communicationbetween the config. client

and individual node

appkey is bound to a netkey

devkey is bound to all netkeys known to a node

Page 28: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

Bluetooth mesh

Anatomy of a smart lighting system

Page 29: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw
Page 30: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

Switch Models Light Models Sensor Models

Page 31: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

Switch Models Light Models Sensor ModelsGeneric On/Off Server

Page 32: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

Switch Models Light Models Sensor ModelsGeneric On/Off Client Generic On/Off Server

Page 33: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

Switch Models Light Models Sensor Models

Light Lightness Server

Light HSL Server

Generic On/Off Client Generic On/Off Server

Page 34: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

Switch Models Light Models Sensor Models

Light Lightness Server

Light HSL Server

Generic On/Off Client Generic On/Off Server

Light LC Server

Sensor Server

Page 35: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

Switch Models Light Models Sensor Models

Light Lightness Server

Light HSL Server

Generic On/Off Client Generic On/Off Server

Light LC Server

Sensor Server

State Binding

Page 36: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

Bluetooth Mesh

Video Demonstration

Page 37: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

Bluetooth Mesh

What next?

Page 38: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

Bluetooth SIG Resources - Reading Material

https://www.bluetooth.com/bluetooth-resources/?types=paper&categories=&tags=mesh

Page 39: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

Bluetooth SIG Resources - hands-on education

https://www.bluetooth.com/bluetooth-resources/?tags=mesh&keyword&types=study-guide

Page 40: An Introduction to Bluetooth Mesh - GOTO Conference · An Introduction to Bluetooth Mesh Martin Woolley Bluetooth SIG Senior Developer Relations Manager, EMEA Twitter: @bluetooth_mdw

Unthinkably ConnectedUnthinkably Connected18 June 2019 34/ Bluetooth SIG Proprietary

Twitter: @bluetooth_mdw

questions?

[email protected].