PlatformIO Community

Mbed framework builds wrong binary?

A couple of days ago I was programming the Nucleo L476 RG in the mbed framework (ST STM32 framework-mbed @ 6.60200.200722). Everything was working oké for dozens of times but then pio suddenly responded that it couldn’t upload the compiled code. I do not remember updating or changing settings. If I look in the .pio directory I do see that a .elf file is built with a far too large size (I expect 40kB but get an .elf of 1.5MB). If I use the online mbed compiler it builds a .bin that can be uploaded to the board without a problem. So, the board is oke, the program is oké, the problem seems to be that platformio suddenly started building the wrong file (large .elf instead of small .bin). How is this possible? Did I unintentionally change some setting?

platform.ini:

[env:nucleo_l476rg]
platform = ststm32
board = nucleo_l476rg
framework = mbed