Hello,
Version - nrf Connect SDK v2.7.0
We have our own project which, I believe, has correctly configured signing using a custom key file.
In VSCode I've created a new configuration using our custom board. I always set the option 'Use sysbuild'. In the project folder resides two files related to sysbuild and mcuboot:
- sysbuild.conf with two KConfig options:
- sysbuild/mcuboot.conf with additional bootloader configuration
Program compiles and produces firmware:
/build/mcuboot/zephyr/zephyr.hex etc.
/build/app_name/zephyr/zephyr.elf etc
/build/app_name/zephyr/zephyr.signed.bin
/build/app_name/zephyr/zephyr.signed.hex
/build/merged.hex
All seems to be on place.
The signing key seem to be ok, in the terminal this line with my custom key appears: MCUBoot bootloader key file: D:/WSN/...../sign_key.pem
In our application logging is redirected to RTT and UART is used for communication with custom terminal app. The dtsi and dts files for our custom board are for the most part the same as for nRF52840 DK (including default uart but with another RX TX pins assigned, respectively 31 and 29).
Using jflash I am able to run the application programming all the combinations including the these three files:
/build/mcuboot/zephyr/zephyr.bin
/build/app_name/zephyr/zephyr.signed.bin
/build/merged.hex
Application is written at the address 0xC000
Bootloader is written at the address 0x0
Two things:
- MCUBoot does not copy the newer firmware from slot 1 to slot 0 for booting. When I program slot 1 (0x82000) with /build/app_name/zephyr/zephyr/zephyr.signed.bin with the next version, the application with older version immediately pops up after a reset. When I program slot 0 (0x82000) with /build/app_name/zephyr/zephyr/zephyr.signed.bin with the next version, the application with newer version immediately pops up after a reset. Why doesn't the MCUBoot copy the newer firmware to the booting slot? What am I missing.
- I have not messages from MCUBoot. How to enable bootloader logging? Can you provide a tip how to do that? I've been trying it for a while traversing the various guides including devzone but with no luck.