mirror of
https://github.com/DarkFlippers/unleashed-firmware
synced 2024-11-26 22:40:25 +00:00
f57f0efc48
* Debug: revert cortex debug to lxml * Debug: update PyCortexMDebug readme * fbt: moved "debug" dir to "scripts" subfolder * ufbt: added missing debug_other & debug_other_blackmagic targets; github: fixed script bundling * lint: fixed formatting on debug scripts * vscode: updated configuration for debug dir changes --------- Co-authored-by: hedger <hedger@users.noreply.github.com> Co-authored-by: hedger <hedger@nanode.su>
120 lines
No EOL
4.4 KiB
JSON
120 lines
No EOL
4.4 KiB
JSON
{
|
|
// Use IntelliSense to learn about possible attributes.
|
|
// Hover to view descriptions of existing attributes.
|
|
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
|
|
"version": "0.2.0",
|
|
"inputs": [
|
|
{
|
|
"id": "BLACKMAGIC",
|
|
"type": "command",
|
|
"command": "shellCommand.execute",
|
|
"args": {
|
|
"useSingleResult": true,
|
|
"env": {
|
|
"PATH": "${workspaceFolder}${command:extension.commandvariable.envListSep}${env:PATH}"
|
|
},
|
|
"command": "fbt -s get_blackmagic",
|
|
"description": "Get Blackmagic device"
|
|
}
|
|
}
|
|
],
|
|
"configurations": [
|
|
{
|
|
"name": "Attach FW (ST-Link)",
|
|
"cwd": "${workspaceFolder}",
|
|
"executable": "./build/latest/firmware.elf",
|
|
"request": "attach",
|
|
"type": "cortex-debug",
|
|
"servertype": "openocd",
|
|
"device": "stlink",
|
|
"svdFile": "./scripts/debug/STM32WB55_CM4.svd",
|
|
// If you're debugging early in the boot process, before OS scheduler is running,
|
|
// you have to comment out the following line.
|
|
"rtos": "FreeRTOS",
|
|
"configFiles": [
|
|
"interface/stlink.cfg",
|
|
"./scripts/debug/stm32wbx.cfg",
|
|
],
|
|
"postAttachCommands": [
|
|
"source scripts/debug/flipperversion.py",
|
|
"fw-version",
|
|
// "compare-sections",
|
|
"source scripts/debug/flipperapps.py",
|
|
"fap-set-debug-elf-root build/latest/.extapps",
|
|
// "source scripts/debug/FreeRTOS/FreeRTOS.py",
|
|
]
|
|
// "showDevDebugOutput": "raw",
|
|
},
|
|
{
|
|
"name": "Attach FW (blackmagic)",
|
|
"cwd": "${workspaceFolder}",
|
|
"executable": "./build/latest/firmware.elf",
|
|
"request": "attach",
|
|
"type": "cortex-debug",
|
|
"servertype": "external",
|
|
"gdbTarget": "${input:BLACKMAGIC}",
|
|
"svdFile": "./scripts/debug/STM32WB55_CM4.svd",
|
|
"rtos": "FreeRTOS",
|
|
"postAttachCommands": [
|
|
"monitor swdp_scan",
|
|
"attach 1",
|
|
"set confirm off",
|
|
"set mem inaccessible-by-default off",
|
|
"source scripts/debug/flipperversion.py",
|
|
"fw-version",
|
|
"source scripts/debug/flipperapps.py",
|
|
"fap-set-debug-elf-root build/latest/.extapps",
|
|
// "compare-sections",
|
|
]
|
|
// "showDevDebugOutput": "raw",
|
|
},
|
|
{
|
|
"name": "Attach FW (JLink)",
|
|
"cwd": "${workspaceFolder}",
|
|
"executable": "./build/latest/firmware.elf",
|
|
"request": "attach",
|
|
"type": "cortex-debug",
|
|
"servertype": "jlink",
|
|
"interface": "swd",
|
|
"device": "STM32WB55RG",
|
|
"svdFile": "./scripts/debug/STM32WB55_CM4.svd",
|
|
"rtos": "FreeRTOS",
|
|
"postAttachCommands": [
|
|
"source scripts/debug/flipperversion.py",
|
|
"fw-version",
|
|
"source scripts/debug/flipperapps.py",
|
|
"fap-set-debug-elf-root build/latest/.extapps",
|
|
]
|
|
// "showDevDebugOutput": "raw",
|
|
},
|
|
{
|
|
"name": "Attach FW (DAP)",
|
|
"cwd": "${workspaceFolder}",
|
|
"executable": "./build/latest/firmware.elf",
|
|
"request": "attach",
|
|
"type": "cortex-debug",
|
|
"servertype": "openocd",
|
|
"device": "cmsis-dap",
|
|
"svdFile": "./scripts/debug/STM32WB55_CM4.svd",
|
|
"rtos": "FreeRTOS",
|
|
"configFiles": [
|
|
"interface/cmsis-dap.cfg",
|
|
"./scripts/debug/stm32wbx.cfg",
|
|
],
|
|
"postAttachCommands": [
|
|
"source scripts/debug/flipperversion.py",
|
|
"fw-version",
|
|
"source scripts/debug/flipperapps.py",
|
|
"fap-set-debug-elf-root build/latest/.extapps",
|
|
],
|
|
// "showDevDebugOutput": "raw",
|
|
},
|
|
{
|
|
"name": "python debug",
|
|
"type": "python",
|
|
"request": "launch",
|
|
"program": "${file}",
|
|
"args": []
|
|
}
|
|
]
|
|
} |