launch.json Properties Reference
This document provides a complete, flattened list of all properties supported in your .vscode/launch.json configuration for the MCU-Debug debug adapter.
Understanding the Table
- Property Name / Path: The JSON key path of the configuration property. For nested structures (such as
hostConfigorrttConfig), properties are flattened (e.g.hostConfig.enabled). - Type: The expected data type(s) (e.g.,
string,boolean,number,array, or union types). - Request Mode: Indicates whether the property applies to a
"launch"request, an"attach"request, or"both". - Default & Description: The default value (if any) and a description of the property.
| Property Name / Path | Type | Request Mode | Default & Description |
|---|---|---|---|
armToolchainPath | string | both | This setting can be used to override the armToolchainPath user setting for a particular launch configuration. |
BMPGDBSerialPort | string | both | The serial port for the Black Magic Probe GDB Server. |
boardId | string | both | PyOCD Board Identifier. Needed if multiple compatible boards are connected. |
breakAfterReset | boolean | both | Default: falseApplies to Restart/Reset/Launch, halt debugger after a reset. Ignored if runToEntryPoint is used. |
chainedConfigurations | number | both | Default: 5Default delay in milliseconds. |
chainedConfigurations | boolean | both | Default: falseRelated or independent server sessions. |
chainedConfigurations | boolean | both | Default: trueEnable/Disable entire set of chained configurations |
chainedConfigurations | array | both | List of properties to inherit from parent. |
chainedConfigurations | number | launch | Default: 5Delay in milliseconds. |
chainedConfigurations | boolean | launch | Default: falseRelated or independent server sessions. |
chainedConfigurations | boolean | launch | Default: trueEnable/Disable this configuration |
chainedConfigurations | string | launch | Folder to use for this configuration. |
chainedConfigurations | array | launch | List of properties to inherit from parent. |
chainedConfigurations | boolean | launch | Default: trueAre Reset/Stop/Disconnect shared? |
chainedConfigurations | string | launch | Name of launch configuration. |
chainedConfigurations | object | launch | Values to override/set in this child configuration. |
chainedConfigurations | string | launch | Default: postInitWait for an event. |
chainedConfigurations | boolean | both | Default: trueAre Reset/Stop/Disconnect shared? |
chainedConfigurations | object | both | Values to override/set in this child configuration. |
chainedConfigurations | string | both | Default: postInitEvent to wait for. |
cliOptions | `string | null` | both |
cmsisPack | string | both | Path to a CMSIS-Pack file. Use to add extra device support. |
configFiles | array | both | OpenOCD/PE GDB Server configuration file(s) to use when debugging (OpenOCD -f option) |
cpu | string | both | Default: cortex-m3CPU Type Selection - used for QEMU server type |
cwd | string | both | Directory to run commands from |
debugFlags | boolean | both | Default: falseShow debug output from disassembly operations |
debugFlags | boolean | both | Default: falseDisable GDB command timeouts. Helpful for debugging extension |
debugFlags | boolean | both | Default: falseEnable GDB MI trace output. Copy/Paste friendly. |
debugFlags | boolean | both | Default: falseEnable parsed GDB MI output. NOT Copy/Paste friendly. |
debugFlags | boolean | both | Default: falseEnable live GDB MI trace output during polling (only applies to built-in liveWatch/RTT). Can be super verbose. |
debugFlags | boolean | both | Default: falseShow path resolution when reading symbols |
debugFlags | boolean | both | Default: falseShow timestamps in debug output |
debugFlags | boolean | both | Default: falseEnable VSCode Request/Response trace output |
debuggerArgs | array | both | Additional arguments to pass to GDB command line |
device | string | both | Target Device Identifier, needed for probe-rs and some other server types. For probe-rs, this can be a chip name (e.g. 'STM32F103C8') |
env | object | both | Environment variables defined as key, value pairs to set for the GDB Server process. |
envFile | string | both | Path to a file to read environment variables from for the GDB Server process. The file should have lines in the format KEY=VALUE. |
executable | string | both | Path of executable for symbols and program information. See also loadFiles, symbolFiles |
gdbInterruptMode | string | both | Default: exec-interruptWhether GDB shall be interrupted using "exec-interrupt" (default) or by signaling "SIGINT" |
gdbPath | string | both | This setting can be used to override the GDB path user/workspace setting for a particular launch configuration. |
gdbTarget | string | both | For externally (servertype = "external") controlled GDB Servers you must specify the GDB target to connect to. |
graphConfig | array | both | Description of how graphing can be done. |
hardwareBreakpoints | number | both | Default: 0If limit > 0, enforce a limit on the number of hardware breakpoints that can be used |
hardwareBreakpoints | boolean | both | Default: falseIf true, forces the use of hardware breakpoints |
hardwareWatchpoints | number | both | Default: 0If limit > 0, enforce a limit on the number of hardware watchpoints that can be used |
hardwareWatchpoints | boolean | both | Default: falseIf true, forces the use of hardware watchpoints |
hostConfig | `object | boolean` | both |
hostConfig | boolean | both | Default: trueEnable/Disable remote probe support. When true, the gdb-server runs on a host machine that has the USB debug probe attached. |
hostConfig | string | both | Address the debug adapter should dial to reach the Probe Agent, from wherever the adapter runs. Examples: "127.0.0.1" for the same machine, "host.docker.internal" from a Docker Desktop container, or a WSL gateway / LAN address. Must be an address the agent is actually bound to — check with mcu-debug proxy --status and look at hosts. |
hostConfig | number | both | Port the Probe Agent is listening on. Shown as port in mcu-debug proxy --status. |
hostConfig | string | both | Authentication token the agent was started with. Prefer "${env:MDBG_PROXY_TOKEN}" over a literal — a token committed to source control is a shared secret in your repository. The agent reads the same MDBG_PROXY_TOKEN variable, so one export configures both ends. |
hostConfig | string | both | Default: mylogin@myserverSSH host, resolved via ~/.ssh/config — so aliases, port, jump hosts and keys are all handled there. Example: "user@lab-server", or an alias defined in ~/.ssh/config. |
hostConfig | number | both | Daemon mode: the port a Probe Agent is already listening on at the SSH host. When set, the extension connects to that agent instead of launching one, and the SSH -L tunnel is established from an OS-assigned local port to this one. When omitted, a new Probe Agent is launched per debug session and its port read from the Discovery JSON. Set this when the agent is started manually or managed by a system service on the probe host. |
hostConfig | string | both | Path to a pre-installed mcu-debug binary on the SSH host (e.g. "/usr/local/bin/mcu-debug"). When set, the extension skips deploying the binary and launches this path directly. Use it when the host has the tool installed already, or when writing to ~/.mcu-debug/bin is not permitted. |
hostConfig | string | both | Authentication token of the pre-running agent named by proxyPort. Required with proxyPort, since an agent we did not launch has a token we cannot know. Ignored otherwise — an agent we launch is given a freshly generated token. Prefer "${env:MDBG_PROXY_TOKEN}" over a literal: a token committed to source control is a shared secret in your repository, and the agent reads the same variable. |
hostConfig | string | both | Glob pattern for files to sync, relative to ${cwd}. Example: '*.cfg'. |
hostConfig | string | both | Remote path to sync the files to. If not specified, the local path is used. |
hostConfig | any | both | Default: auto"auto": extension detects the VS Code remote environment and constructs the correct proxy address automatically. Covers WSL (NAT and Mirrored), Dev Containers, VS Code Remote SSH, and plain local. "ssh": explicit SSH to a separate probe host; requires the ssh object below. |
interface | string | both | Default: swdDebug Interface type to use for connections (defaults to SWD) - Used for J-Link, ST-LINK and BMP probes. |
ipAddress | string | both | IP Address for networked J-Link Adapter |
jlinkscript | string | both | J-Link script file - optional input file for customizing J-Link actions. |
liveWatch | boolean | both | Default: falseEnable/Disable Live Watch. |
liveWatch | number | both | Default: 2Maximum number of samples per second. |
loadFiles | array | both | List of files (hex/bin/elf files) to load/program instead of the executable file. |
machine | string | both | Default: lm3s811evbMachine Type Selection - used for QEMU server type |
numberOfProcessors | number | both | Default: 1Number of processors/cores in the target device. |
objdumpPath | string | both | This setting can be used to override the objdump path user/workspace setting for a particular launch configuration. |
openOCDLaunchCommands | array | launch | OpenOCD command(s) after configuration files are loaded (-c options) |
openOCDPreConfigLaunchCommands | array | launch | OpenOCD command(s) before configuration files are loaded (-c options) |
overrideAttachCommands | array | attach | Override the commands that are normally executed as part of attaching to a running target. |
overrideGDBServerStartedRegex | string | both | You can supply a regular expression to override the output from the GDB Server that is looked for to determine if the GDB Server has started. |
overrideLaunchCommands | array | launch | Override the commands that are normally executed as part of flashing and launching the target. |
overridePreEndSessionCommands | array | both | Override the commands that are normally executed at the start of ending a debug session (e.g. when stopping debugging). |
overrideResetCommands | array | both | Override the commands that are normally executed as part of reset-ing the target. |
overrideRestartCommands | array | both | Deprecated: Restart is now handled by VSCode. Change to overrideResetCommands if you use the Reset button. |
postAttachCommands | array | attach | Additional GDB Commands to be executed after the main attach sequence has finished. |
postLaunchCommands | array | launch | Additional GDB Commands to be executed after the main launch sequence has finished. |
postResetCommands | array | both | Commands to be executed after a Reset operation, after the reset is sent to the target. |
postResetSessionCommands | array | both | Additional GDB Commands to be executed at the end of the reset sequence |
postRestartCommands | array | both | Deprecated: Restart is now handled by VSCode. Change to postResetCommands if you use the Reset button. |
postRestartSessionCommands | array | both | Deprecated: Restart is now handled by VSCode and it is the same as Start. If you are using the Reset button, use postResetSessionCommands instead |
postStartSessionCommands | array | both | Additional GDB Commands to be executed at the end of the start sequence, after a debug session has already started and runToEntryPoint is not specified. |
powerOverBMP | string | both | Power up the board over Black Magic Probe. |
preAttachCommands | array | attach | Additional GDB Commands to be executed at the start of the main attach sequence (immediately after attaching to target). |
preLaunchCommands | array | launch | Additional GDB Commands to be executed at the start of the main launch sequence (immediately after attaching to target). |
preResetCommands | array | both | Commands to be executed prior to a Reset operation, before the reset is sent to the target. |
routeGdbServerOutputToDebugConsole | boolean | both | Default: falseRoute GDB server output to debug console |
rtos | string | both | RTOS being used. For JLink this can be Azure, ChibiOS, embOS, FreeRTOS, NuttX, Zephyr or the path to a custom JLink RTOS Plugin library. For OpenOCD this can be auto (recommended), FreeRTOS, ThreadX, chibios, Chromium-EC, eCos, embKernel, linux, mqx, nuttx, RIOT, uCOS-III, or Zephyr. |
rttConfig | string | both | Default: autoAddress to start searching for the RTT control block. |
rttConfig | boolean | both | Default: trueWhen true, clears the search-string. |
rttConfig | array | both | SWO Decoder Configuration |
rttConfig | boolean | both | Default: falseEnable/Disable RTT |
rttConfig | `number | null` | both |
rttConfig | array | both | Default: ["-e","$\{executable\}"]Arguments to pass to pre-decoder program. |
rttConfig | `array | null` | both |
rttConfig | string | both | Default: $\{workspaceFolder\}Current working directory for pre-decoder program. |
rttConfig | object | both | Additional environment variables for pre-decoder program. |
rttConfig | string | both | Default: defmt-printPath to pre-decoder program. |
rttConfig | number | both | Default: 1000Keep trying to start RTT for OpenOCD until it succeeds. |
rttConfig | string | both | Default: SEGGER RTTA string to search for to find the RTT control block. |
rttConfig | number | both | Default: 16Number of bytes to search for the RTT control block. |
rttConfig | `boolean | object` | both |
rttConfig | boolean | both | Default: trueEnable/Disable built-in RTT support |
rttConfig | string | both | Default: 127.0.0.1Host name to use for built-in RTT server. |
rttConfig | `number | null` | both |
runToEntryPoint | string | launch | Default: mainApplies to Launch/Restart/Reset, ignored for Attach. If enabled the debugger will run until the start of the given function. |
runToMain | boolean | both | Default: falseDeprecated: please use 'runToEntryPoint' instead. |
searchDir | array | both | OpenOCD directories to search for config files and scripts (-s option). |
serialConfig | boolean | both | Default: falseEnable/Disable serial port bridging. When enabled, the extension creates TCP bridges to physical serial ports for easy access to serial output from the target device. |
serialConfig | array | both | List of serial port bridges to expose as TCP ports. Each entry maps a physical serial device to a TCP port that can be connected to for bidirectional communication. |
serialConfig | number | both | Default: 115200Baud rate in bits per second. |
serialConfig | number | both | Default: 8Number of data bits per frame. |
serialConfig | string | both | Default: noneFlow control mode. "software" = XON/XOFF, "hardware" = RTS/CTS. |
serialConfig | string | both | Default: cookedInput mode for data sent to the serial port. "raw" = send as-is, immediately, "cooked" = buffer input until Enter is pressed and perform basic line editing (backspace, Ctrl+U to clear line). |
serialConfig | string | both | A label for this serial port bridge, used in the extension UI to identify it. E.g. 'Debug UART'. Optional but recommended when multiple ports are configured. |
serialConfig | string | both | Optional file path to log all serial data (both input and output). If not set, no logging is performed. |
serialConfig | string | both | Case-insensitive substring matched against the port's description as reported by the OS (e.g. 'STM32 STLink', 'FTDI'). Used for selection, along with path, serial, or vid/pid. Use 'label' to name the port in the UI. |
serialConfig | string | both | Default: noneParity checking mode. |
serialConfig | string | both | Serial device path or glob. E.g. /dev/ttyUSB0, /dev/tty.usbserial-, COM3, /dev/serial/by-id/usb-. Optional if serial or vid/pid are specified. |
serialConfig | string | both | USB product ID in hex (e.g. "0x374b"). Used with vid to identify the device type when serial is unavailable. |
serialConfig | string | both | USB serial number. Stable across reconnects and reboots — preferred in lab environments with multiple boards of the same type. |
serialConfig | string | both | Default: oneNumber of stop bits. |
serialConfig | string | both | USB vendor ID in hex (e.g. "0x0483"). Used with pid to identify the device type when serial is unavailable. |
serialNumber | string | both | J-Link or ST-LINK Serial Number - only needed if multiple J-Links/ST-LINKs are connected to the computer |
serverArgs | array | both | Additional arguments to pass to GDB Server command line |
serverpath | string | both | This setting can be used to override the GDB Server path user/workspace setting for a particular launch configuration. |
servertype | string | both | GDB Server type - supported types are jlink, openocd, probe-rs, pyocd, pe, stlink, stutil, qemu, bmp and external. For "external", please read our Wiki. The executable in your PATH is used by default, to override this use serverpath. |
stlinkPath | string | both | Path to the ST-LINK_gdbserver executable. |
stm32cubeprogrammer | string | both | This path is normally resolved to the installed STM32CubeIDE or STM32CubeProgrammer but can be overridden here. |
svdFile | string | both | This is for 'XPERIPHERALS' window provided by 'mcu-debug.peripheral-viewer'. |
svdPath | string | both | This is for 'XPERIPHERALS' window provided by 'mcu-debug.peripheral-viewer' and 'Embedded Tools' Extension from Microsoft. |
swoConfig | number | both | Default: 0Target CPU frequency in Hz; 0 will attempt to automatically calculate. |
swoConfig | array | both | SWO Decoder Configuration |
swoConfig | boolean | both | Default: falseEnable SWO decoding. |
swoConfig | string | both | Default: probeSource for SWO data. |
swoConfig | string | both | Default: uartBMP only: SWO encoding data used at the line level. |
swoConfig | number | both | Default: 0SWO frequency in Hz; 0 will attempt to automatically calculate. |
swoConfig | string | both | Path name when source is "file" or "serial". |
swoConfig | string | both | When server is "external" && source is "socket", port to connect to. |
symbolFiles | array | both | Array of ELF files to load symbols from instead of the executable file. |
symbolFiles[] | string | both | Pathname of an ELF file for symbols |
symbolFiles[] | `number | string` | both |
symbolFiles[] | `number | string` | both |
symbolFiles[] | string | both | Section name |
symbolFiles[] | `number | string` | both |
targetId | `string | number` | both |
targetProcessor | number | both | Default: 0The processor you want to debug. Zero based integer index. Must be less than 'numberOfProcessors' |
toolchainPrefix | string | both | This setting can be used to override the toolchainPrefix user setting for a particular launch configuration. Default = "arm-none-eabi" |
v1 | boolean | both | Default: falseFor st-util only. Set this to true if your debug probe is a ST-Link V1. |