Renesas RYZ014 Application Note
Hide thumbs Also See for RYZ014:

Advertisement

Quick Links

RYZ014
Firmware Over-the-Air Upgrade
Contents
1.
Introduction ................................................................................................................................ 2
2.
Definitions .................................................................................................................................. 2
3.
FOTA Overview ......................................................................................................................... 2
4.
FOTA on LwM2M ...................................................................................................................... 2
4.1
Architecture ............................................................................................................................................. 2
4.2
Overview .................................................................................................................................................. 3
4.3
FOTA Activation During Manufacturing ................................................................................................... 3
4.3.1
Start the LwM2M Client on the Module ................................................................................................. 4
4.3.2
Adding the Device to the Inventory ....................................................................................................... 6
4.3.3
Register the Device ............................................................................................................................... 9
4.4
Manage the Client on the Server........................................................................................................... 10
4.4.1
Preparation .......................................................................................................................................... 11
4.4.2
Upload the Image on the Server ......................................................................................................... 11
4.5
FOTA Procedure ................................................................................................................................... 12
4.5.1
Overview .............................................................................................................................................. 12
4.5.2
Detailed FOTA Procedure ................................................................................................................... 14
4.5.3
Verify ................................................................................................................................................... 15
4.6
Low Power Considerations .................................................................................................................... 16
4.7
Troubleshooting ..................................................................................................................................... 16
4.7.1
Wrong FOTA Image ............................................................................................................................ 16
5.
FOTA with AT Commands ....................................................................................................... 16
6.
Appendix: AT Commands Description ..................................................................................... 17
6.1
AT+SQNFOTACFG: FOTA Configuration ............................................................................................. 17
6.1.1
Syntax .................................................................................................................................................. 17
6.1.2
Description........................................................................................................................................... 17
6.1.3
Defined Values .................................................................................................................................... 18
6.2
AT+SQNDMCFG: Device Management ................................................................................................ 18
6.2.1
Service Syntax .................................................................................................................................... 19
6.2.2
Server Syntax ...................................................................................................................................... 19
6.2.3
PSK Syntax ......................................................................................................................................... 20
6.2.4
delete-profile-config ............................................................................................................................. 20
6.3
AT+SQNDMCFG: LwM2M Registration Status .................................................................................... 21
6.3.1
Syntax .................................................................................................................................................. 21
6.3.2
Defined values ..................................................................................................................................... 21
Jan.31.23
Application Note
Page 1 of 24

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the RYZ014 and is the answer not in the manual?

Questions and answers

Summary of Contents for Renesas RYZ014

  • Page 1: Table Of Contents

    Application Note RYZ014 Firmware Over-the-Air Upgrade Contents Introduction ..........................2 Definitions ..........................2 FOTA Overview ......................... 2 FOTA on LwM2M ........................2 Architecture ............................. 2 Overview ..............................3 FOTA Activation During Manufacturing ....................3 4.3.1 Start the LwM2M Client on the Module ....................4 4.3.2...
  • Page 2: Introduction

    Examples ............................. 22 Revision History ..........................24 1. Introduction This document details the FOTA mechanisms supported on RYZ014. It is also possible to perform local firmware upgrade using the UART connection. See the Software Upgrade Procedure application note for more details.
  • Page 3: Overview

    RYZ014 Firmware Over-the-Air Upgrade Figure 1. FOTA Process The OEM is responsible for performing modem provisioning during end-device manufacturing (see section 10) and for ‘on-board’ modem information to FOTA service provider (see). The OEM also qualifies and approves the updated software and launches the FOTA operation.
  • Page 4: Start The Lwm2M Client On The Module

    RYZ014 Firmware Over-the-Air Upgrade Figure 2. FOTA Service Process on a Specific Device 4.3.1 Start the LwM2M Client on the Module The FOTA client on each module must be provided the following information: • The endpoint URI:  For example, coaps://eu.iot.avsystem.cloud:5694 •...
  • Page 5 RYZ014 Firmware Over-the-Air Upgrade 4.3.1.2 Device Configuration Once the keys are generated, the PSK key and the bootstrap server information must be written to the device. Then the LwM2M service must be enabled. In the following table, the module is assumed to be running in ‘standard’ operating mode.
  • Page 6: Adding The Device To The Inventory

    RYZ014 Firmware Over-the-Air Upgrade 4.3.2 Adding the Device to the Inventory This section assumes the existence of an AVSystem account for the feature, and the availability of an access to the Coiote IoT Device Management. After logging to the Coiote IoT Device Management, go to Device Inventory: Figure 3.
  • Page 7 RYZ014 Firmware Over-the-Air Upgrade Note: Use the ‘Search’ field to check if an Endpoint with the same name is already registered. If so, delete it to use the new PSK identities. Choose ‘via the Bootstrap server’ option: Figure 6. Choosing Option for Connecting through the Bootstrap Server Enter the client’s endpoint name, security mode, key identity and PSK key in hexadecimal format:...
  • Page 8 RYZ014 Firmware Over-the-Air Upgrade Choose ‘This Coiote DM Management Server PSK’ option, then click the ‘Add device’ button: Figure 8. Choosing ‘Coiote DM Management Server PSK’ Option Confirm the device creation. Figure 9. Confirming the Device Creation Click on the ‘Go to device’ button to advance to the Bootstrap profile management page: Figure 10.
  • Page 9: Register The Device

    RYZ014 Firmware Over-the-Air Upgrade Click the ‘Go to the previous version’ to revert to a previous, more stable version of the web interface (if need be). Figure 11. Going to the Previous Version of the Web Interface 4.3.3 Register the Device In the example below, the LwM2M client is configured in ‘Auto’...
  • Page 10: Manage The Client On The Server

    RYZ014 Firmware Over-the-Air Upgrade 4.4 Manage the Client on the Server Go to the Operation center tab on the Coiote IoT Device Management server. The dashboard shows the number of activated devices (1 in this case). The device’s characteristics are listed in the table: Figure 12.
  • Page 11: Preparation

    Figure 15. Checking the Client Registration in the Device Management Mode 4.4.1 Preparation Get the official differential image delivered by Renesas or generate one following the instructions given in the RYZ014 System Integration Guide. In this chapter, the sample images are to_LOWER_FFF_PXL.bin which downgrades from LR5.4.1.1-57857 to LR5.4.1.1-57830, and to_HIGHER_FFF_PXL.bin which upgrades from LR5.4.1.1-57830 to LR5.4.1.1-...
  • Page 12: Fota Procedure

    RYZ014 Firmware Over-the-Air Upgrade Click on ‘Upload file’, select the differential dup image and then click on ‘save’ to upload it. Figure 17. Uploading the Differential dup Image Select the uploaded file, choose the image delivery method and delivery protocol, then click on Upgrade to begin FOTA procedure.
  • Page 13 RYZ014 Firmware Over-the-Air Upgrade Figure 19. Modem Initiated FOTA Upgrade Procedure The host application must process every URCs to ensure it does not power off the modem while the upgrade package is being installed. 4.5.1.2 Network Initiated Query Once the FOTA client is activated, the server can contact the FOTA client running on the modem and ask it to check if any upgrade package is available using the process detailed below: Figure 20.
  • Page 14: Detailed Fota Procedure

    RYZ014 Firmware Over-the-Air Upgrade 4.5.2 Detailed FOTA Procedure The LwM2M client Auto mode is configured as shown above. When using Auto mode, the device performs everything automatically, including triggering a FOTA check by FOTA update timer, downloading an image if available and installing it.
  • Page 15: Verify

    RYZ014 Firmware Over-the-Air Upgrade Command Response Comment Reconnected to the network +CEREG: 1,"0002", "01A2D002",7 You can also follow the progress on the ‘LwM2M firmware’ tab on the server side. Figure 21. Viewing Upgrade Progress on the Server 4.5.3 Verify After a successful FOTA upgrade/downgrade, the firmware version can be checked on the client side using...
  • Page 16: Low Power Considerations

    Users need to operate the following steps to upgrade the firmware: • Get differential firmware image from Renesas. • Put the differential firmware image on FTP or HTTP/S server •...
  • Page 17: Appendix: At Commands Description

    RYZ014 Firmware Over-the-Air Upgrade 6. Appendix: AT Commands Description 6.1 AT+SQNFOTACFG: FOTA Configuration 6.1.1 Syntax Command Response AT+SQNFOTACFG=<upg_profile>[,<mode> [,<report_state>[,<report_download> ERROR [,<fota_timer_sec>[,<download_to_sec> +CME ERROR: <err> [,<certificateID>]]]]]] +SQNFOTACFG: 32[,(0,1)[,(0-2)[,(0-100) [,(60-32000000)[,(60-65535)[,(11- AT+SQNFOTACFG=? 19)]]]]]]] +SQNFOTACFG: <upg_profile>,<mode>, <report_state>,<report_download>, <fota_timer_sec_requested>, AT+SQNFOTACFG? <fota_timer_sec_actual>, <download_to_sec>,<certificateID> 6.1.2 Description This command is used to configure FOTA client behavior.
  • Page 18: Defined Values

    RYZ014 Firmware Over-the-Air Upgrade The user can control the maximum FOTA client radio activity duration using the above timers, which may be mandatory if the device power supply architecture is only compatible with time-limited activity period. FOTA client configuration is stored in non-volatile memory and is preserved at reboot or during a software upgrade.
  • Page 19: Service Syntax

    RYZ014 Firmware Over-the-Air Upgrade 6.2.1 Service Syntax Command Possible Response(s) AT+SQNDMCFG=<dmProfile>[,<cfgGrp>[,… ]] +CME ERROR: <err> AT+SQNDMCFG=<dmProfile>,"service" [,<autostart>] ERROR AT+SQNDMCFG=<dmProfile>,"service" +SQNDMCFG=<dmProfile>,"service", <autostart> ERROR AT+ SQNDMCFG=? +SQNDMCFG=(32),"service"[,(0,1)] [...] +SQNDMCFG=(32),"server"[,(1- 65535),,(256)[,[(1-8)[,(bs,dm)]]]] This subcommand command is used to configure the autostart of FOTA service. If no <autostart> is provided, the response tells if the service is currently auto-started.
  • Page 20: Psk Syntax

    RYZ014 Firmware Over-the-Air Upgrade 6.2.2.1 Defined values • <dmProfile> (string): Device management server profile name (max. length 32 characters) • <cfgGrp> (string): Device management configuration group identification  "service": service main configuration  "server": Device management server configuration  "psk": pre-shared key (PSK) provisioning •...
  • Page 21: At+Sqndmcfg: Lwm2M Registration Status

    RYZ014 Firmware Over-the-Air Upgrade 6.2.4.1 Defined values • <dmProfile> (string): Device management server profile name (max. length 32 characters) • <cfgGrp> (string): "delete-profile-config": deletes the entire configuration profile 6.3 AT+SQNDMCFG: LwM2M Registration Status This command provides LwM2M Bootstrap and Device Management servers registration status. It can be used to trigger de-registration in order to save battery.
  • Page 22 RYZ014 Firmware Over-the-Air Upgrade 6.3.3 Examples AT+SQNDMST +SQNDMST: "bs",100,"BS_HOLD_OFF",10,7 +SQNDMST: "dm",101,"DEREGISTERED",86400,86397 The bootstrap process is delayed by the carrier’s hold off timer. It will start in 7 seconds. AT+SQNDMST +SQNDMST: "bs",100,"BS_INITIATED",10,-1 +SQNDMST: "dm",101,"DEREGISTERED",86400,86363 The bootstrap process is under way. The <bs Status> string can take other values during the bootstrap process.
  • Page 23 RYZ014 Firmware Over-the-Air Upgrade The bootstrap process was successful: • Server 102 registration was successful. Registration update period is 30 days (2,592,000 seconds). The next registration update is scheduled in 2,587,603 s. • Server 101 registration was successful. Registration update period is 24 h. The next registration update is scheduled in 81,965 s.
  • Page 24 RYZ014 Firmware Over-the-Air Upgrade Revision History Description Rev. Date Page Summary 1.00 Jan.31.23 Initial release R19AN0214EU0100 Rev.1.00 Page 24 of 24 Jan.31.23...
  • Page 25: General Precautions In The Handling Of Microprocessing Unit And Microcontroller Unit Products

    Unit Products The following usage notes are applicable to all Microprocessing unit and Microcontroller unit products from Renesas. For detailed usage notes on the products covered by this document, refer to the relevant sections of the document as well as any technical updates that have been issued for the products.
  • Page 26: Corporate Headquarters

    Renesas Electronics disclaims any and all liability for any damages or losses incurred by you or any third parties arising from the use of any Renesas Electronics product that is inconsistent with any Renesas Electronics data sheet, user’s manual or other Renesas Electronics document.

Table of Contents