SlideShare a Scribd company logo
LEADING
COLLABORATION
IN THE ARM
ECOSYSTEM
New Zephyr features
LWM2M / FOTA Framework
Marti Bolivar <marti.bolivar@linaro.org>
David Brown <david.brown@linaro.org>
Ricardo Salveti <ricardo.salveti@linaro.org>
Mike Scott <michael.scott@linaro.org>
LEADING COLLABORATION
IN THE ARM ECOSYSTEM
Zephyr and LTD
“changing at an alarming pace”
LEADING COLLABORATION
IN THE ARM ECOSYSTEM
Version Changesets Changed lines
1.1.0 481 15,798(+) 9,205(-)
1.2.0 482 37,176(+) 11,044(-)
1.3.0 456 37,216(+) 15,452(-)
1.4.0 473 289,223(+) 14,585(-)
1.5.0 970 179,485(+) 18,732(-)
1.6.0 3,188 1,706,583(+) 131,887(-)
1.7.0 1,839 1,126,493(+) 336,555(-)
1.8.0 1,692 858,467(+) 239,250(-)
Since Zephyr v1.0.0 (February 8)
LEADING COLLABORATION
IN THE ARM ECOSYSTEM
FOTA at last Connect
● MCUBoot talk given by David
○ Introduce the bootloader
○ Discuss the Zephyr port, work with Runtime, etc
○ A more detailed update was given earlier today in SFO17-118, so just some Zep
updates to discuss today
● hawkBit keynote demo
○ FOTA updates of devices which live-streamed temperature data
○ An updated demo was given at today’s keynote
LEADING COLLABORATION
IN THE ARM ECOSYSTEM
Zephyr work since then
● Firmware over the air (FOTA) framework
● LWM2M subsystem and example applications
● Today’s keynote demos
○ hawkBit
○ LWM2M
○ BT Mesh lights
Work in progress, in collaboration with other groups and companies.
LEADING COLLABORATION
IN THE ARM ECOSYSTEM
MCUBoot + FOTA framework
LEADING COLLABORATION
IN THE ARM ECOSYSTEM
Desiderata
● Should be possible to add SoC or board support for
mcuboot without changing mcuboot repository
● Should be possible to portably share system configuration
○ The bootloader,
○ Applications which are chain-loaded by it
○ Bootloader and application build systems (including flashing
and debug)
In short, mcuboot should be “easy”.
LEADING COLLABORATION
IN THE ARM ECOSYSTEM
Booting with MCUBoot
Application image
area
Other
Application
update area
TMPMCUBoot Etc
MCUBoot’s job is to move a new image in the update
area to the main application image area, using the
temporary (TMP) scratch space to avoid data loss.
It and apps need to know various details about the
flash device, and peacefully coexist with other
partitions.
MCUBoot
header
Vector table
LEADING COLLABORATION
IN THE ARM ECOSYSTEM
Flash specifics to know about (apps and bootloader)
Sector
0
Sector
1
Sector 2 Sector n - 1...Sector
3
● Map between sectors and “partitions” / image areas
● Nonuniform sector sizes (e.g. STM32)
● Widely varying “write block sizes” (1, 4, 8 common)
LEADING COLLABORATION
IN THE ARM ECOSYSTEM
Support issues on Zephyr
Zephyr (or other RTOS)
Kernel Flash driver
Bootutil library
(bootloader core)
Board header (flash layout,
WBS, sector sizes)
Small application, mostly defers to bootutil
HAL (for mynewt compatibility)
One header file per board with
flash layout, sector “size”, etc.
This information is duplicated
again in every application that
needs to manage FOTA updates
with mcuboot.
This is tedious and error-prone.
Also, what happens when you
want to change the config?
Partitions in DTS now, but more
remains for writing apps.
Other issues around flashing, etc.
LEADING COLLABORATION
IN THE ARM ECOSYSTEM
MCUBoot with Zephyr + “FOTA framework”
Zephyr
Kernel Flash driver + device
tree (partition / sector
map, write block size)
Bootutil library (bootloader core)
Small application, mostly defers to bootutil
HAL (flash layout, WBS, variable sector size support)
MCUBoot /
DFU manager
MCUBoot’s HAL will allow
target-specific hacks, but
supports obtaining everything
from the OS.
Target-specific behavior from DTS and
the flash driver.
MCUBoot manager allows apps and
bootloader to start sharing code.
Makefile.exports for build systems, but
more work needed to make this easy.
LEADING COLLABORATION
IN THE ARM ECOSYSTEM
LWM2M
LEADING COLLABORATION
IN THE ARM ECOSYSTEM
LWM2M from 10,000 ft (3048 m)
UDP, L2, PHY
CoAP [+DTLS]
LWM2M
IPSO objects
Application callbacks, etc.
LEADING COLLABORATION
IN THE ARM ECOSYSTEM
LWM2M and IPSO
● LWM2M: 18 base objects managed via OMA Working Groups with room for
expansion up to object id 1023. Security (0), Server (1), Device (3), Firmware (5) ...
● IPSO: Hundreds of standard and vendor-defined objects starting with object id
2048. Examples: Light control (3311) used in keynote demo, also presence
(3302), humidity (3304), accelerometer (3313), magnetometer (3314), …
● These well-defined objects / resources increase interoperability.
More details in the OMA registry.
LEADING COLLABORATION
IN THE ARM ECOSYSTEM
Resource Name Read/write Number Required? Type
5850 On/Off RW Single Mandatory Boolean
5851 Dimmer RW Single Optional Integer
5852 On Time RW Single Optional Integer
5805 Cumulative
active power
R Single Optional
5820 Power Factor R Single Optional Float
5706 Colour RW Single Optional String
5701 Sensor Units R Single Optional String
IPSO Light Control Object Resources
LEADING COLLABORATION
IN THE ARM ECOSYSTEM
IPSO Light Control in Source Form
static struct lwm2m_engine_obj_field fields[] = {
OBJ_FIELD_DATA(LIGHT_ON_OFF_ID, RW, BOOL),
OBJ_FIELD_DATA(LIGHT_DIMMER_ID, RW, U8),
OBJ_FIELD_DATA(LIGHT_ON_TIME_ID, RW, S32),
OBJ_FIELD_DATA(LIGHT_CUMULATIVE_ACTIVE_POWER_ID, R,
FLOAT32),
OBJ_FIELD_DATA(LIGHT_POWER_FACTOR_ID, R, FLOAT32),
OBJ_FIELD_DATA(LIGHT_COLOUR_ID, RW, STRING),
OBJ_FIELD_DATA(LIGHT_SENSOR_UNITS_ID, R, STRING),
};
LEADING COLLABORATION
IN THE ARM ECOSYSTEM
Instance-specific data declarations
/* Initialize instance resource data. */
INIT_OBJ_RES_DATA(res[avail], i, LIGHT_ON_OFF_ID,
&on_off_value[avail], sizeof(*on_off_value));
INIT_OBJ_RES_DATA(res[avail], i, LIGHT_DIMMER_ID,
&dimmer_value[avail], sizeof(*dimmer_value));
[...]
INIT_OBJ_RES_DATA(res[avail], i, LIGHT_SENSOR_UNITS_ID,
units[avail], LIGHT_STRING_SHORT);
LEADING COLLABORATION
IN THE ARM ECOSYSTEM
Application level
/* Resource initialization */
lwm2m_engine_set_string("3/0/0", CLIENT_MANUFACTURER);
lwm2m_engine_set_string("3/0/1", CLIENT_MODEL_NUMBER);
[...]
/* Engine startup */
ret = lwm2m_rd_client_start(&client, CONFIG_NET_APP_PEER_IPV6_ADDR,
CONFIG_LWM2M_PEER_PORT, CONFIG_BOARD,
rd_client_event);
LEADING COLLABORATION
IN THE ARM ECOSYSTEM
End to End Demo System
● Control an LED and do a FOTA
update via LWM2M
● Canned Docker containers and
build system glue to get moving
quickly
● http://ltd-docs.readthedocs.io/
en/ltd-17.09/iotfoundry/lwm2m
-howto.html
LEADING COLLABORATION
IN THE ARM ECOSYSTEM
How to play with the Zephyr LWM2M Client locally
● Download the latest Leshan Demo Server build and start
○ $ wget
https://hudson.eclipse.org/leshan/job/leshan/lastSuccessfulBuild/artifact/
leshan-server-demo.jar
○ $ java -jar ./leshan-server-demo.jar
○ Open a web browser to: http://localhost:8080
● Run the Zephyr LWM2M Client via QEMU
○ Follow “Getting Started” Guide
○ Follow “Networking with QEMU” Docs
○ $ make -C samples/net/lwm2m_client run
LEADING COLLABORATION
IN THE ARM ECOSYSTEM
Zephyr LWM2M Roadmap
In Zephyr v1.9
● LWM2M Engine to manage
registering smart object and
handling read/write/create/delete
operations.
● Registration device client state
machine (DTLS not supported yet)
● 4 OMA LWM2M objects: Security,
Server, Device and Firmware
● Support for firmware update via
both direct resource write and pull
via URL resource.
Coming in the future
● Migrate to new Zephyr CoAP APIs.
● LWM2M Engine to support DTLS.
● Registration client to support
bootstrap state machine.
● Add more OMA standard smart
objects: Access Controls, Location
…
● Add more IPSO Smart Objects.
● Optimization!

More Related Content

PDF
BSD Sockets API in Zephyr RTOS - SFO17-108
PDF
Internet of Tiny Linux (IoTL): Episode IV - SFO17-100
PDF
Using SoC Vendor HALs in the Zephyr Project - SFO17-112
PDF
Deploy STM32 family on Zephyr - SFO17-102
PDF
MOVED: RDK/WPE Port on DB410C - SFO17-206
PDF
LAS16-100K1: Welcome Keynote
PDF
Emerging Persistent Memory Hardware and ZUFS - PM-based File Systems in User ...
PDF
SGX Trusted Execution Environment
BSD Sockets API in Zephyr RTOS - SFO17-108
Internet of Tiny Linux (IoTL): Episode IV - SFO17-100
Using SoC Vendor HALs in the Zephyr Project - SFO17-112
Deploy STM32 family on Zephyr - SFO17-102
MOVED: RDK/WPE Port on DB410C - SFO17-206
LAS16-100K1: Welcome Keynote
Emerging Persistent Memory Hardware and ZUFS - PM-based File Systems in User ...
SGX Trusted Execution Environment

What's hot (20)

PDF
OpenWrt From Top to Bottom
PDF
Emanuele Faranda - Creating network overlays with IoT devices using N2N
PDF
BKK16-211 Internet of Tiny Linux (io tl)- Status and Progress
PDF
Claudio Scordino - Handling mixed criticality on embedded multi-core systems
PDF
BUD17 Socionext SC2A11 ARM Server SoC
PDF
The Linux Block Layer - Built for Fast Storage
PDF
BUD17-400: Secure Data Path with OPTEE
PDF
Valerio Di Giampietro - Introduction To IoT Reverse Engineering with an examp...
PDF
Secure Boot on ARM systems – Building a complete Chain of Trust upon existing...
PDF
Andrea Righi - Spying on the Linux kernel for fun and profit
PDF
LAS16-407: Internet of Tiny Linux (IoTL): the sequel.
PDF
F9 Microkernel code reading - part 1
PDF
Mirko Damiani - An Embedded soft real time distributed system in Go
PPTX
Linux Interrupts
PDF
Kernel Recipes 2015: Greybus
PDF
BUD17-104: Scripting Languages in IoT: Challenges and Approaches
PDF
Michele Dionisio & Pietro Lorefice - Developing and testing a device driver w...
PPT
Libpcap
PDF
LAS16-300: Mini Conference 2 Cortex-M Software - Device Configuration
PPTX
Kernel Proc Connector and Containers
OpenWrt From Top to Bottom
Emanuele Faranda - Creating network overlays with IoT devices using N2N
BKK16-211 Internet of Tiny Linux (io tl)- Status and Progress
Claudio Scordino - Handling mixed criticality on embedded multi-core systems
BUD17 Socionext SC2A11 ARM Server SoC
The Linux Block Layer - Built for Fast Storage
BUD17-400: Secure Data Path with OPTEE
Valerio Di Giampietro - Introduction To IoT Reverse Engineering with an examp...
Secure Boot on ARM systems – Building a complete Chain of Trust upon existing...
Andrea Righi - Spying on the Linux kernel for fun and profit
LAS16-407: Internet of Tiny Linux (IoTL): the sequel.
F9 Microkernel code reading - part 1
Mirko Damiani - An Embedded soft real time distributed system in Go
Linux Interrupts
Kernel Recipes 2015: Greybus
BUD17-104: Scripting Languages in IoT: Challenges and Approaches
Michele Dionisio & Pietro Lorefice - Developing and testing a device driver w...
Libpcap
LAS16-300: Mini Conference 2 Cortex-M Software - Device Configuration
Kernel Proc Connector and Containers
Ad

Similar to New Zephyr features: LWM2M / FOTA Framework - SFO17-113 (20)

PDF
ARM® Cortex™ M Bootup_CMSIS_Part_2_3
PDF
RTOS implementation
PDF
Freertos based environmental data acquisition using arm cortex m4 f core
PPT
L1 and L3 _uCOS Task and scheduler concepts
PPTX
Processors topic in system on chip architecture
PPT
Embedded system apsd
PPT
Extending oracle tools final
PPTX
PrismTech Integrated Communications Systems Modeling
PPTX
Fundamentals of Internet of Things (IoT)
PDF
IRJET - Positioning and Tracking of a Person using Embedded Controller in a D...
PPTX
MemVerge: The Software Stack for CXL Environments
PDF
Lab6 rtos
PPT
Christchurch Embedded .NET User Group - Introduction to Microsoft Embedded pl...
PPTX
JRCS Component-Difference Server Roles and it's Significance.pptx
PDF
1-AVR Introduction to Atmega32 good .pdf
PDF
Acpi and smi handlers some limits to trusted computing
PDF
Lucas apa pacsec slides
PPT
Georgy Nosenko - An introduction to the use SMT solvers for software security
DOCX
Project Report On Micro-controller Embedded System
PDF
Configuring ee (enterprise extender) between two ibm system i systems tech ...
ARM® Cortex™ M Bootup_CMSIS_Part_2_3
RTOS implementation
Freertos based environmental data acquisition using arm cortex m4 f core
L1 and L3 _uCOS Task and scheduler concepts
Processors topic in system on chip architecture
Embedded system apsd
Extending oracle tools final
PrismTech Integrated Communications Systems Modeling
Fundamentals of Internet of Things (IoT)
IRJET - Positioning and Tracking of a Person using Embedded Controller in a D...
MemVerge: The Software Stack for CXL Environments
Lab6 rtos
Christchurch Embedded .NET User Group - Introduction to Microsoft Embedded pl...
JRCS Component-Difference Server Roles and it's Significance.pptx
1-AVR Introduction to Atmega32 good .pdf
Acpi and smi handlers some limits to trusted computing
Lucas apa pacsec slides
Georgy Nosenko - An introduction to the use SMT solvers for software security
Project Report On Micro-controller Embedded System
Configuring ee (enterprise extender) between two ibm system i systems tech ...
Ad

More from Linaro (20)

PDF
Deep Learning Neural Network Acceleration at the Edge - Andrea Gallo
PDF
Arm Architecture HPC Workshop Santa Clara 2018 - Kanta Vekaria
PDF
Huawei’s requirements for the ARM based HPC solution readiness - Joshua Mora
PDF
Bud17 113: distribution ci using qemu and open qa
PDF
OpenHPC Automation with Ansible - Renato Golin - Linaro Arm HPC Workshop 2018
PDF
HPC network stack on ARM - Linaro HPC Workshop 2018
PDF
It just keeps getting better - SUSE enablement for Arm - Linaro HPC Workshop ...
PDF
Intelligent Interconnect Architecture to Enable Next Generation HPC - Linaro ...
PDF
Yutaka Ishikawa - Post-K and Arm HPC Ecosystem - Linaro Arm HPC Workshop Sant...
PDF
Andrew J Younge - Vanguard Astra - Petascale Arm Platform for U.S. DOE/ASC Su...
PDF
HKG18-501 - EAS on Common Kernel 4.14 and getting (much) closer to mainline
PDF
HKG18-100K1 - George Grey: Opening Keynote
PDF
HKG18-318 - OpenAMP Workshop
PDF
HKG18-501 - EAS on Common Kernel 4.14 and getting (much) closer to mainline
PDF
HKG18-315 - Why the ecosystem is a wonderful thing, warts and all
PDF
HKG18- 115 - Partitioning ARM Systems with the Jailhouse Hypervisor
PDF
HKG18-TR08 - Upstreaming SVE in QEMU
PDF
HKG18-113- Secure Data Path work with i.MX8M
PPTX
HKG18-120 - Devicetree Schema Documentation and Validation
PPTX
HKG18-223 - Trusted FirmwareM: Trusted boot
Deep Learning Neural Network Acceleration at the Edge - Andrea Gallo
Arm Architecture HPC Workshop Santa Clara 2018 - Kanta Vekaria
Huawei’s requirements for the ARM based HPC solution readiness - Joshua Mora
Bud17 113: distribution ci using qemu and open qa
OpenHPC Automation with Ansible - Renato Golin - Linaro Arm HPC Workshop 2018
HPC network stack on ARM - Linaro HPC Workshop 2018
It just keeps getting better - SUSE enablement for Arm - Linaro HPC Workshop ...
Intelligent Interconnect Architecture to Enable Next Generation HPC - Linaro ...
Yutaka Ishikawa - Post-K and Arm HPC Ecosystem - Linaro Arm HPC Workshop Sant...
Andrew J Younge - Vanguard Astra - Petascale Arm Platform for U.S. DOE/ASC Su...
HKG18-501 - EAS on Common Kernel 4.14 and getting (much) closer to mainline
HKG18-100K1 - George Grey: Opening Keynote
HKG18-318 - OpenAMP Workshop
HKG18-501 - EAS on Common Kernel 4.14 and getting (much) closer to mainline
HKG18-315 - Why the ecosystem is a wonderful thing, warts and all
HKG18- 115 - Partitioning ARM Systems with the Jailhouse Hypervisor
HKG18-TR08 - Upstreaming SVE in QEMU
HKG18-113- Secure Data Path work with i.MX8M
HKG18-120 - Devicetree Schema Documentation and Validation
HKG18-223 - Trusted FirmwareM: Trusted boot

Recently uploaded (20)

PDF
Modernizing your data center with Dell and AMD
PPTX
Big Data Technologies - Introduction.pptx
PDF
Spectral efficient network and resource selection model in 5G networks
PPT
“AI and Expert System Decision Support & Business Intelligence Systems”
PDF
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
PPTX
MYSQL Presentation for SQL database connectivity
PDF
Per capita expenditure prediction using model stacking based on satellite ima...
PDF
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
PDF
Machine learning based COVID-19 study performance prediction
PDF
NewMind AI Monthly Chronicles - July 2025
PPTX
Digital-Transformation-Roadmap-for-Companies.pptx
PDF
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
PDF
Unlocking AI with Model Context Protocol (MCP)
PDF
Diabetes mellitus diagnosis method based random forest with bat algorithm
DOCX
The AUB Centre for AI in Media Proposal.docx
PPTX
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
PPTX
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
PDF
Approach and Philosophy of On baking technology
PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
PPT
Teaching material agriculture food technology
Modernizing your data center with Dell and AMD
Big Data Technologies - Introduction.pptx
Spectral efficient network and resource selection model in 5G networks
“AI and Expert System Decision Support & Business Intelligence Systems”
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
MYSQL Presentation for SQL database connectivity
Per capita expenditure prediction using model stacking based on satellite ima...
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
Machine learning based COVID-19 study performance prediction
NewMind AI Monthly Chronicles - July 2025
Digital-Transformation-Roadmap-for-Companies.pptx
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
Unlocking AI with Model Context Protocol (MCP)
Diabetes mellitus diagnosis method based random forest with bat algorithm
The AUB Centre for AI in Media Proposal.docx
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
Approach and Philosophy of On baking technology
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
Teaching material agriculture food technology

New Zephyr features: LWM2M / FOTA Framework - SFO17-113

  • 1. LEADING COLLABORATION IN THE ARM ECOSYSTEM New Zephyr features LWM2M / FOTA Framework Marti Bolivar <marti.bolivar@linaro.org> David Brown <david.brown@linaro.org> Ricardo Salveti <ricardo.salveti@linaro.org> Mike Scott <michael.scott@linaro.org>
  • 2. LEADING COLLABORATION IN THE ARM ECOSYSTEM Zephyr and LTD “changing at an alarming pace”
  • 3. LEADING COLLABORATION IN THE ARM ECOSYSTEM Version Changesets Changed lines 1.1.0 481 15,798(+) 9,205(-) 1.2.0 482 37,176(+) 11,044(-) 1.3.0 456 37,216(+) 15,452(-) 1.4.0 473 289,223(+) 14,585(-) 1.5.0 970 179,485(+) 18,732(-) 1.6.0 3,188 1,706,583(+) 131,887(-) 1.7.0 1,839 1,126,493(+) 336,555(-) 1.8.0 1,692 858,467(+) 239,250(-) Since Zephyr v1.0.0 (February 8)
  • 4. LEADING COLLABORATION IN THE ARM ECOSYSTEM FOTA at last Connect ● MCUBoot talk given by David ○ Introduce the bootloader ○ Discuss the Zephyr port, work with Runtime, etc ○ A more detailed update was given earlier today in SFO17-118, so just some Zep updates to discuss today ● hawkBit keynote demo ○ FOTA updates of devices which live-streamed temperature data ○ An updated demo was given at today’s keynote
  • 5. LEADING COLLABORATION IN THE ARM ECOSYSTEM Zephyr work since then ● Firmware over the air (FOTA) framework ● LWM2M subsystem and example applications ● Today’s keynote demos ○ hawkBit ○ LWM2M ○ BT Mesh lights Work in progress, in collaboration with other groups and companies.
  • 6. LEADING COLLABORATION IN THE ARM ECOSYSTEM MCUBoot + FOTA framework
  • 7. LEADING COLLABORATION IN THE ARM ECOSYSTEM Desiderata ● Should be possible to add SoC or board support for mcuboot without changing mcuboot repository ● Should be possible to portably share system configuration ○ The bootloader, ○ Applications which are chain-loaded by it ○ Bootloader and application build systems (including flashing and debug) In short, mcuboot should be “easy”.
  • 8. LEADING COLLABORATION IN THE ARM ECOSYSTEM Booting with MCUBoot Application image area Other Application update area TMPMCUBoot Etc MCUBoot’s job is to move a new image in the update area to the main application image area, using the temporary (TMP) scratch space to avoid data loss. It and apps need to know various details about the flash device, and peacefully coexist with other partitions. MCUBoot header Vector table
  • 9. LEADING COLLABORATION IN THE ARM ECOSYSTEM Flash specifics to know about (apps and bootloader) Sector 0 Sector 1 Sector 2 Sector n - 1...Sector 3 ● Map between sectors and “partitions” / image areas ● Nonuniform sector sizes (e.g. STM32) ● Widely varying “write block sizes” (1, 4, 8 common)
  • 10. LEADING COLLABORATION IN THE ARM ECOSYSTEM Support issues on Zephyr Zephyr (or other RTOS) Kernel Flash driver Bootutil library (bootloader core) Board header (flash layout, WBS, sector sizes) Small application, mostly defers to bootutil HAL (for mynewt compatibility) One header file per board with flash layout, sector “size”, etc. This information is duplicated again in every application that needs to manage FOTA updates with mcuboot. This is tedious and error-prone. Also, what happens when you want to change the config? Partitions in DTS now, but more remains for writing apps. Other issues around flashing, etc.
  • 11. LEADING COLLABORATION IN THE ARM ECOSYSTEM MCUBoot with Zephyr + “FOTA framework” Zephyr Kernel Flash driver + device tree (partition / sector map, write block size) Bootutil library (bootloader core) Small application, mostly defers to bootutil HAL (flash layout, WBS, variable sector size support) MCUBoot / DFU manager MCUBoot’s HAL will allow target-specific hacks, but supports obtaining everything from the OS. Target-specific behavior from DTS and the flash driver. MCUBoot manager allows apps and bootloader to start sharing code. Makefile.exports for build systems, but more work needed to make this easy.
  • 12. LEADING COLLABORATION IN THE ARM ECOSYSTEM LWM2M
  • 13. LEADING COLLABORATION IN THE ARM ECOSYSTEM LWM2M from 10,000 ft (3048 m) UDP, L2, PHY CoAP [+DTLS] LWM2M IPSO objects Application callbacks, etc.
  • 14. LEADING COLLABORATION IN THE ARM ECOSYSTEM LWM2M and IPSO ● LWM2M: 18 base objects managed via OMA Working Groups with room for expansion up to object id 1023. Security (0), Server (1), Device (3), Firmware (5) ... ● IPSO: Hundreds of standard and vendor-defined objects starting with object id 2048. Examples: Light control (3311) used in keynote demo, also presence (3302), humidity (3304), accelerometer (3313), magnetometer (3314), … ● These well-defined objects / resources increase interoperability. More details in the OMA registry.
  • 15. LEADING COLLABORATION IN THE ARM ECOSYSTEM Resource Name Read/write Number Required? Type 5850 On/Off RW Single Mandatory Boolean 5851 Dimmer RW Single Optional Integer 5852 On Time RW Single Optional Integer 5805 Cumulative active power R Single Optional 5820 Power Factor R Single Optional Float 5706 Colour RW Single Optional String 5701 Sensor Units R Single Optional String IPSO Light Control Object Resources
  • 16. LEADING COLLABORATION IN THE ARM ECOSYSTEM IPSO Light Control in Source Form static struct lwm2m_engine_obj_field fields[] = { OBJ_FIELD_DATA(LIGHT_ON_OFF_ID, RW, BOOL), OBJ_FIELD_DATA(LIGHT_DIMMER_ID, RW, U8), OBJ_FIELD_DATA(LIGHT_ON_TIME_ID, RW, S32), OBJ_FIELD_DATA(LIGHT_CUMULATIVE_ACTIVE_POWER_ID, R, FLOAT32), OBJ_FIELD_DATA(LIGHT_POWER_FACTOR_ID, R, FLOAT32), OBJ_FIELD_DATA(LIGHT_COLOUR_ID, RW, STRING), OBJ_FIELD_DATA(LIGHT_SENSOR_UNITS_ID, R, STRING), };
  • 17. LEADING COLLABORATION IN THE ARM ECOSYSTEM Instance-specific data declarations /* Initialize instance resource data. */ INIT_OBJ_RES_DATA(res[avail], i, LIGHT_ON_OFF_ID, &on_off_value[avail], sizeof(*on_off_value)); INIT_OBJ_RES_DATA(res[avail], i, LIGHT_DIMMER_ID, &dimmer_value[avail], sizeof(*dimmer_value)); [...] INIT_OBJ_RES_DATA(res[avail], i, LIGHT_SENSOR_UNITS_ID, units[avail], LIGHT_STRING_SHORT);
  • 18. LEADING COLLABORATION IN THE ARM ECOSYSTEM Application level /* Resource initialization */ lwm2m_engine_set_string("3/0/0", CLIENT_MANUFACTURER); lwm2m_engine_set_string("3/0/1", CLIENT_MODEL_NUMBER); [...] /* Engine startup */ ret = lwm2m_rd_client_start(&client, CONFIG_NET_APP_PEER_IPV6_ADDR, CONFIG_LWM2M_PEER_PORT, CONFIG_BOARD, rd_client_event);
  • 19. LEADING COLLABORATION IN THE ARM ECOSYSTEM End to End Demo System ● Control an LED and do a FOTA update via LWM2M ● Canned Docker containers and build system glue to get moving quickly ● http://ltd-docs.readthedocs.io/ en/ltd-17.09/iotfoundry/lwm2m -howto.html
  • 20. LEADING COLLABORATION IN THE ARM ECOSYSTEM How to play with the Zephyr LWM2M Client locally ● Download the latest Leshan Demo Server build and start ○ $ wget https://hudson.eclipse.org/leshan/job/leshan/lastSuccessfulBuild/artifact/ leshan-server-demo.jar ○ $ java -jar ./leshan-server-demo.jar ○ Open a web browser to: http://localhost:8080 ● Run the Zephyr LWM2M Client via QEMU ○ Follow “Getting Started” Guide ○ Follow “Networking with QEMU” Docs ○ $ make -C samples/net/lwm2m_client run
  • 21. LEADING COLLABORATION IN THE ARM ECOSYSTEM Zephyr LWM2M Roadmap In Zephyr v1.9 ● LWM2M Engine to manage registering smart object and handling read/write/create/delete operations. ● Registration device client state machine (DTLS not supported yet) ● 4 OMA LWM2M objects: Security, Server, Device and Firmware ● Support for firmware update via both direct resource write and pull via URL resource. Coming in the future ● Migrate to new Zephyr CoAP APIs. ● LWM2M Engine to support DTLS. ● Registration client to support bootstrap state machine. ● Add more OMA standard smart objects: Access Controls, Location … ● Add more IPSO Smart Objects. ● Optimization!