Template
- tasks.json: Build + Flash/Reset/Erase via JLink Commander - launch.json: cortex-debug J-Link debug configuration - flash.jlink: JLink Commander script for automated flashing - extensions.json: recommended VSCode extensions - .gitignore: remove .vscode/ exclusion (template needs these files)
112 lines
3.1 KiB
JSON
112 lines
3.1 KiB
JSON
{
|
|
"version": "2.0.0",
|
|
"tasks": [
|
|
{
|
|
"label": "Build",
|
|
"type": "cmake",
|
|
"command": "build",
|
|
"group": {
|
|
"kind": "build",
|
|
"isDefault": true
|
|
},
|
|
"problemMatcher": [
|
|
{
|
|
"base": "$gcc",
|
|
"fileLocation": [
|
|
"relative",
|
|
"${command:cmake.buildDirectory}"
|
|
]
|
|
}
|
|
],
|
|
"options": {
|
|
"environment": {
|
|
"CLICOLOR_FORCE": "1"
|
|
}
|
|
},
|
|
"presentation": {
|
|
"clear": true
|
|
},
|
|
"icon": {
|
|
"id": "code",
|
|
"tooltip": "Build"
|
|
}
|
|
},
|
|
{
|
|
"label": "Build and Flash (Jlink)",
|
|
"group": {
|
|
"kind": "build",
|
|
"isDefault": true
|
|
},
|
|
"dependsOn": [
|
|
"Build",
|
|
"Flash MCU (Jlink)"
|
|
],
|
|
"dependsOrder": "sequence",
|
|
"icon": {
|
|
"id": "insert",
|
|
"tooltip": "Build and Flash (Jlink)"
|
|
}
|
|
},
|
|
{
|
|
"label": "Flash MCU (Jlink)",
|
|
"type": "shell",
|
|
"command": "JLink.exe -device GD32E230F8 -if SWD -speed 4000 -autoconnect 1 -CommanderScript '${workspaceFolder}/.vscode/flash.jlink'",
|
|
"group": {
|
|
"kind": "build",
|
|
"isDefault": true
|
|
},
|
|
"problemMatcher": [],
|
|
"options": {
|
|
"cwd": "${command:cmake.buildDirectory}/Application"
|
|
},
|
|
"presentation": {
|
|
"clear": true
|
|
},
|
|
"icon": {
|
|
"id": "gather",
|
|
"tooltip": "Flash MCU (Jlink)"
|
|
}
|
|
},
|
|
{
|
|
"label": "Reset MCU (Jlink)",
|
|
"type": "shell",
|
|
"command": "JLink.exe -device GD32E230F8 -if SWD -speed 4000 -autoconnect 1 -c \"r;exit\"",
|
|
"group": {
|
|
"kind": "build",
|
|
"isDefault": true
|
|
},
|
|
"problemMatcher": [],
|
|
"options": {
|
|
"cwd": "${workspaceFolder}"
|
|
},
|
|
"presentation": {
|
|
"clear": true
|
|
},
|
|
"icon": {
|
|
"id": "discard",
|
|
"tooltip": "Reset MCU (Jlink)"
|
|
}
|
|
},
|
|
{
|
|
"label": "Mass Erase MCU (Jlink)",
|
|
"type": "shell",
|
|
"command": "JLink.exe -device GD32E230F8 -if SWD -speed 4000 -autoconnect 1 -c \"erase;exit\"",
|
|
"group": {
|
|
"kind": "build",
|
|
"isDefault": true
|
|
},
|
|
"problemMatcher": [],
|
|
"options": {
|
|
"cwd": "${workspaceFolder}"
|
|
},
|
|
"presentation": {
|
|
"clear": true
|
|
},
|
|
"icon": {
|
|
"id": "clear-all",
|
|
"tooltip": "Erase MCU (Jlink)"
|
|
}
|
|
}
|
|
]
|
|
}
|