52840 USB Dongle and DFU (OTA) example

Looking for an example to adapt into my program.

I detect 'smp_svr' but compiling it give me error, it seems I need a flash configuration in file pm_static.yml, but I have no idea on how to do  it.
One example - just to see if everything is OK for my intentions - will be appreciate. 

Same result using 3.2.1 or 2.8.0 SDK

Thanks in andvace

Parents
  • Hi,

    What is the end goal? I ask because the nRF52840 Dongle is special in the sense that it ships with an nRF5 SDK USB bootloader. As you want OTA (which is a bit odd on a dongle) I suspect you are using it as a development platform? If so, I would recommend that you use a development kit instead. That has a debugger, and importantly, does not have the existing nRF5 SDK bootloader that complicates things when developing other bootloaders.

    The default device tree memory layout for nRF52840 dongle acomodates the MBR (which is the immutable part of the nRF5 SDK bootloadser), as it places MCUboot at 0x1000 instead 0x0, but you will need to add a pm_static.yml for this yourself. You can see an example here.

    If you are using an external debugger to program the nRF52840 dongle you can remove the bootloader that is on the device, so that it would be like any other nRF52840 device without the old nRF5 SDK bootloader and MBR. Then you would also need to modify the board files, most importantly remove FLASH_LOAD_OFFSET og set it to 0 as well as the dts (you can copy the memory related configurations from the nRF52840 DK in that case as that will be identical).

  • Thanks Einar for clarifications.
    And yes, my company used some USB donbgle for fast developing, and I've embed this inside the box.

    Due to the FW upgrade I would like develop the OTA on this dongle. My idea was a double bootloader: the USB launch the OTA bootloader and so on... IT seems weird but is my idea, because I can't reopen the box and program the dongle with a JTAG, only USB connector is reachable.

    Now I'm adapting a connector for the JTAG and try to modify one dongle (I have 10 of them... !) . Fot the finale version (on a Nordic chip on a PCB) I plan to buy a dev kit.

    Now I have undestand why pm_static seems too complicate.

    Thanks again.

    Massimo alias TheRaptus.

Reply
  • Thanks Einar for clarifications.
    And yes, my company used some USB donbgle for fast developing, and I've embed this inside the box.

    Due to the FW upgrade I would like develop the OTA on this dongle. My idea was a double bootloader: the USB launch the OTA bootloader and so on... IT seems weird but is my idea, because I can't reopen the box and program the dongle with a JTAG, only USB connector is reachable.

    Now I'm adapting a connector for the JTAG and try to modify one dongle (I have 10 of them... !) . Fot the finale version (on a Nordic chip on a PCB) I plan to buy a dev kit.

    Now I have undestand why pm_static seems too complicate.

    Thanks again.

    Massimo alias TheRaptus.

Children
No Data
Related