Closed XIVN1987 closed 2 years ago
Every time starting debug, cortex-debug will download executable to mcu flash. How start debugging without download?
my cortex-debug configuration:
"type": "cortex-debug", "name": "Cortex Debug", "cwd": "${workspaceRoot}/ports/m480", "executable": "./build-M482Lite/micropython.elf", "runToMain": true, "request": "launch", "servertype": "pyocd", "targetId": "m487jidae", "svdFile": "./M481_v1.svd",
Terminal output:
[2022-01-03T05:44:25.031Z] SERVER CONSOLE DEBUG: onBackendConnect: gdb-server session connected. You can switch to "DEBUG CONSOLE" to see GDB interactions. 0000859:WARNING:common:STLink, CMSIS-DAPv2 and PicoProbe probes are not supported because no libusb library was found. 0000958:INFO:board:Target type is m487jidae 0000994:INFO:dap:DP IDR = 0x2ba01477 (v1 rev2) 0001029:INFO:ap:AHB-AP#0 IDR = 0x24770011 (AHB-AP var1 rev2) 0001051:INFO:rom_table:AHB-AP#0 Class 0x1 ROM table #0 @ 0xe00ff000 (designer=43b part=4c4) 0001058:INFO:rom_table:[0]<e000e000:SCS-M4 class=14 designer=43b part=00c> 0001063:INFO:rom_table:[1]<e0001000:DWT class=14 designer=43b part=002> 0001068:INFO:rom_table:[2]<e0002000:FPB class=14 designer=43b part=003> 0001103:INFO:rom_table:[3]<e0000000:ITM class=14 designer=43b part=001> 0001108:INFO:rom_table:[4]<e0040000:TPIU-M4 class=9 designer=43b part=9a1 devtype=11 archid=0000 devid=ca1:0:0> 0001113:INFO:rom_table:[5]<e0041000:ETM-M4 class=9 designer=43b part=925 devtype=13 archid=0000 devid=0:0:0> 0001115:INFO:cortex_m:CPU core #0 is Cortex-M4 r0p1 0001124:INFO:cortex_m:FPU present: FPv4-SP-D16-M 0001128:INFO:dwt:4 hardware watchpoints 0001132:INFO:fpb:6 hardware breakpoints, 4 literal comparators 0001364:INFO:server:Semihost server started on port 50002 (core 0) 0001401:INFO:gdbserver:GDB server started on port 50001 (core 0) 0001583:INFO:gdbserver:Client connected to port 50001! 0001638:INFO:gdbserver:Attempting to load argon 0001638:INFO:gdbserver:Attempting to load freertos 0001639:INFO:gdbserver:Attempting to load rtx5 0001639:INFO:gdbserver:Attempting to load threadx 0001639:INFO:gdbserver:Attempting to load zephyr [---|---|---|---|---|---|---|---|---|----] [========================================] 0023593:INFO:loader:Erased 446464 bytes (109 sectors), programmed 446464 bytes (109 pages), skipped 0 bytes (0 pages) at 20.00 kB/s
You'd use a "request": "attach" to debug an already flashed device without re-flash (and restarting - although you can manually restart the code once connected).
Every time starting debug, cortex-debug will download executable to mcu flash. How start debugging without download?
my cortex-debug configuration:
Terminal output: