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

problem with MCUboot

Hi,

As I understand Nordic NCS now supports nRF52 development for nrf52832/40/11/10, so based on this I am trying to make a simple application for nRF5232 chip (peripheral_uart) with mcuboot and eventually enable DFU over BLE for the device. 

Currently, I have a problem building application with CONFIG_BOOTLOADER_MCUBOOT=y

Build fails when it starts to build MCUBOOT. This is the output from command: west build -p always -b nrf52_pca10040

Fullscreen
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
-- west build: build configuration:
source directory: /home/voja/Documents/irnas/ncs/nrf/samples/usb/usb_uart_bridge
build directory: /home/voja/Documents/irnas/ncs/nrf/samples/usb/usb_uart_bridge/build
BOARD: nrf52840_pca10090 (origin: command line)
-- west build: generating a build system
-- Zephyr version: 2.1.99
-- Selected BOARD nrf52840_pca10090
-- Found west: /home/voja/.virtualenvs/zephyenv/bin/west (found suitable version "0.6.3", minimum required is "0.6.0")
-- Loading /home/voja/Documents/irnas/ncs/zephyr/boards/arm/nrf52840_pca10090/nrf52840_pca10090.dts as base
Devicetree configuration written to /home/voja/Documents/irnas/ncs/nrf/samples/usb/usb_uart_bridge/build/zephyr/include/generated/devicetree.conf
Parsing /home/voja/Documents/irnas/ncs/zephyr/Kconfig
/home/voja/Documents/irnas/ncs/nrf/lib/fprotect/Kconfig:20: WARNING: dt_int_val is deprecated.
/home/voja/Documents/irnas/ncs/bootloader/mcuboot/zephyr/Kconfig:37: WARNING: dt_int_val is deprecated.
Loaded configuration '/home/voja/Documents/irnas/ncs/zephyr/boards/arm/nrf52840_pca10090/nrf52840_pca10090_defconfig'
Merged configuration '/home/voja/Documents/irnas/ncs/nrf/samples/usb/usb_uart_bridge/prj.conf'
Configuration saved to '/home/voja/Documents/irnas/ncs/nrf/samples/usb/usb_uart_bridge/build/zephyr/.config'
-- The C compiler identification is GNU 8.3.1
-- The CXX compiler identification is GNU 8.3.1
-- The ASM compiler identification is GNU
-- Found assembler: /home/voja/Documents/gcc-arm-none-eabi-8-2019-q3-update/bin/arm-none-eabi-gcc
-- Cache files will be written to: /home/voja/.cache/zephyr
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

 

I was able to build the MCUboot separately, but as I understand this should be done automatically and added to the application when I have CONFIG_BOOTLOADER_MCUBOOT=y in prj.conf file. 

I have the latest release (v1.2.0) of NCS on Ubuntu 18.04

Is there something I am missing?

Best regards,
Vojislav

  • My goal is to do the FOTA over BLE on nRF52811 device, like stated in documentation:
    https://developer.nordicsemi.com/nRF_Connect_SDK/doc/latest/nrf/ug_nrf52.html#fota-upgrades

    Best regards,
    Vojislav

  • I have the same problem when trying to compile the USB_UART_BRIDGE example which has MCUBOOT enabled by default. When I run the command: west build -b nrf52840_pca20035 I get the response:


    Fullscreen
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    -- west build: build configuration:
    source directory: /home/voja/Documents/irnas/ncs/nrf/samples/usb/usb_uart_bridge
    build directory: /home/voja/Documents/irnas/ncs/nrf/samples/usb/usb_uart_bridge/build (created)
    BOARD: nrf52840_pca20035 (origin: command line)
    -- west build: generating a build system
    -- Zephyr version: 2.1.99
    -- Found PythonInterp: /home/voja/.virtualenvs/zephyenv/bin/python (found suitable version "3.6.9", minimum required is "3.6")
    -- Selected BOARD nrf52840_pca20035
    -- Found west: /home/voja/.virtualenvs/zephyenv/bin/west (found suitable version "0.6.3", minimum required is "0.6.0")
    -- Loading /home/voja/Documents/irnas/ncs/nrf/boards/arm/nrf52840_pca20035/nrf52840_pca20035.dts as base
    Devicetree configuration written to /home/voja/Documents/irnas/ncs/nrf/samples/usb/usb_uart_bridge/build/zephyr/include/generated/devicetree.conf
    Parsing /home/voja/Documents/irnas/ncs/zephyr/Kconfig
    /home/voja/Documents/irnas/ncs/nrf/lib/fprotect/Kconfig:20: WARNING: dt_int_val is deprecated.
    /home/voja/Documents/irnas/ncs/bootloader/mcuboot/zephyr/Kconfig:37: WARNING: dt_int_val is deprecated.
    Loaded configuration '/home/voja/Documents/irnas/ncs/nrf/boards/arm/nrf52840_pca20035/nrf52840_pca20035_defconfig'
    Merged configuration '/home/voja/Documents/irnas/ncs/nrf/samples/usb/usb_uart_bridge/prj.conf'
    Configuration saved to '/home/voja/Documents/irnas/ncs/nrf/samples/usb/usb_uart_bridge/build/zephyr/.config'
    -- The C compiler identification is GNU 8.3.1
    -- The CXX compiler identification is GNU 8.3.1
    -- The ASM compiler identification is GNU
    -- Found assembler: /home/voja/Documents/gcc-arm-none-eabi-8-2019-q3-update/bin/arm-none-eabi-gcc
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    Best regards,
    Vojislav

  • I don't have any issues compiling these projects in NCS v1.2 with CONFIG_BOOTLOADER_MCUBOOT=y

    From the error-message, it looks like some old/stale build files are causing this issue.

    Try to delete the build folder in ncs\mcuboot\boot\zephyr , or run git clean -fxd in ncs\mcuboot
    If that does not work, try to clean your "/home/voja/.cache/zephyr" folder.

  • Thank you for your reply, git clean -fxd did the job!

    Best regards,
    Vojislav