Newcomer can't get VS Code to run

VSCode is finished!
Basically the same error (“CC” is written wrong or can not be found…) but
the error in case of full path to c_cpp_properties.json is now clean!
The only error left is in the main.cpp - #include <Arduino.h> is marked as error!
Shall I send you the full error message?

Does pressing Build button now invoke pio run and the whole PlatformIO subsystem?

Is building going through successfully?

Can you do a RebuildIntelliSense again?

And if that doesn’t work, show the full VSCode screenshot with errors.

1 Like

Hi Max,
thanks for being back!
So starting “build” is working with error (… “CC” written wrong …)!
I have done a RebuildIntellisense with error.
Following is the screenshot and the full error message!
I cross my fingers that you can find something!
Hans

> Executing task in folder Marlin-2.0.7.2-SKR-E3-DIP: C:\Users\elli\.platformio\penv\Scripts\pio.exe init --ide vscode <


The current working directory C:\B-Marlin\Marlin-2.0.7.2-SKR-E3-DIP will be used for the project.

The next files/directories have been created in C:\B-Marlin\Marlin-2.0.7.2-SKR-E3-DIP
include - Put project header files here
lib - Put here project specific (private) libraries
src - Put project source files here
platformio.ini - Project Configuration File
Error: Processing STM32F103RC_btt_USB (platform: ststm32@~6.1; board: genericSTM32F103RC; framework: arduino)
----------------------------------------------------------------------------------------------------------------------------------------------------Verbose mode can be enabled via `-v, --verbose` option
Der Befehl "CC" ist entweder falsch geschrieben oder
konnte nicht gefunden werden.
CalledProcessError: Command 'CC -DTARGET_STM32F1 -D__MARLIN_FIRMWARE__ -DHAVE_SW_SERIAL -DTONE_CHANNEL=4 -DDEBUG_LEVEL=0 -DSS_TIMER=4 -DUSE_USB_COMPOSITE -D__MARLIN_DEPS__ -w -dM -E -x c++ buildroot/share/PlatformIO/scripts/common-dependencies.h' returned non-zero exit status 1.:
  File "C:\users\elli\.platformio\penv\lib\site-packages\platformio\builder\main.py", line 168:
    env.SConscript(item, exports="env")
  File "C:\Users\elli\.platformio\packages\tool-scons\scons-local-4.0.1\SCons\Script\SConscript.py", line 598:
    return _SConscript(self.fs, *files, **subst_kw)
  File "C:\Users\elli\.platformio\packages\tool-scons\scons-local-4.0.1\SCons\Script\SConscript.py", line 287:
    exec(compile(scriptdata, scriptname, 'exec'), call_stack[-1].globals)
  File "C:\B-Marlin\Marlin-2.0.7.2-SKR-E3-DIP\buildroot\share\PlatformIO\scripts\common-dependencies.py", line 286:
    apply_features_config()
  File "C:\B-Marlin\Marlin-2.0.7.2-SKR-E3-DIP\buildroot\share\PlatformIO\scripts\common-dependencies.py", line 118:
    if not env.MarlinFeatureIsEnabled(feature):
  File "C:\Users\elli\.platformio\packages\tool-scons\scons-local-4.0.1\SCons\Environment.py", line 219:
    return self.method(*nargs, **kwargs)
  File "C:\B-Marlin\Marlin-2.0.7.2-SKR-E3-DIP\buildroot\share\PlatformIO\scripts\common-dependencies.py", line 262:
    load_marlin_features()
  File "C:\B-Marlin\Marlin-2.0.7.2-SKR-E3-DIP\buildroot\share\PlatformIO\scripts\common-dependencies.py", line 250:
    define_list = subprocess.check_output(cmd, shell=True).splitlines()
  File "C:\Users\elli\.platformio\python3\lib\subprocess.py", line 411:
    **kwargs).stdout
  File "C:\Users\elli\.platformio\python3\lib\subprocess.py", line 512:
    output=stdout, stderr=stderr)
============================================================ [FAILED] Took 1.33 seconds ============================================================
Environment          Status    Duration
-------------------  --------  ------------
STM32F103RC_btt_USB  FAILED    00:00:01.334
====================================================== 1 failed, 0 succeeded in 00:00:01.334 ====================================================== 

The terminal process "C:\Users\elli\.platformio\penv\Scripts\pio.exe 'init', '--ide', 'vscode'" terminated with exit code: 1.

Terminal will be reused by tasks, press any key to close it.

…I think I might have a clue on what’s going on. A special marlin script might prevent you from building anything at this moment.

When reading through the code at BIGTREETECH-SKR-E3-DIP-V1.0/Firmware/Marlin-2.0.7.2-SKR-E3-DIP/buildroot/share/PlatformIO/scripts/common-dependencies.py at fd6c9dec3a7849ee84c39da49b9bd5088dc9a518 · bigtreetech/BIGTREETECH-SKR-E3-DIP-V1.0 · GitHub and especially the related function search_compiler it looks like it’s trying to invoke the GCC compiler of the system to invoke it with some special command. If you don’t have one installed, it will fail. If true, this script in Marlin is extremely bad written since it assumes you just have gcc available in your path.

Now there are two ways to test this, and let’s try one after the other.

First, install MinGW64 on your computer using http://mingw-w64.org/doku.php/download/mingw-builds. The default installation settings will suffice.

The program will install in a path of e.g. C:\Program Files\mingw-w64\x86_64-8.1.0-posix-seh-rt_v6-rev0\mingw64\bin(<-- only an example, search your own in C:\Program Files\mingw-w64). In that path, there should be the gcc executable.

The folder in which this gcc executable resides must now be added to the PATH. To do this, right click on “This computer” in the Windows explorer window and go to the last item “Properties”.

A window will open that, if wide enough, reveals “Advanced System settings” on the right side.

grafik

In there, click the button “Environment variables”.

grafik

Edit the “PATH” variable in System variables, not the user variables.

Use the “New” button to the folder in which gcc resides to the system’s PATH environment variables.

Press “OK” on all dialogs until everythings closed.

Restart your computer. Then, open a Windows terminal (Windows + R → cmd.exe) and execute gcc --version. It should output something like

gcc (x86_64-posix-seh-rev0, Built by MinGW-W64 project) 8.1.0
Copyright (C) 2018 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

If not, you have not added the correct path to the PATH variable.

If all is good, re-open VSCode with the Marlin project and try to re-initialize the project again. Does it work now?

The second way would be by going into the platformio.ini of the Marlin project, gotoing to the [env:STM32F103RC_btt_USB ] environment and adding the line

custom_gcc = <path to a gcc.exe>

And you can take the path e.g. from the c_cpp_properties.json that PlatformIO has generated, which nicely includes the full absolute path to the arm-none-eabi-gcc execeutable. The script also tries to find that attribute and use it.

This might work for this project, but would have to be re-done for every Marlin project you compile, so the general install-GCC fix should be better.

Hi Max,
took a while to get things done!
I went through all things you required step-by-step.
I installed the program minGW-W64 and have set the path:

Then I have cleaned up VSCode and started from scratch. After finishing and cbuilding with pio - Error: “CC” written wrong or could not be found.
Then I edited the path for gcc in platformio.ini and error again - but different!
See the screenshot and the build -messages:

> Executing task in folder Marlin-2.0.7.2-SKR-E3-DIP: C:\Users\elli\.platformio\penv\Scripts\pio.exe run <

Warning! Ignore unknown configuration option `custom_gcc` in section [platformio]
Processing STM32F103RC_btt_USB (platform: ststm32@~6.1; board: genericSTM32F103RC; framework: arduino)
----------------------------------------------------------------------------------------------------------------------------------------------------Verbose mode can be enabled via `-v, --verbose` option
CONFIGURATION: https://docs.platformio.org/page/boards/ststm32/genericSTM32F103RC.html
PLATFORM: ST STM32 (6.1.1) > STM32F103RC (48k RAM. 256k Flash)  
HARDWARE: STM32F103RCT6 72MHz, 48KB RAM, 256KB Flash
DEBUG: Current (blackmagic) External (blackmagic, jlink, stlink)
PACKAGES:
 - framework-arduinoststm32-maple 2.10000.200103 (1.0.0)        
 - tool-stm32duino 1.0.2
 - toolchain-gccarmnoneeabi 1.70201.0 (7.2.1)
LDF: Library Dependency Finder -> http://bit.ly/configure-pio-ldf
LDF Modes: Finder ~ chain, Compatibility ~ soft
Found 31 compatible libraries
Scanning dependencies...
Dependency Graph
|-- <SoftwareSerialM> 1.0.0
|-- <USBComposite for STM32F1> 0.91
|-- <TMCStepper> 0.7.1
|   |-- <SoftwareSerialM> 1.0.0
|-- <U8glib-HAL> 0.4.3
|   |-- <Wire> 1.0
|-- <Wire> 1.0
|-- <FreeRTOS701>
|-- <EEPROM>
|-- <Servo(STM32F1)> 1.1.2
|-- <STM32ADC> 1.0
Building in release mode
Compiling .pio\build\STM32F103RC_btt_USB\FrameworkArduinoVariant\board.cpp.o
Der Befehl "arm-none-eabi-g++" ist entweder falsch geschrieben oder
konnte nicht gefunden werden.
Compiling .pio\build\STM32F103RC_btt_USB\FrameworkArduinoVariant\wirish\boards.cpp.o
Der Befehl "arm-none-eabi-g++" ist entweder falsch geschrieben oder
konnte nicht gefunden werden.
Compiling .pio\build\STM32F103RC_btt_USB\FrameworkArduinoVariant\wirish\boards_setup.cpp.o
Der Befehl "arm-none-eabi-g++" ist entweder falsch geschrieben oder
konnte nicht gefunden werden.
Compiling .pio\build\STM32F103RC_btt_USB\FrameworkArduinoVariant\wirish\start.S.o
*** [.pio\build\STM32F103RC_btt_USB\FrameworkArduinoVariant\board.cpp.o] Error 1
*** [.pio\build\STM32F103RC_btt_USB\FrameworkArduinoVariant\wirish\boards.cpp.o] Error 1
*** [.pio\build\STM32F103RC_btt_USB\FrameworkArduinoVariant\wirish\boards_setup.cpp.o] Error 1
Der Befehl "arm-none-eabi-gcc" ist entweder falsch geschrieben oder
konnte nicht gefunden werden.
*** [.pio\build\STM32F103RC_btt_USB\FrameworkArduinoVariant\wirish\start.S.o] Error 1
=========================================================== [FAILED] Took 12.10 seconds ===========================================================

Environment          Status    Duration
-------------------  --------  ------------
STM32F103RC_btt_USB  FAILED    00:00:12.098
====================================================== 1 failed, 0 succeeded in 00:00:12.098 ====================================================== 
The terminal process "C:\Users\elli\.platformio\penv\Scripts\pio.exe 'run'" terminated with exit code: 1.

Terminal will be reused by tasks, press any key to close it.

What to try next!?
Best Regards
Hans

Can you add \gcc.exe at the end of this path? It has to the full path to the executable.

Already did - no change

Please remove your entire C:\Users\elli\.platformio\packages folder and retry.

The missing file (…arm-none-eabi-gcc) is existing under C:/user/elli/.pio/…
both as zip and in different versions (see screenshot!)
How can we teach intellisense to pick this path too?

Would it help, if I put this in a window-path too - actually which one though?

That file path is the download cache (.cache\tmp\..), only the ones in the \packages path is interesting.

The PlatformIO Rebuild IntelliSense project task has to do that. I see per your last picture that that actually executed successfully now. Has it adapted the c_cpp_properties.json accordingly with the full path to your compiler? As said, it should be something like C:\Users\elli\.platformio\packages\toolchain-gccarmnoneeabi\bin\arm-none-eabi-gcc.exe.

Does Marlin build now with the build button?

In the …json file it does not show the path:

Yes - Marlin now works perfect with the button (whenever the Alien is finished…)

I’m baffled on why there is still no full path in there.

I’m testing this on Linux (but behavior should be the same) and when I do a normal PlatformIO project I get

the full path.

You did upgrade your core to the very latest version with pio upgrade --dev in the PlatformIO CLI right?

I’ll also try with the Marlin project shortly…

Edit: With Marlin it also works perfectly fine, full path given

and IntelliSense working

Basically I have the file located!

The problem is even if you do place the full path in the c_cpp_properties.json, every time PlatformIO does an IntelliSense index rebuild it will overwrite that file, and to me it looks like the PlatformIO core is putting the wrong filepath in there.

Can you please to do the following: Open a PlatformIO CLI and execute

pio --version
pio init --ide=vscode ; type .vscode\c_cpp_properties.json

and post the output of the first command and the second output starting at the compilerPath line.

If the version does not return 5.0.4a2, re-run pio upgrade --dev.

PS C:\B-Marlin\Marlin-2.0.7.2-SKR-E3-DIP> pio --version
PlatformIO Core, version 5.0.4a2
PS C:\B-Marlin\Marlin-2.0.7.2-SKR-E3-DIP>

       "name": "PlatformIO",
        "includePath": [
            "C:/B-Marlin/Marlin-2.0.7.2-SKR-E3-DIP/Marlin",
            "C:/B-Marlin/Marlin-2.0.7.2-SKR-E3-DIP",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/STM32ADC/src",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/Servo/src",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/EEPROM",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/FreeRTOS701",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/FreeRTOS701/utility",
            "C:/B-Marlin/Marlin-2.0.7.2-SKR-E3-DIP/.pio/libdeps/STM32F103RC_btt_USB/U8glib-HAL/src",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/Wire",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/Wire/utility",
            "C:/B-Marlin/Marlin-2.0.7.2-SKR-E3-DIP/.pio/libdeps/STM32F103RC_btt_USB/TMCStepper/src",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/USBComposite",
            "C:/B-Marlin/Marlin-2.0.7.2-SKR-E3-DIP/.pio/libdeps/STM32F103RC_btt_USB/SoftwareSerialM",
            "C:/B-Marlin/Marlin-2.0.7.2-SKR-E3-DIP/Marlin/src/HAL/STM32F1",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/cores/maple",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/system/libmaple",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/system/libmaple/include",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/system/libmaple/stm32f1/include",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/system/libmaple/usb/stm32f1",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/system/libmaple/usb/usb_lib",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/variants/generic_stm32f103r",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/A_STM32_Examples",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/Adafruit_GFX_AS",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/Adafruit_ILI9341",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/Adafruit_ILI9341_STM",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/Adafruit_SSD1306",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/Ethernet_STM/src",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/FreeRTOS821",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/FreeRTOS821/utility",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/FreeRTOS900",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/Lcd7920_STM",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/MapleCoOS",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/MapleCoOS/utility",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/MapleCoOS116",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/MapleCoOS116/utility",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/OLED_I2C",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/OneWireSTM/src",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/RTClock/src",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/SDIO",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/Serasidis_EtherCard_STM/src",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/Serasidis_VS1003B_STM/src",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/Serasidis_XPT2046_touch/src",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/Touch-Screen-Library_STM",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/WS2812B/src",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/WireSlave/src",
            "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/stm_fft",
            "C:/Users/elli/.platformio/packages/tool-unity",
            ""
        ],
        "browse": {
            "limitSymbolsToIncludedHeaders": true,
            "path": [
                "C:/B-Marlin/Marlin-2.0.7.2-SKR-E3-DIP/Marlin",
                "C:/B-Marlin/Marlin-2.0.7.2-SKR-E3-DIP",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/STM32ADC/src",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/Servo/src",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/EEPROM",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/FreeRTOS701",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/FreeRTOS701/utility",
                "C:/B-Marlin/Marlin-2.0.7.2-SKR-E3-DIP/.pio/libdeps/STM32F103RC_btt_USB/U8glib-HAL/src",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/Wire",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/Wire/utility",
                "C:/B-Marlin/Marlin-2.0.7.2-SKR-E3-DIP/.pio/libdeps/STM32F103RC_btt_USB/TMCStepper/src",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/USBComposite",
                "C:/B-Marlin/Marlin-2.0.7.2-SKR-E3-DIP/.pio/libdeps/STM32F103RC_btt_USB/SoftwareSerialM",
                "C:/B-Marlin/Marlin-2.0.7.2-SKR-E3-DIP/Marlin/src/HAL/STM32F1",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/cores/maple",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/system/libmaple",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/system/libmaple/include",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/system/libmaple/stm32f1/include",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/system/libmaple/usb/stm32f1",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/system/libmaple/usb/usb_lib",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/variants/generic_stm32f103r",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/A_STM32_Examples",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/Adafruit_GFX_AS",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/Adafruit_ILI9341",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/Adafruit_ILI9341_STM",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/Adafruit_SSD1306",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/Ethernet_STM/src",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/FreeRTOS821",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/FreeRTOS821/utility",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/FreeRTOS900",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/Lcd7920_STM",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/MapleCoOS",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/MapleCoOS/utility",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/MapleCoOS116",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/MapleCoOS116/utility",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/OLED_I2C",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/OneWireSTM/src",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/RTClock/src",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/SDIO",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/Serasidis_EtherCard_STM/src",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/Serasidis_VS1003B_STM/src",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/Serasidis_XPT2046_touch/src",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/Touch-Screen-Library_STM",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/WS2812B/src",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/WireSlave/src",
                "C:/Users/elli/.platformio/packages/framework-arduinoststm32-maple/STM32F1/libraries/stm_fft",
                "C:/Users/elli/.platformio/packages/tool-unity",
                ""
            ]
        },
        "defines": [
            "PLATFORMIO=50004",
            "STM32F103xE",
            "STM32F1",
            "TARGET_STM32F1",
            "__MARLIN_FIRMWARE__",
            "HAVE_SW_SERIAL",
            "TONE_CHANNEL=4",
            "DEBUG_LEVEL=0",
            "SS_TIMER=4",
            "USE_USB_COMPOSITE",
            "ARDUINO=10808",
            "ARDUINO_ARCH_STM32",
            "ARDUINO_ARCH_STM32F1",
            "ARDUINO_GENERIC_STM32F103R",
            "MCU_STM32F103RC",
            "__STM32F1__",
            "BOARD_generic_stm32f103r",
            "F_CPU=72000000L",
            "VECT_TAB_ADDR=0x8000000",
            "ERROR_LED_PORT=GPIOB",
            "ERROR_LED_PIN=1",
            "CONFIG_MAPLE_MINI_NO_DISABLE_DEBUG=1",
            "SERIAL_USB",
            "GENERIC_BOOTLOADER",
            ""
        ],
        "cppStandard": "c++14",
        "compilerPath": "arm-none-eabi-gcc",
        "compilerArgs": [
            "-mcpu=cortex-m3",
            "-mthumb",
            "-mcpu=cortex-m3",
            "-mthumb",
            "-march=armv7-m",
            ""
        ]
    }
],
"version": 4

}
PS C:\B-Marlin\Marlin-2.0.7.2-SKR-E3-DIP>

For the life of me I can’t figure out why PlatformIO won’t put the full path to the compiler in there. Will have to retest on Marlin later today…

OK, Max!
I wonder anyhow what kind of effort you put in here to help me - even on a sunday - and even worse - on 1st of advent!! Really appreciate it !!!
Best Regards
Hans

1 Like

Hi Max,
now here we have the salad!,
Just for fun I thought it would be an idea to put all the stuff onto my old Win-7 laptop!
I installed it - took the new 2.0.7.2 version from BTT, went through your recipe-setup (…pio upgrade…),
no system-path at all, no special treatment - and it compiled successfully!
There are some warnings - but produced the firmware.bin!
you can see the screenshot and the partial terminal-output (…warnings) :blush:

 Archiving .pio\build\STM32F103RC_btt_USB\libbd0\libU8glib-HAL.a
Compiling .pio\build\STM32F103RC_btt_USB\lib17f\FreeRTOS701\utility\croutine.c.o
Compiling .pio\build\STM32F103RC_btt_USB\lib17f\FreeRTOS701\utility\heap_2.c.o
Compiling .pio\build\STM32F103RC_btt_USB\lib17f\FreeRTOS701\utility\list.c.o
Compiling .pio\build\STM32F103RC_btt_USB\lib17f\FreeRTOS701\utility\port.c.o
C:\users\acer\.platformio\packages\framework-arduinoststm32-maple\STM32F1\libraries\FreeRTOS701\utility\port.c: In function 'xPortStartScheduler':
C:\users\acer\.platformio\packages\framework-arduinoststm32-maple\STM32F1\libraries\FreeRTOS701\utility\port.c:178:2: warning: implicit declaration of function 'systick_attach_callback' [-Wimplicit-function-declaration]
  systick_attach_callback(&xPortSysTickHandler);
  ^~~~~~~~~~~~~~~~~~~~~~~
At top level:
C:\users\acer\.platformio\packages\framework-arduinoststm32-maple\STM32F1\libraries\FreeRTOS701\utility\port.c:285:6: warning: 'prvSetupTimerInterrupt' defined but not used [-Wunused-function]
 void prvSetupTimerInterrupt( void )
      ^~~~~~~~~~~~~~~~~~~~~~
Compiling .pio\build\STM32F103RC_btt_USB\lib17f\FreeRTOS701\utility\queue.c.o
Compiling .pio\build\STM32F103RC_btt_USB\lib17f\FreeRTOS701\utility\tasks.c.o
Compiling .pio\build\STM32F103RC_btt_USB\lib17f\FreeRTOS701\utility\timers.c.o
Compiling .pio\build\STM32F103RC_btt_USB\liba82\EEPROM\EEPROM.cpp.o
Archiving .pio\build\STM32F103RC_btt_USB\lib17f\libFreeRTOS701.a
Compiling .pio\build\STM32F103RC_btt_USB\liba82\EEPROM\flash_stm32.c.o
Compiling .pio\build\STM32F103RC_btt_USB\lib045\Servo\Servo.cpp.o
Archiving .pio\build\STM32F103RC_btt_USB\liba82\libEEPROM.a
Compiling .pio\build\STM32F103RC_btt_USB\lib828\STM32ADC\STM32ADC.cpp.o
Archiving .pio\build\STM32F103RC_btt_USB\lib045\libServo.a
Compiling .pio\build\STM32F103RC_btt_USB\lib828\STM32ADC\utility\util_adc.c.o
C:\users\acer\.platformio\packages\framework-arduinoststm32-maple\STM32F1\libraries\STM32ADC\src\utility\util_adc.c:10:30: warning: 'adc_result' initialized and declared 'extern'
 extern volatile unsigned int adc_result = 0;
                              ^~~~~~~~~~
Archiving .pio\build\STM32F103RC_btt_USB\lib828\libSTM32ADC.a
Linking .pio\build\STM32F103RC_btt_USB\firmware.elf
.pio\build\STM32F103RC_btt_USB\FrameworkArduino\main.cpp.o: In function `main':
C:\users\acer\.platformio\packages\framework-arduinoststm32-maple\STM32F1\cores\maple/main.cpp:38: warning: undefined reference to `setup()'
C:\users\acer\.platformio\packages\framework-arduinoststm32-maple\STM32F1\cores\maple/main.cpp:41: warning: undefined reference to `loop()'
Checking size .pio\build\STM32F103RC_btt_USB\firmware.elf
Building .pio\build\STM32F103RC_btt_USB\firmware.bin
Advanced Memory Usage is available via "PlatformIO Home > Project Inspect"
RAM:   [=         ]   9.9% (used 4888 bytes from 49152 bytes)
Flash: [=         ]   7.3% (used 19088 bytes from 262144 bytes)
=============================================================== [SUCCESS] Took 324.78 seconds ===============================================================

Environment          Status    Duration
-------------------  --------  ------------
STM32F103RC_btt_USB  SUCCESS   00:05:24.776
================================================================ 1 succeeded in 00:05:24.776 ================================================================

Terminal will be reused by tasks, press any key to close it.

All I need to check, if this is a one-time-event, or if it is reproduceable!
I will let you know after my sleep!
Regards
Hans

It seems, it works continuesly! The second run even without error-messages!
Following the terminal-output:

 Executing task in folder Marlin-2.0.7.2-SKR-E3-DIP: C:\Users\ACER\.platformio\penv\Scripts\pio.exe run <

Processing STM32F103RC_btt_USB (platform: ststm32@~6.1; board: genericSTM32F103RC; framework: arduino)
--------------------------------------------------------------------------------------------------------------------------------------------------------------
Verbose mode can be enabled via `-v, --verbose` option
CONFIGURATION: https://docs.platformio.org/page/boards/ststm32/genericSTM32F103RC.html
PLATFORM: ST STM32 (6.1.1) > STM32F103RC (48k RAM. 256k Flash)
HARDWARE: STM32F103RCT6 72MHz, 48KB RAM, 256KB Flash
DEBUG: Current (blackmagic) External (blackmagic, jlink, stlink)
PACKAGES:
 - framework-arduinoststm32-maple 2.10000.200103 (1.0.0)
 - tool-stm32duino 1.0.2
 - toolchain-gccarmnoneeabi 1.70201.0 (7.2.1)
LDF: Library Dependency Finder -> http://bit.ly/configure-pio-ldf
LDF Modes: Finder ~ chain, Compatibility ~ soft
Found 31 compatible libraries
Scanning dependencies...
Dependency Graph
|-- <SoftwareSerialM> 1.0.0
|-- <USBComposite for STM32F1> 0.91
|-- <TMCStepper> 0.7.1
|   |-- <SoftwareSerialM> 1.0.0
|-- <U8glib-HAL> 0.4.3
|   |-- <Wire> 1.0
|-- <Wire> 1.0
|-- <FreeRTOS701>
|-- <EEPROM>
|-- <Servo(STM32F1)> 1.1.2
|-- <STM32ADC> 1.0
Building in release mode
Checking size .pio\build\STM32F103RC_btt_USB\firmware.elf
Advanced Memory Usage is available via "PlatformIO Home > Project Inspect"
RAM:   [=         ]   9.9% (used 4888 bytes from 49152 bytes)
Flash: [=         ]   7.3% (used 19088 bytes from 262144 bytes)
================================================================ [SUCCESS] Took 77.68 seconds ================================================================

Environment          Status    Duration
-------------------  --------  ------------
STM32F103RC_btt_USB  SUCCESS   00:01:17.684
================================================================ 1 succeeded in 00:01:17.684 ================================================================

Terminal will be reused by tasks, press any key to close it.