You should try the most recent version first. Open a PIO terminal and to a pio upgrade --dev
to get on 4.1.0a1
, then restart VSCode, clean and recompile the project. Does the error persist?
i upgraded now…
i am using atom right now… i clicked on clean and then build… the terminal appears only for some milliseconds and closes.
i looked into the documentation and startet in the terminal “platformio run --target clean”
After that i got the same error
What is the content of your Marlin.ino
file? If it’s like this with only comments and no actual code, please delete the file. Maybe there is an error when attempting to convert the .ino
to a .cpp
file if there is no actual code content.
I am having the same problem. Removing the Marlin.ino has not solved my problem. Now Im getting something like this multiple times
Compiling .pio/build/LPC1768/src/src/HAL/HAL_LPC1768/DebugMonitor.cpp.o
sh: arm-none-eabi-g++: command not found
and then farther down I’m getting
*** [.pio/build/LPC1768/src/src/HAL/HAL_LPC1768/DebugMonitor.cpp.o] Error 127
Does it matter that it installs toolchain-gccarmnoneeabi
every time it I try to compile?
… yes probably, might be a symptom of it not being able to handle the compiler toolchain package and not being able to use it afterwards.
Well strictly put this is a 3rd party platform outside of PlatformIO’s normal ecosystem and it’s also pointing to a custom release of the compiler
But I think I’ve figured out the problem. You see if you actually download the compiler from the link above, it’s for Linux x64. Extract it and look at arm-none-eabi-g++
.
>file "arm-none-eabi-g++"
arm-none-eabi-g++; ELF 64-bit LSB executable, x86-64, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 3.2.0, from '8@%rdi 8@%rsi', stripped
Of course this won’t work an Apple machine as I’ll infer from the appley-looking path
@JonathanFStewart, are you also using an Apple machine?
I don’t really know why a custom platform needed to be created for this, there already is the GitHub - platformio/platform-nxplpc: NXP LPC: development platform for PlatformIO platform for NXP chips. Why not make an addition to this repository?
You could try and get the compiler for Apple/Windows by overriding the package, that is, add to the environment in the platformio.ini
the lines
platform_packages = toolchain-gccarmnoneeabi@https://dl.bintray.com/platformio/dl-packages/toolchain-gccarmnoneeabi-darwin_x86_64-1.80201.181220.tar.gz
(Windows: http://dl.platformio.org/packages/toolchain-gccarmnoneeabi-windows_x86-1.80201.190214.tar.gz), though I’m unsure whether it will accept HTTP links to archives, examples only show git repos are package names.
You may also attempt to just download the file above, remove the contents of the toolchain-gccarmnoneabi
folder and replace it with the contents of the archive above.
Where is the exact marlin branch and platformio.ini
you are using for reproduction?
@maxgerhardt yes I am also on an Apple machine. I have installed the arm tool chain and can run it from the terminal/CL but I can’t seem to get platform IO to recognize its already installed and just to use it.
The marlin branch I am using is here
the Platformio.ini file is also there, The only change I am making is changing line 21 from
default_envs = megaatmega2560
to
default_envs = LPC1768
to make it compile for the board I am using
PlatformIO will not use installed compilers from the commandline, as it is supposed to use specific versions of compilers sourced from the packages/toolchain-armgccnoneeabi
folders.
In addition to what is said above you could also try an easier thing: Remove the toolchain-armgccnoneeabi folder, go to your ~/.platformio/platforms/nxplpc-arduino-lpc176x
folder, edit the manifest.json
(file shown above) and replace the url
link with the link for darwin x86_64 from the post below. It should attempt to redownload the compiler from PlatformIO and use it.
That would still leave the question open on why a special compiler release had to be made… If it not works, the original author of the repository should be asked what changed.
I think I figured out what the problem is/was. I had to open Xcode and accept the license agreement I remember this being a problem for other Arduino stuff in the past. Its working now though. Thanks @maxgerhardt
Well actually that of course won’t work because it doesn’t reference the manifest.json
on disk but on the web.
You can edit your ~/.platformio/platforms/nxplpc-arduino-lpc176x/platform.json
and replace the https://raw.githubusercontent.com/p3p/pio-nxplpc-arduino-lpc176x/master/manifest.json
line with https://gist.githubusercontent.com/maxgerhardt/632204307236b865c42b36ce83c8cc22/raw/77bc71ad307b716d34ae74fb78d24c4847367a56/manifest.json
which has the right URL for darwin in it.
Well good that it’s working but this is not really the proper way to solve it. It downloads a package which is meant for Linux, tries to execute arm-none-eabi-g++
, can’t execute the actually downloaded package but magically picks one you’ve installed in the shell (I didn’t really think this would work actually o_O). So maybe try that above for a cleaner solution.
THHHHAAAAANNNNNKKK YOU!!! The manual package helped!
I tried the solution of Max. I don’t get the error directly now but after 8 minutes of loading I get the error:
PackageManager: Installing toolchain-gccarmnoneeabi @ >=1.80201.181221
Downloading…
Unpacking…
Warning! Package Mirror: Package version 1.80201.181220 doesn’t satisfy requirements >=1.80201.181221
Error: Could not install ‘toolchain-gccarmnoneeabi’ with version requirements ‘>=1.80201.181221’ for your system ‘darwin_x86_64’.
Please try this solution → Redirecting...
I changed 1.80201.181221 in the JSON file in 1.80201.181220 and now it works. Thanks Max!
Hi,
I also have this problem. Not be able to compile the “default_envs = LPC1768”
During the compilation I`m receiving these errors in Atom:
Marlin\src\lcd\extensible_ui\lib\ftdi_eve_touch_ui\ftdi_eve_lib\extended\unicode…/…/…/…/…/…/…/inc/…/HAL/./HAL_LPC1768/MarlinSerial.h:27:10: fatal error: …/…/inc/MarlinConfigPre.h: No such file or directory.
And:
*** [.pio\build\LPC1768\src\src\lcd\extensible_ui\lib\ftdi_eve_touch_ui\ftdi_eve_lib\extended\unicode\font_bitmaps.cpp.o] Error 1
DUE_debug IGNORED
LPC1768 FAILED 00:00:09.731
LPC1769 IGNORED
The only things i changes was the LPC1768 in the Platformio.ini.
and the
#define MOTHERBOARD BOARD_BIGTREE_SKR_V1_3 in the Configuration.h
Has someone found a solution for this?
Greetings
Palermo
Have the solutions above not helped? Which platform are you on?
I`m Running Windows 10,
I replaced the link as you suggested in folder .platformio\platforms\nxplpc-arduino-lpc176x
“version”: “0.1.1”,
“packageRepositories”: [
“https://gist.githubusercontent.com/maxgerhardt/632204307236b865c42b36ce83c8cc22/raw/77bc71ad307b716d34ae74fb78d24c4847367a56/manifest.json”,
This is how it look right now.
My feeling is that I`m doing something little wrong
Hm this still references darwin
aka Mac OS. Out of my head I can’t remember why or how exactly it worked. But have you tried reverting all your local changes and added
platform_packages = toolchain-gccarmnoneeabi@http://dl.platformio.org/packages/toolchain-gccarmnoneeabi-windows_x86-1.80201.190214.tar.gz
in the target environment of the platformio.ini
?
What I need to do is this?:
[env:LPC1769]
platform = toolchain-gccarmnoneeabi@http://dl.platformio.org/packages/toolchain-gccarmnoneeabi-windows_x86-1.80201.190214.tar.gz
board = nxp_lpc1769
build_flags = -DU8G_HAL_LINKS -IMarlin/src/HAL/HAL_LPC1768/include -IMarlin/src/HAL/HAL_LPC1768/u8g ${common.build_flags}
Change the platform with your suggested link in platformio.ini?
No not the platform, just keep everything normal and add the above platform_packages
ni the environment instead.
The LPC configuration now looks like this:
[env:LPC1768]
platform = https://github.com/p3p/pio-nxplpc-arduino-lpc176x/archive/0.1.2.zip
platform_packages = toolchain-gccarmnoneeabi@http://dl.platformio.org/packages/toolchain-gccarmnoneeabi-windows_x86-1.80201.190214.tar.gz
board = nxp_lpc1768
build_flags = -DU8G_HAL_LINKS -IMarlin/src/HAL/HAL_LPC1768/include -IMarlin/src/HAL/HAL_LPC1768/u8g ${common.build_flags}
# debug options for backtrace
# -funwind-tables
# -mpoke-function-name
lib_ldf_mode = off
lib_compat_mode = strict
extra_scripts = Marlin/src/HAL/HAL_LPC1768/upload_extra_script.py
src_filter = ${common.default_src_filter} +<src/HAL/HAL_LPC1768>
monitor_speed = 250000
lib_deps = Servo
LiquidCrystal
U8glib-HAL=https://github.com/MarlinFirmware/U8glib-HAL/archive/bugfix.zip
TMCStepper@>=0.6.1,<1.0.0
Adafruit NeoPixel=https://github.com/p3p/Adafruit_NeoPixel/archive/release.zip
SailfishLCD=https://github.com/mikeshub/SailfishLCD/archive/master.zip
Still giving me the same error.
But did something with the new suggested package:
HARDWARE: LPC1768 100MHz, 31.97KB RAM, 464KB Flash
DEBUG: Current (cmsis-dap) On-board (cmsis-dap) External (blackmagic, jlink)
**PACKAGES: toolchain-gccarmnoneeabi 1.80201.190214 (8.2.1), framework-arduino-lpc176x 0.2.2**
Converting Marlin.ino
LDF: Library Dependency Finder -> http://bit.ly/configure-pio-ldf
LDF Modes: Finder ~ off, Compatibility ~ strict
Found 6 compatible libraries
Scanning dependencies...
Dependency Graph
|-- <Servo> 1.0.0
|-- <LiquidCrystal> 1.0.0
|-- <U8glib-HAL> 0.4.1
|-- <TMCStepper> 0.6.1
|-- <Adafruit NeoPixel> 1.3.0
|-- <SailfishLCD>
Building in release mode
But the error message stay`s the same:
Marlin\src\lcd\extensible_ui\lib\ftdi_eve_touch_ui\ftdi_eve_lib\extended\unicode…/…/…/…/…/…/…/inc/…/HAL/./HAL_LPC1768/MarlinSerial.h:27:10: fatal error: …/…/inc/MarlinConfigPre.h: No such file
or directory
Did I add the packages correctly ?
If removed all the project files from editor.
Deleted the project folder from disk.
Extract a fresh Marlin-bugfix-2.0.x
Added the project folder to editor.
Applied all the necessary changes for SKR 1.3 and recompiled with success.
Next step adding BLtouch and Filament run-out detection.
Thanks for helping @maxgerhardt
Greatly appreciated
Greetings
Palermo
Hi, this thread is a bit old, but I’m having the same problem.
I’m running Windows 10, VS Code with platformIO and Auto Build Marlin extensions.
When I press build it fails and I get:
PS C:\Marlin2022> platformio run -e LPC1769
Processing LPC1769 (board: nxp_lpc1769; platform: https://github.com/p3p/pio-nxplpc-arduino-lpc176x/archive/0.1.3.zip; framework: arduino)
-------------------------------------------------------------------------------------------------------------------------------------Verbose mode can be enabled via -v, --verbose
option
arm-none-eabi-g++.exe: fatal error: cannot execute ‘cc1plus’: CreateProcess: No such file or directory
compilation terminated.
I tried all of the above fixes and I keep getting the same error.
I’m out of options, any help would be greatly appreciated
Guido