Documentation

Mistake on this page? Email us

Device Management Client 1.5.0 General Availability (GA)

Changes since the previous release

  • A new callback to track notification and delayed post response delivery statuses.

    • Added API M2MBase::set_message_delivery_status_cb(message_delivery_status_cb callback, void *client_args);.
  • The following APIs are marked as deprecated as the new API replaces them. They will be removed in subsequential client relases.

    • M2MBase::send_notification_delivery_status(const M2MBase& object, const NotificationDeliveryStatus status)
    • M2MBase::get_notification_msgid()
    • M2MBase::set_notification_msgid(uint16_t msgid)
    • M2MBase::set_notification_delivery_status_cb(notification_delivery_status_cb callback, void *client_args)
    • M2MBase::get_notification_delivery_status()
    • M2MBase::clear_notification_delivery_status()
  • Added an API to get the internal object list of Device Management Client.

    • MbedCloudClient::get_object_list()
  • Added Firmware Update over CoAP into Device Management Client.

    • You can download the firmware using HTTP by setting the flag update-download_protocol to MBED_CLOUD_CLIENT_UPDATE_DOWNLOAD_PROTOCOL_HTTP. This is the default configuration.
    • To Download using CoAP in MbedOS, set the flag in the "target_overrides" section of the mbed_app.json file as follows:

    "mbed-cloud-client.update-download-protocol": "MBED_CLOUD_CLIENT_UPDATE_DOWNLOAD_PROTOCOL_COAP".

  • Optimized the static RAM usage by reusing the static object ManifestManagerContext during the client initialization.

  • Implemented resume firmware download after a connection failure.

  • Merged two branches of Device Management Update client to one and added profile and feature flags to separate between different feature sets. A new profile flag ARM_UC_PROFILE_MBED_CLOUD_CLIENT is used to enable the correct profile for Device Management Client.

  • Improved the registration flow in Device Management Client by sending the initial meta data of the device as part of the registration message. This reduces the data traffic between the client and cloud.

  • Introduced PAL_DNS_API_VERSION for handling DNS.

    • 0 = synchronous DNS (Device Management Client example default for all network interfaces other than Mesh and Thread on Mbed OS).
    • 1 = asynchronous DNS.
    • 2 = asynchronous DNS v2 (Device Management Client example only with Mbed OS 5.9 or later, used with Thread and Mesh).
  • The error FCC_STATUS_STORE_ERROR is returned upon an internal storage initialization failure.

Fixes

Device Management Client

  • Fixed offset by 1 error in MbedCloudClient class set_device_resource_value API, which sets the manufacturer and model number value in the Device Object (/3).
  • Fixed the usage of GNU-specific pthread_sigqueue, which is a GNU-specific extension, to make Device Management Client portable over other flavours of C libraries. For example, OpenWrt uses the musl c library.
  • Fixed reconnection of lost connection to Device Management.
  • Fixed compile time warnings related to PAL_INT_FLASH_NUM_SECTIONS on non-reference Mbed OS boards.
  • Fixed reconnection logic on client when Device Management responds with "service unavailable".
  • Fixed memory leak that occurred when sending a notification during the reconnection sequence.
  • Fixed overwriting of Manufacturer and Model number by Update component.

Device Management Update Client

  • Fixed RTL8195 flash R/W issue by adding FlashIAP Init call into initialization.
  • Fixed long HTTP headers handling logic to support headers to split to multiple fragments.
  • Fixed Device Management Update Client versioning to work in factory flow.
  • Fixed Update state machine failure which was noticed when traces were enabled. The notification state machine was changed to sequentially wait for the internal asynchronous operations to complete before sending updated resource values to service and waiting for an acknowledgment from service.
  • Changed uninitialization for Device Management Update Client to be done for all states past initialization states. Added null-checks for resource value settings.

Platform Adaptation Layer (PAL)

  • Fixed Coverity issues in PAL.
  • Improved error handling and logging for network and storage.
  • Fixed PAL tracing implementation to allow an application to override the tracing level definitions.
  • In pal_isLeapYear, fixed a bug that made the certificate times off by a day.
  • Enforced usage of MTU limits when using DTLS and PAL_UDP_MTU_SIZE is defined.
  • [LINUX] Improved logging for RNG generation.
  • [LINUX] The glibc-specific function pthread_sigqueue() was replaced with pthead_kill().
  • [LINUX] Increased the stack size of PAL_NOISE_TRNG_THREAD to 32k and PAL_NET_TEST_ASYNC_SOCKET_MANAGER_THREAD_STACK_SIZE to 24k.
  • [LINUX] Added a socket event filter clearing for pal_plat_connect() and pal_plat_asynchronousSocket().
  • [Mbed OS] Define PAL_USE_INTERNAL_FLASH and PAL_INT_FLASH_NUM_SECTIONS is 2 by default for all targets.
  • [Mbed OS] Compatibility changes for Mbed OS 5.10.
  • [Mbed OS] Fixed a compatibility issue with Mbed TLS 2.13.0 for ARMCC compiler.

Device Management Client example

  • Added configurations for the K66F target board.
  • Added a hardcoded RoT injection when the application is configured to use the developer mode. This preserves the Device Management Client credentials even when SOTP is erased (for example due to reflashing of the application binary).
  • Updated to Mbed OS 5.9.6.
  • Updated easy-connect to v1.2.16.
  • Updated the storage selector with compiler warning fixes in the internal libraries.
  • Replaced the notification delivery status functionality with a more generic message delivery status callback.
  • Added an example on using the delayed response for execute operations.

Known issues

Occasionally, when downloading the firmware using the MBED_CLOUD_CLIENT_UPDATE_DOWNLOAD_PROTOCOL_COAP configuration, the client can show an error UpdateWarningURINotFound or UpdateWarningUnknown and the update campaign stops. You will see Invalid asset URI as a device event in the Portal. A workaround for this issue is to start a new update campaign.

Mbed OS

We recommend searching the issue list in the Mbed OS repository for known issues and their latest status.

  • UDP mode with NUCLEO-F411RE is not working.
  • NUCLEO-F411RE compiled with IAR does not connect.
  • UBLOX EVK Odin W2 does not work with IAR compiled binaries, Mbed OS issue #7137.
  • UBLOX EVK Odin W2 does not work with release and debug profiles.
  • K64F with Thread hard faults (imprecise data access error, in event_core_write) when compiling with ARM CC compiler.
  • DTLS handshake fails on ublox ODIN-W2, issue #6545.
  • Mbed OS 5.9 increases memory consumption compared to Mbed OS 5.8.

Linux

  • Firmware update from one Linux distribution version to another does not work. For example, firmware update from Yocto distribution Morty to Rocko is not currently possible, as there are Linux version-dependent files (device tree) in the BOOT partition. Therefore, updates need to be done within one major version of a distribution.
  • glibc versions 2.23 and 2.24 have a bug in thread creation. It can cause random crashes with Linux.
    • If possible, update glibc to version 2.25 (or newer). See the sourceware issue 20116 for details.
    • We have implemented a workaround for this issue to decrease its likelihood. This issue may still occur in certain circumstances.
  • The Device Management Client application must run as root to have access rights to perform the firmware update.
    • This is not the most secure way to handle this issue and a more secure implementation will come later.
  • Yocto distribution has only been tested in the developer certificate mode.

Device Management Client 1.5.0 Third Party IP report

Device Management Client uses some open source Third Party IP (TPIP). This table lists the TPIPs whose sources we included:

Original License Description
cn-cbor MIT factory configurator client uses cn-cbor: A constrained node implementation of CBOR in C, with slight modifications. The code is located in mbed-cloud-client/factory-configurator-client/secsrv-cbor.
Unity MIT Platform Adaptation Layer (PAL) tests use Unity framework from ThrowTheSwitch. The code is located in mbed-cloud-client/mbed-client-pal/Test/Unity.

You do also get more TPIP via Mbed OS release itself (for example lwIP and FATFS).