diff options
Diffstat (limited to '.vscode')
-rw-r--r-- | .vscode/c_cpp_properties.json | 9 | ||||
-rw-r--r-- | .vscode/extensions.json | 7 | ||||
-rw-r--r-- | .vscode/launch.json | 47 | ||||
-rw-r--r-- | .vscode/settings.json | 12 | ||||
-rw-r--r-- | .vscode/tasks.json | 77 |
5 files changed, 152 insertions, 0 deletions
diff --git a/.vscode/c_cpp_properties.json b/.vscode/c_cpp_properties.json new file mode 100644 index 0000000..51f5ad0 --- /dev/null +++ b/.vscode/c_cpp_properties.json @@ -0,0 +1,9 @@ +{ + "configurations": [ + { + "name": "src", + "compileCommands": "${workspaceFolder}/src/compile_commands.json" + } + ], + "version": 4 +}
\ No newline at end of file diff --git a/.vscode/extensions.json b/.vscode/extensions.json new file mode 100644 index 0000000..f4800ac --- /dev/null +++ b/.vscode/extensions.json @@ -0,0 +1,7 @@ +{ + "recommendations": [ + "marus25.cortex-debug", + "ms-vscode.cpptools-extension-pack", + "EditorConfig.EditorConfig" + ] +} diff --git a/.vscode/launch.json b/.vscode/launch.json new file mode 100644 index 0000000..2f7561c --- /dev/null +++ b/.vscode/launch.json @@ -0,0 +1,47 @@ +{ + "version": "0.2.0", + "configurations": [ + { + "name": "ppusim debug", + "type": "cppdbg", + "request": "launch", + "program": "${workspaceFolder}/src/main", + "windows": { "program": "${workspaceFolder}/src/main.exe" }, + "args": [], + "cwd": "${fileDirname}", + "environment": [], + "externalConsole": false, + "MIMode": "gdb", + "preLaunchTask": "client/build", + "setupCommands": [ + { + "description": "Enable pretty-printing for gdb", + "text": "-enable-pretty-printing", + "ignoreFailures": true + }, + { + "description": "Set Disassembly Flavor to Intel", + "text": "-gdb-set disassembly-flavor intel", + "ignoreFailures": true + } + ] + }, + { + "name": "stm32 debug", + "cwd": "${workspaceFolder}", + "executable": "${workspaceFolder}/src/main.elf", + "request": "launch", + "type": "cortex-debug", + "servertype": "stlink", + "preLaunchTask": "stm32/flash", + "linux": { + "stlinkPath": "/usr/bin/st-util" + }, + "windows": { + "armToolchainPath": "C:/msys64/mingw64/bin", + "stlinkPath": "C:/msys64/mingw64/bin/st-util.exe", + "gdbPath": "C:/msys64/mingw64/bin/gdb-multiarch.exe" + } + } + ] +} diff --git a/.vscode/settings.json b/.vscode/settings.json new file mode 100644 index 0000000..d027762 --- /dev/null +++ b/.vscode/settings.json @@ -0,0 +1,12 @@ +{ + "terminal.integrated.defaultProfile.windows": "MSYS2 MinGW x64", + "terminal.integrated.profiles.windows": { + "MSYS2 MinGW x64": { + "path": [ "C:/msys64/msys2_shell.cmd" ], + "args": [ "-defterm", "-no-start", "-mingw64", "-shell", "sh", "-here" ], + "icon": "terminal-bash" + } + }, + "cmake.configureOnOpen": false, + "files.eol": "\n" +} diff --git a/.vscode/tasks.json b/.vscode/tasks.json new file mode 100644 index 0000000..53a235e --- /dev/null +++ b/.vscode/tasks.json @@ -0,0 +1,77 @@ +{ + "version": "2.0.0", + "windows": { + "options": { + "cwd": "${workspaceFolder}", + "shell": { + "executable": "C:/msys64/msys2_shell.cmd", + "args": [ "-defterm", "-no-start", "-mingw64", "-shell", "sh", "-here", "-c" ] + }, + }, + }, + "tasks": [ + { + "label": "build", + "group": { + "isDefault": false, + "kind": "build" + }, + "options": { "cwd": "${workspaceFolder}/src" }, + "windows": { + "command": "make -j", + "args": [ "" ], + }, + "command": "make", + "args": [ "-j" ], + "type": "shell" + }, + { + "label": "flash", + "detail": "build and upload to stm32", + "group": { + "isDefault": false, + "kind": "test" + }, + "options": { "cwd": "${workspaceFolder}/src" }, + "windows": { + "command": "make -j flash", + "args": [ "" ], + }, + "command": "make", + "args": [ "-j", "flash" ], + "type": "shell" + }, + { + "label": "compiledb", + "detail": "generate editor autocomplete files", + "group": { + "isDefault": false, + "kind": "test" + }, + "options": { "cwd": "${workspaceFolder}/src" }, + "windows": { + "command": "make compile_commands.json", + "args": [ "" ], + }, + "command": "make", + "args": [ "compile_commands" ], + "type": "shell" + }, + { + "label": "clean", + "detail": "remove binary files from working directory", + "group": { + "isDefault": false, + "kind": "test" + }, + "options": { "cwd": "${workspaceFolder}" }, + "windows": { + "command": "make clean", + "args": [ "" ], + }, + "command": "make", + "args": [ "clean" ], + "type": "shell" + } + ] +} |