The compile process completes fine:
Executing task: C:\Users\tony.platformio\penv\Scripts\platformio.exe debug --environment LPC1769Debug <
Processing LPC1769Debug (platform: https://github.com/p3p/pio-nxplpc-arduino-lpc176x/archive/0.1.3.zip; board: nxp_lpc1769; framework: arduino)
--------------------------------------------------------------------------------------------------------------------------------------------------------------Verbose mode can be enabled via `-v, --verbose` option
CONFIGURATION: https://docs.platformio.org/page/boards/nxplpc-arduino-lpc176x/nxp_lpc1769.html
PLATFORM: NXP Arduino LPC176x (0.1.3) > NXP LPC1769
HARDWARE: LPC1769 120MHz, 31.97KB RAM, 464KB Flash
DEBUG: Current (custom) On-board (cmsis-dap) External (blackmagic, jlink)
PACKAGES:
- framework-arduino-lpc176x 0.2.9
- toolchain-gccarmnoneeabi 1.90301.200702 (9.3.1)
Converting Marlin.ino
LDF: Library Dependency Finder -> http://bit.ly/configure-pio-ldf
LDF Modes: Finder ~ off, Compatibility ~ strict
Found 2 compatible libraries
Scanning dependencies...
Dependency Graph
|-- <U8glib-HAL> 0.4.5
Building in debug mode
Checking size .pio\build\LPC1769Debug\debug\firmware.elf
Advanced Memory Usage is available via "PlatformIO Home > Project Inspect"
RAM: [==== ] 39.8% (used 13044 bytes from 32736 bytes)
Flash: [====== ] 64.5% (used 306536 bytes from 475136 bytes)
================================================================ [SUCCESS] Took 7.54 seconds ================================================================
Environment Status Duration
------------- -------- ------------
LPC1769Debug SUCCESS 00:00:07.538
================================================================ 1 succeeded in 00:00:07.538 ================================================================
Terminal will be reused by tasks, press any key to close it.
The Debug Console has only one line of output and it is:
undefinedError: Could not load a build configuration
Here is my platform.ini file
[platformio]
src_dir = Marlin
boards_dir = buildroot/share/PlatformIO/boards
default_envs = LPC1769Debug
include_dir = Marlin
[common]
…tons of things here not pertinent to the problem …
[features]
…tons of things here not pertinent to the problem …
[env]
framework = arduino
extra_scripts = ${common.extra_scripts}
build_flags = ${common.build_flags}
lib_deps = ${common.lib_deps}
monitor_speed = 250000
monitor_flags =
–quiet
–echo
–eol
LF
–filter
colorize
–filter
time
[common_LPC]
platform = https://github.com/p3p/pio-nxplpc-arduino-lpc176x/archive/0.1.3.zip
platform_packages = framework-arduino-lpc176x@^0.2.6
lib_ldf_mode = off
lib_compat_mode = strict
extra_scripts = ${common.extra_scripts}
src_filter = ${common.default_src_filter} +<src/HAL/LPC1768> +<src/HAL/shared/backtrace>
lib_deps = ${common.lib_deps}
Servo
custom_marlin.uses_liquidcrystal = arduino-libraries/LiquidCrystal@~1.0.7
custom_marlin.neopixel_led = Adafruit NeoPixel=https://github.com/p3p/Adafruit_NeoPixel/archive/1.5.0.zip
build_flags = ${common.build_flags} -DU8G_HAL_LINKS -IMarlin/src/HAL/LPC1768/include -IMarlin/src/HAL/LPC1768/u8g
-Wno-int-in-bool-context -Wno-unused-variable -Wno-unknown-pragmas
[env:LPC1768]
platform = ${common_LPC.platform}
extends = common_LPC
board = nxp_lpc1768
lib_deps = marlinfirmware/U8glib-HAL@^0.4.4
[env:LPC1769Debug]
extends = env:LPC1769
build_type = debug
build_flags = ${common_LPC.build_flags} -g3 -O0 -ggdb -DDEBUG -DVECT_TAB_FLASH=0x00000000
debug_tool = custom
debug_server = $PLATFORMIO_CORE_DIR/packages/tool-openocd/bin/openocd
-c
gdb_port 3334
-c
tcl_port disabled
-c
telnet_port disabled
-c
set CALLER DEBUG # so that all cfg files know who called them
-c
set LOADADDRESS 0x00000000 # MAKE SURE TO SET THIS CORRECTLY!!!
-c
set FIRMWARENAME {$PROG_PATH} # for debug, use $PROG_PATH ($SOURCE is not available) for output filename
-c
set PROGRAMMER STLINK # tell MY_LPC1769.cfg whether to use STLink or MCULink interface
-c
set PROG_DEVICE STLINK_COPPER # tell MY_LPC1769.cfg which device (STLINK_DISCO, STLINK_BLACK, STLINK_COPPER)
-f # it outputs .elf, but the MY_LPC1769.cfg will rename it to .bin
$PLATFORMIO_CORE_DIR/packages\tool-openocd\scripts\board\MY_LPC1769.cfg
#Add debug related commands
debug_build_flags = -g3 -O0 -ggdb3 -DDEBUG
debug_load_mode = modified
debug_port = localhost:3334 # where GDB connects to OpenOCD
debug_load_cmds = load
debug_init_break = #tbreak loop #main # leave empty to not stop on main(), or set a function name or line to break at
debug_init_cmds =
#mon gdb_memory_map enable
define pio_reset_halt_target
monitor reset
monitor halt
end
define pio_reset_run_target
monitor reset
end
define pio_restart_target
pio_reset_halt_target
end
target remote $DEBUG_PORT
#mon set non-stop on
#define hook-stop
#echo "hook-stop"
#mon cortex_m maskisr on
#end
#define hook-continue
#echo "hook-continue"
#mon cortex_m maskisr off
#end
monitor init # GDB monitor commands to send to OpenOCD
monitor reset init # sets MEMMAP (0x400FC040) to 0x1 for User Flash mapped to address 0x00000000
set mem inaccessible-by-default off # GDB commands
monitor mdw 0x400FC040 # look to see if User Reset (1) and not Bootloader (0)
$INIT_BREAK # GDB commands this sends whatever is in (debug_init_break = )
$LOAD_CMDS # GDB commands this sends whatever is in (debug_load_cmds = )
debug_extra_cmds =
set remotetimeout 5000 # GDB command to extend timeout from target 5000 seconds
show remotetimeout
lib_deps = marlinfirmware/U8glib-HAL@^0.4.4 # needed by Marlin 2.0.8 release
[env:LPC1769]
build_type = release
platform = ${common_LPC.platform}
extends = common_LPC
board = nxp_lpc1769
build_flags = ${common_LPC.build_flags} -g -ggdb -O1 # any optimize levels -O1,-O2,-O3,-Os cause Marlin Mode failure on TFT35
extra_scripts = ${common_LPC.extra_scripts}
TGExtra\MY_LPC17xx_helper.py # calcs LPC checksum and writes it to 0x0000001c in binary file
#TGExtra\dump_env.py
#Add upload related commands
upload_protocol= custom # for LPC17xx use custom, cmsis-dap inserts an extra “-t, lpc1768” to upload_flags, causing errors
#strange, the arguments to command below must all be on the same line, unlike the debug_server =, (or put args in upload_flags)
upload_command = $PROJECT_PACKAGES_DIR\tool-openocd\bin\openocd
upload_flags =
-c
set FIRMWARENAME {$PROJECT_DIR$SOURCE} # for upload, $SOURCE seems to be available as output filename
-c
set CALLER UPLOAD # so that all cfg files know who called them
-c
set LOADADDRESS 0x00000000 # MAKE SURE TO SET THIS CORRECTLY!!! For now LPC parts must start at zero!
-c
set PROGRAMMER STLINK # tell MY_LPC1769.cfg whether to use STLink or MCULink interface
-c
set PROG_DEVICE STLINK_COPPER # tell MY_LPC1769.cfg which device (STLINK_DISCO, STLINK_BLACK, STLINK_COPPER)
-f
$PROJECT_PACKAGES_DIR\tool-openocd\scripts\board\MY_LPC1769.cfg
lib_deps = marlinfirmware/U8glib-HAL@^0.4.4 # needed by Marlin 2.0.8 release
Here is the Console output from Toggle Developer Tools:
console.ts:137 [Extension Host] (node:11700) [DEP0005] DeprecationWarning: Buffer() is deprecated due to security and usability issues. Please use the Buffer.alloc(), Buffer.allocUnsafe(), or Buffer.from() methods instead.(Use Code --trace-deprecation ...
to show where the warning was created)
v @ console.ts:137
console.ts:137 [Extension Host] activating extension
console.ts:137 [Extension Host] starting language server
console.ts:137 [Extension Host] runCommand C:\Users\tony.platformio\python3\python.exe Array(2) Object
console.ts:137 [Extension Host] runCommand C:\Users\tony.platformio\python3\python.exe Array(8) Object
console.ts:137 [Extension Host] Found compatible PlatformIO Core 5.2.0 → C:\Users\tony.platformio\penv\Scripts\platformio.exe
console.ts:137 [Extension Host] PIO Core State Object
console.ts:137 [Extension Host] Switching project to c:\Users\tony\Documents\CNC\MAINBOARD\Marlin-2.0.8-0525210-SGEN
console.ts:137 [Extension Host] Activating project c:\Users\tony\Documents\CNC\MAINBOARD\Marlin-2.0.8-0525210-SGEN
console.ts:137 [Extension Host] Put command in queue C:\Users\tony.platformio\penv\Scripts\python.exe Array(2) Object
console.ts:137 [Extension Host] runCommand C:\Users\tony.platformio\penv\Scripts\python.exe Array(2) Object
log.ts:301 ERR Bad progress location: platformio-ide.projectTasks: Error: Bad progress location: platformio-ide.projectTasks
at i.withProgress (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1992:121025)
at w.$startProgress (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1495:29184)
at d._doInvokeHandler (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1502:12737)
at d._invokeHandler (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1502:12421)
at d._receiveRequest (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1502:11083)
at d._receiveOneMessage (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1502:9761)
at vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1502:7857
at l.fire (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:69:1712)
at r.fire (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:85:16477)
at f._receiveMessage (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:85:21747)
at vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:85:18625
at l.fire (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:69:1712)
at b.acceptChunk (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:85:13838)
at vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:85:13186
at Socket.k (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:2872:163769)
at Socket.emit (events.js:315:20)
at addChunk (internal/streams/readable.js:309:12)
at readableAddChunk (internal/streams/readable.js:284:9)
at Socket.Readable.push (internal/streams/readable.js:223:10)
at Pipe.onStreamRead (internal/stream_base_commons.js:188:23)
console.ts:137 [Extension Host] Put command in queue C:\Users\tony.platformio\penv\Scripts\python.exe Array(7) Object
console.ts:137 [Extension Host] runCommand C:\Users\tony.platformio\penv\Scripts\python.exe Array(7) Object
console.ts:137 [Extension Host] Put command in queue C:\Users\tony.platformio\penv\Scripts\python.exe Array(2) Object
console.ts:137 [Extension Host] runCommand C:\Users\tony.platformio\penv\Scripts\python.exe Array(2) Object
log.ts:301 ERR Bad progress location: platformio-ide.projectTasks: Error: Bad progress location: platformio-ide.projectTasks
at i.withProgress (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1992:121025)
at w.$startProgress (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1495:29184)
at d._doInvokeHandler (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1502:12737)
at d._invokeHandler (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1502:12421)
at d._receiveRequest (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1502:11083)
at d._receiveOneMessage (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1502:9761)
at vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1502:7857
at l.fire (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:69:1712)
at r.fire (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:85:16477)
at f._receiveMessage (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:85:21747)
at vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:85:18625
at l.fire (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:69:1712)
at b.acceptChunk (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:85:13838)
at vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:85:13186
at Socket.k (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:2872:163769)
at Socket.emit (events.js:315:20)
at addChunk (internal/streams/readable.js:309:12)
at readableAddChunk (internal/streams/readable.js:284:9)
at Socket.Readable.push (internal/streams/readable.js:223:10)
at Pipe.onStreamRead (internal/stream_base_commons.js:188:23)
console.ts:137 [Extension Host] Could not fetch project targets for ‘LPC1769Debug’ environment => Error: Traceback (most recent call last):
File “”, line 1, in
TypeError: ‘NoneType’ object is not subscriptable
v @ console.ts:137
console.ts:137 [Extension Host] Put command in queue C:\Users\tony.platformio\penv\Scripts\python.exe Array(2) Object
console.ts:137 [Extension Host] runCommand C:\Users\tony.platformio\penv\Scripts\python.exe Array(2) Object
log.ts:301 ERR Bad progress location: platformio-ide.projectTasks: Error: Bad progress location: platformio-ide.projectTasks
at i.withProgress (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1992:121025)
at w.$startProgress (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1495:29184)
at d._doInvokeHandler (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1502:12737)
at d._invokeHandler (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1502:12421)
at d.receiveRequest (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1502:11083)
at d.receiveOneMessage (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1502:9761)
at vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1502:7857
at l.fire (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:69:1712)
at r.fire (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:85:16477)
at f.receiveMessage (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:85:21747)
at vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:85:18625
at l.fire (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:69:1712)
at b.acceptChunk (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:85:13838)
at vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:85:13186
at Socket.k (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:2872:163769)
at Socket.emit (events.js:315:20)
at addChunk (internal/streams/readable.js:309:12)
at readableAddChunk (internal/streams/readable.js:284:9)
at Socket.Readable.push (internal/streams/readable.js:223:10)
at Pipe.onStreamRead (internal/stream_base_commons.js:188:23)
console.ts:137 [Extension Host] runCommand C:\Users\tony.platformio\penv\Scripts\python.exe Array(2) Object
console.ts:137 [Extension Host] Error: C:\Users\tony.platformio\penv\lib\site-packages\platformio_main.py:70: DeprecationWarning: ‘resultcallback’ has been renamed to ‘result_callback’. The old name will be removed in Click 8.1.
@cli.resultcallback()
Error: Traceback (most recent call last):
File "C:\Users\tony.platformio\penv\lib\site-packages\platformio_main.py", line 115, in main
cli() # pylint: disable=no-value-for-parameter
File “C:\Users\tony.platformio\penv\lib\site-packages\click\core.py”, line 1137, in call
return self.main(*args, **kwargs)
File “C:\Users\tony.platformio\penv\lib\site-packages\click\core.py”, line 1062, in main
rv = self.invoke(ctx)
File "C:\Users\tony.platformio\penv\lib\site-packages\platformio\commands_init.py", line 44, in invoke
return super(PlatformioCLI, self).invoke(ctx)
File “C:\Users\tony.platformio\penv\lib\site-packages\click\core.py”, line 1668, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File “C:\Users\tony.platformio\penv\lib\site-packages\click\core.py”, line 1404, in invoke
return ctx.invoke(self.callback, **ctx.params)
File “C:\Users\tony.platformio\penv\lib\site-packages\click\core.py”, line 763, in invoke
return __callback(*args, **kwargs)
File “C:\Users\tony.platformio\penv\lib\site-packages\click\decorators.py”, line 26, in new_func
return f(get_current_context(), *args, **kwargs)
File “C:\Users\tony.platformio\penv\lib\site-packages\platformio\commands\project.py”, line 197, in project_init
pg.generate()
File “C:\Users\tony.platformio\penv\lib\site-packages\platformio\ide\projectgenerator.py”, line 132, in generate
contents = self._render_tpl(tpl_path, tpl_vars)
File “C:\Users\tony.platformio\penv\lib\site-packages\platformio\ide\projectgenerator.py”, line 138, in _render_tpl
return bottle.template(fp.read(), **tpl_vars)
File “C:\Users\tony.platformio\penv\lib\site-packages\bottle.py”, line 3630, in template
return TEMPLATES[tplid].render(kwargs)
File “C:\Users\tony.platformio\penv\lib\site-packages\bottle.py”, line 3419, in render
self.execute(stdout, env)
File “C:\Users\tony.platformio\penv\lib\site-packages\bottle.py”, line 3406, in execute
eval(self.co, env)
File “”, line 77, in
NameError: name ‘includes’ is not defined
============================================================
An unexpected error occurred. Further steps:
============================================================
at spawnOptions.cwd (c:\Users\tony\.vscode\extensions\platformio.platformio-ide-2.3.3\node_modules\platformio-node-helpers\dist\index.js:1:776014) at ChildProcess.a (c:\Users\tony\.vscode\extensions\platformio.platformio-ide-2.3.3\node_modules\platformio-node-helpers\dist\index.js:1:771284) at ChildProcess.emit (events.js:315:20) at ChildProcess.EventEmitter.emit (domain.js:467:12) at ChildProcess.cp.emit (c:\Users\tony\.vscode\extensions\platformio.platformio-ide-2.3.3\node_modules\cross-spawn\lib\enoent.js:34:29) at maybeClose (internal/child_process.js:1048:16) at Process.ChildProcess._handle.onexit (internal/child_process.js:288:5)
v @ console.ts:137
console.ts:137 [Extension Host] runCommand C:\Users\tony.platformio\penv\Scripts\python.exe Array(2) Object
One curious thing I discovered… this is the output which shows up under the folder “Marlin-2.0.8-0525210-SGEN.pio\build\LPC1769Debug\debug”

I found that if I move all those files up one level to Marlin-2.0.8-0525210-SGEN.pio\build\LPC1769Debug (no /debug subfolder), and I adjust the launch.json eliminating the extra /debug folder from “Marlin-2.0.8-0525210-SGEN.pio\build\LPC1769Debug”
“executable”: “C://Users//tony//Documents//CNC/MAINBOARD//Marlin-2.0.8-0525210-SGEN//.pio//build//LPC1769Debug//debug//firmware.elf”, to
“executable”: “C://Users//tony//Documents//CNC/MAINBOARD//Marlin-2.0.8-0525210-SGEN//.pio//build//LPC1769Debug//firmware.elf”,
then PIO Debug will run … but I don’t know why, and this is a lot of work to mess with the folders like that. I never had to do this before, everything used to work fine. It seems like there is a problem finding the output files when that extra “/debug” folder is there. Could there be a limit to the string length of the path?
I’ll try moving the entire project up a few folders to shorten the paths, and see what happens.