Files created size

I found the plugin for vs code beautiful and easy to use.
my curiosity was born from the fact that I made the comparison with the file created by i’de adrduino that smaller, why?
the ide are installed without having made any changes.

For what board? What code? Version of the Arduino IDE? Is the board support package up to date / same version as PlatformIOs? (i.e. for ESP8266… core 2.5.0 or 2.4.2 for both, etc).

Can I just double check that you mean the Arduino IDE output is smaller?

There can sometimes be minor variations due to the exact compiler settings and how well the compiler optimises things… but they should be pretty much the same.

For a simple blinky sketch for the Arduino Uno, they are absolutely identical.

NUCLEO-64 STM32f103RB and stm32f103c8t6

Ok, since you’re on the STM32 platform… you’ll either be using the stm32duino core, or the rogerclarke maple core. The rogerclarke core builds generally include a bootloader, the stm32duino core doesn’t (although they are in the process of adding one).

Because it’s newer, and officially supported by STMicroelectronics, the stm32duino core is used by default. However, it doesn’t have the DFU bootloader, so there’s no easy auto resetting upload, etc, but the code is a lot smaller because the bootloader is missing.

Basically, depending on whether you used board = nucleo_f103rb or board = genericSTM32F103RB in your platformio.ini will change how the build works, and whether you can switch between the stm32duino core and maple core using board_build.core = maple

nucleo_f103rb (default stm32duino core)

DATA:    [          ]   4.5% (used 912 bytes from 20480 bytes)
PROGRAM: [=         ]   8.5% (used 11180 bytes from 131072 bytes)

Making it pretty much the same as that of the Arduino IDE with v1.5.0 of the stm32duino board support package:

Sketch uses 11324 bytes (8%) of program storage space. Maximum is 131072 bytes.
Global variables use 912 bytes (4%) of dynamic memory, leaving 19568 bytes for local variables. Maximum is 20480 bytes.

nucleo_f103rb (maple core via board_build.core = maple)

DATA:    [==        ]  20.9% (used 4272 bytes from 20480 bytes)
PROGRAM: [==        ]  15.3% (used 19996 bytes from 131072 bytes)

Which doesn’t really tally up with the Arduino IDE using the rogerclark core and STM Nucleo F103RB… so I don’t know what’s happening here…note also there is a difference in maximum sizes, so I don’t think this is a proper comparision… something is still configured diferently.

Sketch uses 12920 bytes (11%) of program storage space. Maximum is 108000 bytes.
Global variables use 2456 bytes (14%) of dynamic memory, leaving 14544 bytes for local variables. Maximum is 17000 bytes.