Skip to content

Commit e529328

Browse files
authored
Add debugging local and remote (container) support for all GSG's.
* debugging support. * improve toolchain arm compiler detection * update to cmake 3.18.2
1 parent b3e2a65 commit e529328

File tree

19 files changed

+47986
-96
lines changed

19 files changed

+47986
-96
lines changed

.devcontainer/Dockerfile

Lines changed: 0 additions & 12 deletions
This file was deleted.

.devcontainer/devcontainer.json

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,14 @@
11
// For format details, see https://aka.ms/vscode-remote/devcontainer.json
22
{
3-
"image": "kartben/azurertos-gnuarm:latest",
3+
"image": "ryanwinter/arm-none-eabi-gcc:latest",
44
"extensions": [
5-
"ms-vscode.cpptools",
6-
"ms-vscode.cmake-tools",
7-
"marus25.cortex-debug",
8-
"vsciot-vscode.vscode-iot-workbench",
9-
"xaver.clang-format",
10-
],
5+
"ms-vscode.cpptools",
6+
"ms-vscode.cmake-tools",
7+
"marus25.cortex-debug",
8+
"vsciot-vscode.vscode-iot-workbench",
9+
"xaver.clang-format",
10+
"ms-azuretools.vscode-docker"
11+
],
1112
"remoteUser": "vscode",
12-
"postCreateCommand": "git submodule update --recursive --init",
13+
"postCreateCommand": "git submodule update --recursive --init"
1314
}
File renamed without changes.

MXChip/AZ3166/.vscode/cmake-kits.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
[
2+
{
3+
"name": "ARM GCC Cortex",
4+
"toolchainFile": "${workspaceFolder}/../../cmake/arm-gcc-cortex-m4.cmake"
5+
}
6+
]

MXChip/AZ3166/.vscode/launch.json

Lines changed: 34 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -1,42 +1,37 @@
11
{
2-
// Use IntelliSense to learn about possible attributes.
3-
// Hover to view descriptions of existing attributes.
4-
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
52
"version": "0.2.0",
63
"configurations": [
7-
{
8-
"type": "cortex-debug",
9-
"request": "launch",
10-
"servertype": "openocd",
11-
"armToolchainPath": "C:\\Program Files (x86)\\GNU Arm Embedded Toolchain\\9 2020-q2-update\\bin",
12-
"cwd": "${workspaceRoot}/build/app",
13-
"executable": "${input:sampleName}.elf",
14-
"name": "(OpenOCD) Cortex Debug",
15-
"device": "STM32F412RG",
16-
"runToMain": true,
17-
"interface": "swd",
18-
"configFiles": [
19-
"interface/stlink.cfg",
20-
"target/stm32f4x.cfg"
21-
],
22-
"svdFile": "${cwd}/STM32F412.svd",
23-
"swoConfig": {
24-
"enabled": true,
25-
"cpuFrequency": 10000000,
26-
"swoFrequency": 2000000,
27-
"source": "probe"
28-
},
29-
},
30-
],
31-
"inputs": [
32-
{
33-
"type": "pickString",
34-
"id": "sampleName",
35-
"description": "Which sample do you want to download and debug?",
36-
"options": [
37-
"mxchip_azure_iot"
38-
],
39-
"default": "mxchip_azure_iot"
40-
}
41-
]
42-
}
4+
{
5+
"name": "MXCHIP: Local OpenOCD",
6+
"type": "cortex-debug",
7+
"request": "launch",
8+
"servertype": "openocd",
9+
"device": "STM32F412RG",
10+
"runToMain": true,
11+
"executable": "${workspaceFolder}/build/app/mxchip_azure_iot.elf",
12+
"svdFile": "${workspaceFolder}/.vscode/STM32F412.svd",
13+
"cwd": "${workspaceRoot}",
14+
"configFiles": [
15+
"board/stm32f4discovery.cfg"
16+
]
17+
},
18+
{
19+
"name": "MXCHIP: Remote",
20+
"type": "cortex-debug",
21+
"executable": "${workspaceFolder}/build/app/mxchip_azure_iot.elf",
22+
"request": "launch",
23+
"servertype": "external",
24+
"gdbTarget": "${input:device.host}",
25+
"runToMain": true,
26+
"svdFile": "${workspaceFolder}/.vscode/STM32F412.svd",
27+
}
28+
],
29+
"inputs": [
30+
{
31+
"id": "device.host",
32+
"type": "promptString",
33+
"default": "localhost:3333",
34+
"description": "The local hostname with port for GDB to connect to"
35+
}
36+
]
37+
}

MXChip/AZ3166/AZ3166.code-workspace

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
{
2+
"folders": [
3+
{
4+
"path": "."
5+
}
6+
],
7+
"settings": {
8+
"git.ignoreLimitWarning": true,
9+
"git.autofetch": true,
10+
"git.confirmSync": false,
11+
"cmake.configureOnOpen": true,
12+
"C_Cpp.default.configurationProvider": "ms-vscode.cmake-tools"
13+
}
14+
}

0 commit comments

Comments
 (0)