Beware that this post is related to an SDK in maintenance mode
More Info: Consider nRF Connect SDK for new designs
This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

DFU from iPhone SE fails

Our application is based on nRF5 SDK 17.0.2, 52832, and buttonless secure DFU without bonds. It works fine with the windows nrfconnect app but when testing various phones we get problems:
iPhone SE: always fails
OnePlus Nord: fails sometimes
iPad Pro, iPad Mini, Huawei P30 Lite, Samsung S10e, S20: works fine

Mode of these failures is the same. The init packet and every data object is transferred, crc is read back correct on all (compared to a good sequence), but final signature check fails because data was corrupted on some objects after receive. This happens sometimes but not always when starting a flash write on a new object before the last object flash write is finished. There seems to be something wrong with the data flow in the bootloader.

Parents
  • Hi,

    Are you using a custom app to do the DFU? And are you using the IOS-Pods-DFU-Library library?

    We have seen such issues from time to time, and often it is if data arrives too fast compared to the time it takes to write to flash. Typically this can be solved by reducing the BLE packet size (say down to 23) and/or using PRN with a lower number.

  • So far we are using the ios nrfconnect app. The flash write requests are queued and use separate write buffers, so it shouldnt be a problem if some writes take a long time, but you are right, this is the problem.

    Do you mean NRF_SDH_BLE_GATT_MAX_MTU_SIZE 23 in the bootloader ?

    What is PRN ?

  • Hi,

    sjerlhagen said:
    So far we are using the ios nrfconnect app.

    I see. Then there is no way you can tweek this.

    sjerlhagen said:
    Do you mean NRF_SDH_BLE_GATT_MAX_MTU_SIZE 23 in the bootloader ?

    You can do it in the bootloader, yes. And it would be a good test to see if it works. But my original thought was to do it in your app, assuming it was a custom app (which I now understand is not the case).

    sjerlhagen said:
    What is PRN ?

     This is Packet Receipt Notification, which is a concept in the DFU protocol. It can be used as a form of flow control mechanism.

    I assume this is the 2020 version of the iPhone SE, right? Which version of iOS and nRF Connect are you using?

Reply
  • Hi,

    sjerlhagen said:
    So far we are using the ios nrfconnect app.

    I see. Then there is no way you can tweek this.

    sjerlhagen said:
    Do you mean NRF_SDH_BLE_GATT_MAX_MTU_SIZE 23 in the bootloader ?

    You can do it in the bootloader, yes. And it would be a good test to see if it works. But my original thought was to do it in your app, assuming it was a custom app (which I now understand is not the case).

    sjerlhagen said:
    What is PRN ?

     This is Packet Receipt Notification, which is a concept in the DFU protocol. It can be used as a form of flow control mechanism.

    I assume this is the 2020 version of the iPhone SE, right? Which version of iOS and nRF Connect are you using?

Children
Related