This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Talking to nrf52840 secure bootloader via UART: Timeout if Application Image is around 178228 B (or greater)

Our Setup

  • STM32 Chip (master) connected to nRF52840 (slave) via UART
  • STM32 is supposed to update the application on nRF52840
  • nRF52840 runs the secure UART bootloader from SDK 15.3.0
  • application updates are running smooth so far with Application sizes around 80KB
  • current status: we are in production stage with a serious amount of devices sold and shipped

Our Problem

When the application reaches around 178228 B (or beyond) the master suddenly receives a communication timeout when trying to update an application.

Details:

  • timeout on master occurs on the last package of the application transfer, when we are expecting a response to OBJET_EXECUTE (0x04)
  • retrying on master side has no effect: timeout all the time

Question

Looking at the nRF52840 debug output the bootloader seems to do what is expected. But Why the timeout after the transmission of the last package? And what does it have to do with this seemingly arbitrary number of 178228 Bytes?

Update

I attached the full log of the nRF52840 Bootloader as well as the result of 

nrfjprog --recover --log

[2021-Mar-08 11:01:05] [ info] --------------------------------------------------------------------------------
[2021-Mar-08 11:01:05] [ info] nrfjprog --recover --log 
[2021-Mar-08 11:01:05] [ info] nrfjprog version 10.10.0 
[2021-Mar-08 11:01:05] [ info] --------------------------------------------------------------------------------
[2021-Mar-08 11:01:05] [debug] [ nRF0x0] - open_dll
[2021-Mar-08 11:01:05] [debug] [ nRF0x0] - Load library at /opt/nrfjprog/libjlinkarm_unknown_nrfjprogdll.so.
[2021-Mar-08 11:01:05] [debug] [ nRF0x0] - Library loaded, loading member functions.
[2021-Mar-08 11:01:05] [debug] [ nRF0x0] - Member functions succesfully loaded.
[2021-Mar-08 11:01:05] [debug] [Backend] - Logger callback at 0x55708435be00 registered in Segger backend logger.
[2021-Mar-08 11:01:05] [debug] [  JLink] - [Debug   ] [JLink     ] Logger callback at 0x55708435be00 registered in JLink logger.
[2021-Mar-08 11:01:05] [debug] [nRFUnknown] - Just_open_dll_tagged_callback
[2021-Mar-08 11:01:05] [debug] [Backend] - open_dll
[2021-Mar-08 11:01:05] [debug] [Backend] - No J-Link DLL path was provided. Attempting to auto detect.
[2021-Mar-08 11:01:05] [debug] [Backend] - Load library at /opt/SEGGER/JLink/libjlinkarm.so.
[2021-Mar-08 11:01:05] [debug] [Backend] - Library loaded, loading member functions.
[2021-Mar-08 11:01:05] [debug] [Backend] - Member functions succesfully loaded.
[2021-Mar-08 11:01:05] [debug] [Backend] - dll_version
[2021-Mar-08 11:01:05] [debug] [Backend] - Segger dll version 6.86.g loaded.
[2021-Mar-08 11:01:05] [debug] [Backend] - set_core_data
[2021-Mar-08 11:01:05] [debug] [ nRF0x0] - enum_emu_snr
[2021-Mar-08 11:01:05] [debug] [nRFUnknown] - Just_enum_emu_snr
[2021-Mar-08 11:01:05] [debug] [Backend] - enum_emu_snr
[2021-Mar-08 11:01:05] [debug] [Backend] - ---just_enum_emu_snr
[2021-Mar-08 11:01:05] [debug] [Backend] - ---just_get_num_emus
[2021-Mar-08 11:01:05] [debug] [ nRF0x0] - connect_to_emu_with_snr
[2021-Mar-08 11:01:05] [debug] [nRFUnknown] - Just_connect_to_emu_with_snr
[2021-Mar-08 11:01:05] [debug] [Backend] - connect_to_emu_with_snr
[2021-Mar-08 11:01:05] [debug] [Backend] - is_connected_to_emu
[2021-Mar-08 11:01:05] [debug] [Backend] - ---just_enum_emu_snr
[2021-Mar-08 11:01:05] [debug] [Backend] - ---just_get_num_emus
[2021-Mar-08 11:01:06] [debug] [Backend] - ---just_connect_to_emu_with_snr
[2021-Mar-08 11:01:06] [debug] [Backend] - ---just_connect_to_emu_without_snr
[2021-Mar-08 11:01:06] [debug] [Backend] - Segger logging enabled.
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] Firmware: J-Link OB-SAM3U128-V2-NordicSemi compiled Mar 17 2020 14:43:00
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] Hardware: V1.00
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] S/N: 683148846
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] OEM: SEGGER
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] Feature(s): RDI, FlashBP, FlashDL, JFlash, GDB
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] TELNET listener socket opened on port 19021
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] WEBSRV Starting webserver
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] WEBSRV Webserver running on local port 19080
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] - 2.978ms returns "O.K."  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_HasError()  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_GetHWStatus(...)  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] - 0.224ms returns 0  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_HasError()  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_ExecCommand("SetRestartOnClose = 0", ...).   
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] - 0.003ms returns 0x01  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_HasError()  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_ExecCommand("DisableFlashDL", ...).   
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] - 0.002ms returns 0x00  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_HasError()  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_ExecCommand("ExcludeFlashCacheRange 0x0-0xFFFFFFFF", ...).   
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] - 0.002ms returns 0x00  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_HasError()  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_SetHookUnsecureDialog  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_SetHookUnsecureDialog(...)
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] - 0.010ms returns 0  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_HasError()  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_TIF_Select(JLINKARM_TIF_SWD)  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] - 0.522ms returns 0x00  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_HasError()  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_SetSpeed(2000)  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] - 0.033ms  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_HasError()  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_GetSN()  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] - 0.005ms returns 683148846  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_HasError()  
[2021-Mar-08 11:01:06] [debug] [Backend] - ---just_load_core_data
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_ExecCommand("CORESIGHT_SetIndexAHBAPToUse = 0", ...).   
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] - 0.002ms returns 0x00  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_HasError()  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_ExecCommand("device = Cortex-M4", ...).   
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] XML file found at: /opt/SEGGER/JLink/JLinkDevices.xml 
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] /opt/SEGGER/JLink/JLinkDevices.xml evaluated successfully. 
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] Device "CORTEX-M4" selected.
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] - 13.724ms returns 0x00  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_HasError()  
[2021-Mar-08 11:01:06] [debug] [ nRF0x0] - read_connected_emu_snr
[2021-Mar-08 11:01:06] [debug] [nRFUnknown] - Just_read_connected_emu_snr
[2021-Mar-08 11:01:06] [debug] [Backend] - read_connected_emu_snr
[2021-Mar-08 11:01:06] [debug] [Backend] - is_connected_to_emu
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_IsOpen()  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] - 0.006ms returns 0x01  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_HasError()  
[2021-Mar-08 11:01:06] [debug] [ nRF0x0] - read_device_family
[2021-Mar-08 11:01:06] [debug] [nRFUnknown] - Just_read_device_family
[2021-Mar-08 11:01:06] [debug] [Backend] - is_connected_to_emu
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_IsOpen()  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] - 0.005ms returns 0x01  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_HasError()  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_Lock()  
[2021-Mar-08 11:01:06] [debug] [Backend] - read_debug_port_idr
[2021-Mar-08 11:01:06] [debug] [Backend] - read_debug_port_register
[2021-Mar-08 11:01:06] [debug] [Backend] - ---just_read_debug_port_register
[2021-Mar-08 11:01:06] [debug] [Backend] - coresight_configure
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_CORESIGHT_Configure()  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] - 100.485ms returns 0  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_HasError()  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_CORESIGHT_ReadAPDPReg(DP reg 0x00)  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] failed
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] - 0.812ms returns -1  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_HasError()  
[2021-Mar-08 11:01:06] [debug] [Backend] - JLinkARM.dll reported "-1", an unknown error.
[2021-Mar-08 11:01:06] [debug] [Backend] - ---just_abort_debug_action
[2021-Mar-08 11:01:06] [debug] [Backend] - Attempting to clear any configuration errors in debug port before closing connection. 
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_CORESIGHT_WriteAPDPReg(DP reg 0x00, 0x0000001F)  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] - 0.828ms returns -1  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_HasError()  
[2021-Mar-08 11:01:06] [debug] [Backend] - JLinkARM.dll reported "-1", an unknown error.
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] - 0.020ms  
[2021-Mar-08 11:01:06] [debug] [ nRF0x0] - close_dll
[2021-Mar-08 11:01:06] [debug] [nRFUnknown] - Just_close_dll
[2021-Mar-08 11:01:06] [debug] [Backend] - close
[2021-Mar-08 11:01:06] [debug] [Backend] - disconnect_from_emu
[2021-Mar-08 11:01:06] [debug] [Backend] - is_connected_to_emu
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_IsOpen()  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] - 0.009ms returns 0x01  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_HasError()  
[2021-Mar-08 11:01:06] [debug] [Backend] - ---just_disconnect_from_emu
[2021-Mar-08 11:01:06] [debug] [Backend] - is_connected_to_device
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_IsConnected()  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] - 0.010ms returns FALSE  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_HasError()  
[2021-Mar-08 11:01:06] [debug] [Backend] - ---just_is_debug_region_powered
[2021-Mar-08 11:01:06] [debug] [Backend] - ---just_read_debug_port_register
[2021-Mar-08 11:01:06] [debug] [Backend] - is_connected_to_emu
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_IsOpen()  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] - 0.009ms returns 0x01  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_HasError()  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_Lock()  
[2021-Mar-08 11:01:06] [debug] [Backend] - ---just_write_debug_port_register
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_CORESIGHT_WriteAPDPReg(DP reg 0x02, 0x00000000)  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] - 0.815ms returns -1  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_HasError()  
[2021-Mar-08 11:01:06] [debug] [Backend] - JLinkARM.dll reported "-1", an unknown error.
[2021-Mar-08 11:01:06] [debug] [Backend] - ---just_abort_debug_action
[2021-Mar-08 11:01:06] [debug] [Backend] - Attempting to clear any configuration errors in debug port before closing connection. 
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_CORESIGHT_WriteAPDPReg(DP reg 0x00, 0x0000001F)  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] - 0.760ms returns -1  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_HasError()  
[2021-Mar-08 11:01:06] [debug] [Backend] - JLinkARM.dll reported "-1", an unknown error.
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] - 0.014ms  
[2021-Mar-08 11:01:06] [debug] [  JLink] - [Debug   ] [JLink     ] JLINK_Close()  
[2021-Mar-08 11:01:06] [debug] [Backend] - Segger Backend closed.



STM32 Slip Log:

...
page done, continuing
Serial: Streaming Data: len:1072 offset:176128 crc:0x01b83350
SLIP: --> [08, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, e8, 2d, 00, 20, 23, 2d, 30, 2b, 20, 00, 00, 00, 68, 6c, 4c, 00, 65, 66, 67, 45, 46, 47, 00, 00, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 41, 42, 43, 44, 45, 46]
SLIP: --> [08, 00, 00, 00, 00, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 61, 62, 63, 64, 65, 66, 00, 00, 00, 00, 00, 00, 00, 00, b5, 89, 02, 00, 00, 00, 00, 00, 11, 8f, 02, 00, 00, 00, 00, 00, 95, c4, 02, 00, 00, 00, 00, 00, 7d, dd, 02, 00, 14, 40, 00, 20, 61, e0, 02, 00]
SLIP: --> [08, 00, 00, 00, 00, 13, dd, 02, 00, 14, 40, 00, 20, a9, de, 02, 00, 00, 00, 00, 00, 79, fa, 02, 00, 00, 00, 00, 00, fd, 07, 03, 00, fc, 3e, 00, 20, 4f, f1, 02, 00, 14, 3f, 00, 20, 09, aa, 02, 00, 00, 00, 00, 00, 1e, a1, 04, 00, 00, 00, 00, 00, 24, a1, 04, 00]
SLIP: --> [08, 00, 00, 00, 00, 3a, a1, 04, 00, 00, 00, 00, 00, 6d, b5, 04, 00, 00, 00, 00, 00, 2b, a1, 04, 00, 00, 00, 00, 00, 64, b5, 04, 00, 00, 00, 00, 00, 77, b5, 04, 00, 00, 00, 00, 00, 68, b5, 04, 00, 00, 00, 00, 00, 71, b5, 04, 00, 00, 00, 00, 00, 2f, a1, 04, 00]
SLIP: --> [08, 00, 00, 00, 00, 34, a1, 04, 00, 00, 00, 00, 00, 21, 99, 04, 00, 00, 00, 03, 03, 8e, b2, 04, 00, 00, 00, 00, 00, 80, a6, 04, 00, 00, 00, 03, 03, 12, a1, 04, 00, 00, 00, 00, 00, 0b, ab, 04, 00, 00, 00, 03, 03, fb, 9b, 04, 00, 00, 00, 03, 03, bc, b2, 04, 00]
SLIP: --> [08, 00, 00, 03, 03, 40, b5, 04, 00, 00, 00, 03, 03, 58, b5, 04, 00, 00, 00, 03, 03, 0f, ae, 04, 00, 00, 00, 03, 03, 26, a9, 04, 00, 00, 00, 03, 03, e9, aa, 04, 00, 00, 00, 03, 03, fb, aa, 04, 00, 00, 00, 03, 03, 47, ad, 04, 00, 00, 00, 03, 03, ba, ab, 04, 00]
SLIP: --> [08, 00, 00, 03, 03, 7e, b2, 04, 00, 00, 00, 03, 03, f8, b0, 04, 00, 00, 00, 03, 03, 14, 9c, 04, 00, 00, 00, 00, 00, 1a, a1, 04, 00, 00, 00, 00, 00, c8, 2e, 00, 20, 90, 2f, 00, 20, 98, 2f, 00, 20, d0, 2e, 00, 20, 18, 00, 00, 00, 5d, 8a, 02, 00, 00, 00, 00, 00]
SLIP: --> [08, 8d, 8f, 02, 00, 00, 00, 00, 00, 11, 91, 02, 00, 00, 00, 00, 00, 85, 0a, 03, 00, 00, 00, 00, 00, d1, 0c, 03, 00, 00, 00, 00, 00, fd, 88, 02, 00, 00, 00, 00, 00, ac, 36, 00, 20, 68, 36, 00, 20, 40, 00, 00, 00, 01, 00, 00, 00, 00, 00, 00, 00, e4, 98, 04, 00]
SLIP: --> [08, 00, 00, 00, 00, f0, 98, 04, 00, 5c, 2c, 00, 20, 7c, 50, fd, 7f, 01, 00, 00, 00, 00, 00, 00, 00, 00, 20, 00, 40, 00, 00, 00, 00, 00, 20, 00, 40, 00, 00, 00, 00, 00, 00, 00, 00, ff, 00, 00, 00, 00, 90, d0, 03, ff, ff, ff, ff, 01, 01, 00, 18, 00, 00, 00, 00]
SLIP: --> [08, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, ff, ff, 06, 00, 0c, 00, 00, 00, 80, 0c, ff, ff, 08, ff, ac, fd, 01, 00, 00, 00, 00, 06, 9a, 2c, 00, 20, 01, 00, 00, 00, 9c, 2c, 00, 20, 00, 00, 00, 00]
SLIP: --> [08, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 38, 2d, 00, 20, 01, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 6c, 42, 00, 20, 1f, 00, 00, 00, 8b, 42, 00, 20, 1f, 00, 00, 00, 02, 00, 00, 00, 00, 00, 00, 00]
SLIP: --> [08, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 2c, 2d, 00, 20, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 01, 00, 00, 00, 3f, 04, 00, 00, 0c, 00, 00, 00]
SLIP: --> [08, aa, 42, 00, 20, ac, fd, 00, 00, 0a, 00, 00, 00, b6, 42, 00, 20, ff, ff, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, ff, 01, 00, 00, 01, 00, 00, 00, 00, 00, 00, 00]
SLIP: --> [08, 01, 00, 00, 00, 01, 00, 00, 00, 64, 00, 00, 00, 01, 00, 00, 00, e8, 03, 00, 00, 03, 00, 00, 00, 98, 2d, 00, 20, 03, 00, 00, 00, a8, 2d, 00, 20, 00, 00, 00, 00, 00, 01, 00, 00, e8, 03, 00, 00, ff, 1f, a1, 07, 01, 00, 00, 00, 00, 01, 00, 00, 00, 00, 00, 00]
SLIP: --> [08, e8, 03, 00, 00, 5a, 05, 02, 00, 00, 02, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 18, 18, 18, 18, 18, 18, 18, 18, 00, e8, 2d, 00, 20, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00]
SLIP: --> [08, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00]
SLIP: --> [08, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 69, 62, 02, 00, 41, 62, 02, 00, 00, 00, 00, 00, 00, 00, 00, 00, 09, 7c, 02, 00, 00, 00, 00, 00, 00, 00, 00, 00]
SLIP: --> [03]
SLIP: <-- [60, 03, 01, 30, b4, 02, 00, ee, ab, af, a7]
SLIP: --> [04]
... timeout occurs here

nRF52840 Bootloader debug output

...
 nrf_dfu_serial_uart: Allocated buffer 20002758
 nrf_dfu_req_handler: Handle NRF_DFU_OP_OBJECT_WRITE (data)
 nrf_dfu_flash: nrf_fstorage_write(addr=0x00058B80, src=0x200027E0, len=64 bytes), queue usage: 1
 nrf_dfu_flash: Flash write success: addr=0x00058B80, pending 0
 nrf_dfu_req_handler: Request handling complete. Result: 0x1
 nrf_dfu_serial_uart: Allocated buffer 200027DC
 nrf_dfu_req_handler: Handle NRF_DFU_OP_OBJECT_WRITE (data)
 nrf_dfu_serial_uart: Allocated buffer 200027DC
 nrf_dfu_flash: nrf_fstorage_write(addr=0x00058BC0, src=0x2000275C, len=32 bytes), queue usage: 1
 nrf_dfu_flash: Flash write success: addr=0x00058BC0, pending 0
 nrf_dfu_req_handler: Request handling complete. Result: 0x1
 nrf_dfu_req_handler: Handle NRF_DFU_OP_CRC_GET (data)
 nrf_dfu_req_handler: Offset:207840, CRC:0x01C081E3
 nrf_dfu_req_handler: Request handling complete. Result: 0x1
 nrf_dfu_serial: Sending Response: [0x3, 0x1]
 nrf_dfu_serial_uart: Allocated buffer 200027DC
 nrf_dfu_req_handler: Handle NRF_DFU_OP_OBJECT_EXECUTE (data)
 nrf_dfu_req_handler: Whole firmware image received. Postvalidating.
 nrf_dfu_validation: Hash verification. start address: 0x26000, size: 0x32BE0
 nrf_dfu_validation: Invalidating old application in bank 0.
 nrf_dfu_serial: Sending Response: [0x4, 0x1]
 nrf_dfu_settings: Writing settings...
 nrf_dfu_settings: Erasing old settings at: 0x000FF000
 nrf_dfu_flash: nrf_fstorage_erase(addr=0x0x000FF000, len=1 pages), queue usage: 1
 nrf_dfu_flash: Flash erase success: addr=0x000FF000, pending 0
 nrf_dfu_flash: nrf_fstorage_write(addr=0x000FF000, src=0x20002950, len=896 bytes), queue usage: 1
 nrf_dfu_flash: Flash write success: addr=0x000FF000, pending 0
 nrf_dfu_settings: Backing up settings page to address 0xFE000.
 nrf_dfu_settings: Writing settings...
 nrf_dfu_settings: Erasing old settings at: 0x000FE000
 nrf_dfu_flash: nrf_fstorage_erase(addr=0x0x000FE000, len=1 pages), queue usage: 1
 nrf_dfu_flash: Flash erase success: addr=0x000FE000, pending 0
 nrf_dfu_flash: nrf_fstorage_write(addr=0x000FE000, src=0x20002CD0, len=896 bytes), queue usage: 1
 nrf_dfu_flash: Flash write success: addr=0x000FE000, pending 0
 nrf_dfu_req_handler: All flash operations have completed. DFU completed.
 app: Shutting down transports (found: 1)
 app: Resetting bootloader.

Full Log:

6567.bl.log

Related