Why does `copy & paste` work but cli `mbed compile -f` does not?

  • When I flash an ST custom board with an ST-Link programmer/debugger (e.g. cut off a NUCLEO board) using the copy & paste method then it works.
  • But when I try to program the same custom board using the mbed cli mbed compile -f ... command then it isn’t flashed (“066F” not found in platform database). This method also fails when I try to program an officially supported mbed board with an ST-Link programmer/debugger which has been cut off the board but then reconnect with wires.
  • However, when I start to debug the same custom or official mbed board offline by providing the .elf file then the board is flashed correctly.