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

OTA over serial failure| sdk 15.2

Hello Everyone,

I am using nrf52832 and sdk 15.2 for ota over serial. I have made bootloader for OTA over UART and tested same with nrfutil using my dfu package file. firmware is upgraded successfully and  working fine.

Now I need to upgrade firmware using host MCU. I tried sending dfu package file( .zip ) to nrf52832 over UART using slip librairy to upgrade firmware but it is not working.

Is there any compulsion to send Ping packet, PNR, MTU Packet, init packet, application and bootloader separately over UART?

Can we send directly dfu package created through nrfutil to nrf52832 from other MCU over UART?

Kindly suggest me right approach.

Parents
  • Hi ,

    What is the minimum MBR size we can use for OTA?

    I am using 4096 for now. I want to reduce it.

  • What parameter are you talking about, exactly? What is it called?

  • Hello,

    Sorry for the late reply. When a ticket has a verified answer, it falls out of the system, because the issue is solved.

     

    Somesh Burkule said:
    can we use this to 2048 or 1024?

     Why?

     

    Somesh Burkule said:

    one more question... As I saw in sdkconfig of uart secure bootloader, there is option to use DFU over BLE.

    Can we use single bootloader for DFU over Serial and BLE both?

     It is possible. You have to add the other transport layer. It is usually done by just including the .c and .h files to the project, as the transport layers are registered through some macros from those. Then, from main() -> nrf_bootloader_init() -> nrf_dfu_init() -> nrf_dfu_transports_init() it will fetch the list of registered transport layers.

    In the BLE bootloader, the BLE transport layer is included by the following define in nrf_dfu_ble.c:

    DFU_TRANSPORT_REGISTER(nrf_dfu_transport_t const ble_dfu_transport) =
    {
        .init_func  = ble_dfu_transport_init,
        .close_func = ble_dfu_transport_close,
    };

    And it is done similarly in the serial bootloader. Search for "DFU_TRANSPORT_REGISTER" in the project.

    BR,

    Edvin

  • NB: I manually changed the status of the ticket, so it will pop up when you write something again.

  •  Why?

    I am downloading dfu files from server. so if speed is slow ota will fail or I'll need to get file saved in 4Kb packets.

    Is it possible 2048? any impact?

    It is possible.

    does it work independently? or need some other setting while DFU over Serial or BLE? or need to only enter in boot mode?

  • Make sure to decide whether you want to go down this way as well, and maybe it is easier to create a new ticket? This is no longer related to "OTA over serial failure", which the title reads on this ticket.

     

    Somesh Burkule said:
    I am downloading dfu files from server. so if speed is slow ota will fail or I'll need to get file saved in 4Kb packets.

     Ok. Set it to 1kB then. Does it change the behavior? Do you run into any issues? I don't see why it shouldn't work, but I don't know what your bootloader project looks like, so perhaps you have made some changes that would affect this.

     

    Somesh Burkule said:
    does it work independently? or need some other setting while DFU over Serial or BLE? or need to only enter in boot mode?

     It works independently, but you don't want to do DFU over Serial and BLE at the same time. If you start with serial, then you finish that DFU with Serial. Don't to BLE simultaneously. But it is possible to support both protocols.

    The only thing to keep in mind while using BLE is that your application must always use the same softdevice version as your bootloader uses. Because your bootloader needs to use the same SD api as the softdevice that is programmed. So if you update the softdevice version, you must update the bootloader as well.

  • Ok. I'll try with reducing size.

    It works independently, but you don't want to do DFU over Serial and BLE at the same time. If you start with serial, then you finish that DFU with Serial. Don't to BLE simultaneously. But it is possible to support both protocols.

    Nice.

    Thanks for your support.

    I'm closing this now.

Reply Children
No Data
Related