Hello,
We are using nRFSDK v15.0.0 and nRF52840 in our system. There is also an external MCU that is connected to the nRF52840 via UART. Currently we are trying to perform a FW upgrade on the external MCU using the Nordic DFU. The Nordic DFU simply forwards the External app image to the external MCU via UART using YModem protocol.
After the nRF52840 sends the external image packet, it waits for an ACK from the external MCU before responding to the nrfutil. We are using nrf_serial_read/write synchronous (polling) method. Since the erase times of the flash on the external MCU is in order of 4-5 seconds, the nRF52840 does not get an ACK for this time and hence cannot respond to the nrfutil which causes the nrfutil to timeout.
We experimented with "-t" argument in the nrfutil dfu serial, but this is not making any difference except when the nrfutil starts (before progress bar is displayed).
- Is there any way we can configure the timeout parameter so that nrfutil does not timeout? Like a response timeout for a command sent from the nrfutil.
- Are there any retries built into the nrfutil? For example, if there is no response from the DFU target, will the nrfutil send the packet again? Dont see anything based on RTT logs on the DFU target side.
- Also, since we are using synchronous nrf_serial, the nrf_serial_read keeps blocking and does not timeout when no characters are received from the external MCU. We are aware of the deadlock situation that is in API documentation and we are not calling the nrf_serial_read() inside a app_timer timeout handler or any other ISR. The nrf_serial_read is called inside the API implementation for the nrf_dfu_flash_write methods. We created a separate interface (nrf_fstorage_extmcu, similar to nrf_fstorage_nvmc) and we call the nrf_serial_write/read inside the write method to send this out to external mcu. Not sure, what could be wrong. Looking at the call stack, this is called from app_scheduler context inside loop_forever().
- We see that nrf_serial is not present in the SDK v17.x. So, is this not supported? If we were to migrate to latest SDK in future, nrf_serial will not be available anymore?
Here's the call stack (for item 3 above)

p_rx-timer is always active.
