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

Firmware not starting after DFU

Hello, I have the following question. I'm trying to program my firmware via DFU Bootloader and nRF Connect (smartphone). That works perfectly with the test board SparkFun nRF52832 Breakout. But if I do the same with my own hardware, the firmware won't start. The upload goes perfectly, but DFU will start again in two seconds. If the firmware is flashed without a DFU, it works without a problem. It looks like the problem is with the hardware. But I compared everything and found no mistake. What could be causing the error in the hardware that does not allow the flashed firmware to start?

SDK_17.0.0_9d13099, nRF52832

Schematic board SparkFun


Thanks in advance

Parents
  • Hello,

    I don't know what sort of bootloader you are using, but please check out the equvialent _debug project, such as:

    SDK\examples\dfu\secure_bootloader\pca10040_uart_debug

    And monitor the RTT log. What does it say? When the DFU is finished, but it restarts in DFU mode, does the RTT log say anything about why the DFU mode was re-entered?

    What changes did you do to the bootloader project? Have you tested a bootloader from an unmodified SDK?

    Best regards,

    Edvin

  • Thank you for your prompt reply. I use nRF5_SDK_17.0.0_9d13099 \ examples \ dfu \ secure_bootloader \ pca10040_s132_ble as the bootloader. I've only commented out the functions for LEDs and #include "boards.h" from the example. RTT log shows nothing during update:

    LOG: J-Link RTT Viewer V6.92: Logging started.
    LOG: Connecting to J-Link via USB...
    LOG: Device "NRF52832_XXAA" selected.
    LOG: InitTarget() start
    LOG: InitTarget() end
    LOG: Found SW-DP with ID 0x2BA01477
    LOG: DPv0 detected
    LOG: Scanning AP map to find all available APs
    LOG: AP[2]: Stopped AP scan as end of AP map has been reached
    LOG: AP[0]: AHB-AP (IDR: 0x24770011)
    LOG: AP[1]: JTAG-AP (IDR: 0x02880000)
    LOG: Iterating through AP map to find AHB-AP to use
    LOG: AP[0]: Core found
    LOG: AP[0]: AHB-AP ROM base: 0xE00FF000
    LOG: CPUID register: 0x410FC241. Implementer code: 0x41 (ARM)
    LOG: Found Cortex-M4 r0p1, Little endian.
    LOG: FPUnit: 6 code (BP) slots and 2 literal slots
    LOG: CoreSight components:
    LOG: ROMTbl[0] @ E00FF000
    LOG: ROMTbl[0][0]: E000E000, CID: B105E00D, PID: 000BB00C SCS-M7
    LOG: ROMTbl[0][1]: E0001000, CID: B105E00D, PID: 003BB002 DWT
    LOG: ROMTbl[0][2]: E0002000, CID: B105E00D, PID: 002BB003 FPB
    LOG: ROMTbl[0][3]: E0000000, CID: B105E00D, PID: 003BB001 ITM
    LOG: ROMTbl[0][4]: E0040000, CID: B105900D, PID: 000BB9A1 TPIU
    LOG: ROMTbl[0][5]: E0041000, CID: B105900D, PID: 000BB925 ETM
    LOG: RTT Viewer connected.

    What should I activate in order for the RTT log to say something?

Reply
  • Thank you for your prompt reply. I use nRF5_SDK_17.0.0_9d13099 \ examples \ dfu \ secure_bootloader \ pca10040_s132_ble as the bootloader. I've only commented out the functions for LEDs and #include "boards.h" from the example. RTT log shows nothing during update:

    LOG: J-Link RTT Viewer V6.92: Logging started.
    LOG: Connecting to J-Link via USB...
    LOG: Device "NRF52832_XXAA" selected.
    LOG: InitTarget() start
    LOG: InitTarget() end
    LOG: Found SW-DP with ID 0x2BA01477
    LOG: DPv0 detected
    LOG: Scanning AP map to find all available APs
    LOG: AP[2]: Stopped AP scan as end of AP map has been reached
    LOG: AP[0]: AHB-AP (IDR: 0x24770011)
    LOG: AP[1]: JTAG-AP (IDR: 0x02880000)
    LOG: Iterating through AP map to find AHB-AP to use
    LOG: AP[0]: Core found
    LOG: AP[0]: AHB-AP ROM base: 0xE00FF000
    LOG: CPUID register: 0x410FC241. Implementer code: 0x41 (ARM)
    LOG: Found Cortex-M4 r0p1, Little endian.
    LOG: FPUnit: 6 code (BP) slots and 2 literal slots
    LOG: CoreSight components:
    LOG: ROMTbl[0] @ E00FF000
    LOG: ROMTbl[0][0]: E000E000, CID: B105E00D, PID: 000BB00C SCS-M7
    LOG: ROMTbl[0][1]: E0001000, CID: B105E00D, PID: 003BB002 DWT
    LOG: ROMTbl[0][2]: E0002000, CID: B105E00D, PID: 002BB003 FPB
    LOG: ROMTbl[0][3]: E0000000, CID: B105E00D, PID: 003BB001 ITM
    LOG: ROMTbl[0][4]: E0040000, CID: B105900D, PID: 000BB9A1 TPIU
    LOG: ROMTbl[0][5]: E0041000, CID: B105900D, PID: 000BB925 ETM
    LOG: RTT Viewer connected.

    What should I activate in order for the RTT log to say something?

Children
No Data
Related