Mbed cli 2: target.mbed_app_start not honored

I am trying to build + run the blinky application on an Adafruit nrf52840 feather with an unmanaged boot loader “UF2”. I am failing to move the target.mbed_app_start address to 0x26000 as it is required by UF2 on this board. Although specifying an “mbed_app.json” with the required content, mbed is always creating the app image with flash start address 0.

Details:

I am following the installation instructions on Install or upgrade - Build tools | Mbed OS 6 Documentation and imported the * mbed-os-example-blinky demo project.

Initially I am using the board NRF52840_DK as the adafruit feather board is pretty similar.

Now, although adding a file “mbed_app.json” to the blinky root directory. The “.text” start address of the resulting image is always “0x0”.

mbed_app.json:

{ 
	"target_overrides": { 
		"*": { 
			"target.mbed_app_start" : "0x26000"
		} 
	} 
}

after “mbed-tool compile -m NRF52840_DK -t GCC_ARM” I always get “cmake_build/NRF52840_DK/develop/GCC_ARM/mbed-os/targets/TARGET_NORDIC/TARGET_NRF5x/TARGET_NRF52/TARGET_MCU_NRF52840/mbed-mcu-nrf52840.link_script.ld” with this content:

MEMORY
{
  FLASH (rx) : ORIGIN = 0x0, LENGTH = 0x100000
  RAM_NVIC (rwx) : ORIGIN = 0x20000000, LENGTH = 0x100
  RAM_CRASH_DATA (rwx) : ORIGIN = (0x20000000 + 0x100), LENGTH = 0x100
  RAM (rwx) : ORIGIN = ((0x20000000 + 0x100) + 0x100), LENGTH = (0x40000 - (0x100 + 0x100))
}
...

I would have expected “FLASH (rx) : ORIGIN = 0x26000”.

With mbed cli 1 this worked out of the box. Why not with mbed cli 2? Am I doing something wrong?

see

Perfect! Thanks ladislas. Too bad that cli 2 does not support it (yet?) but at least there is a workaround.

Regards
Jörg