初版适配和修改

This commit is contained in:
cyy_mac
2026-08-07 19:04:38 +08:00
parent 460e0e9e73
commit f695460797
17 changed files with 1701 additions and 1 deletions

30
.vscode/c_cpp_properties.json vendored Normal file
View File

@@ -0,0 +1,30 @@
{
"configurations": [
{
"name": "STM32F407ZG (ARM GCC)",
"includePath": [
"${workspaceFolder}/GCC_COMPAT/include",
"${workspaceFolder}/USER",
"${workspaceFolder}/CORE",
"${workspaceFolder}/FWLIB/inc",
"${workspaceFolder}/SYSTEM/**",
"${workspaceFolder}/HARDWARE/**",
"${workspaceFolder}/BALANCE",
"${workspaceFolder}/FreeRTOS/include",
"${workspaceFolder}/FreeRTOS/portable/GCC/ARM_CM4F"
],
"defines": [
"STM32F40_41xxx",
"USE_STDPERIPH_DRIVER",
"ARM_MATH_CM4",
"HSE_VALUE=8000000U",
"__FPU_PRESENT=1",
"__FPU_USED=1"
],
"compilerPath": "/opt/homebrew/bin/arm-none-eabi-gcc",
"cStandard": "c11",
"intelliSenseMode": "linux-gcc-arm"
}
],
"version": 4
}

36
.vscode/launch.json vendored Normal file
View File

@@ -0,0 +1,36 @@
{
"version": "0.2.0",
"configurations": [
{
"name": "DAPLink Debug",
"cwd": "${workspaceFolder}",
"executable": "${workspaceFolder}/build/debug/OriginCar.elf",
"request": "launch",
"type": "cortex-debug",
"device": "STM32F407ZG",
"svdFile": "${workspaceFolder}/../../stm32/stm32f407-gcc-framework/STM32F407.svd",
"servertype": "openocd",
"configFiles": ["${workspaceFolder}/openocd.cfg"],
"preLaunchTask": "Build Debug",
"runToEntryPoint": "main",
"overrideLaunchCommands": [
"monitor reset init",
"load",
"monitor reset init"
],
"liveWatch": { "enabled": true, "samplesPerSecond": 4 }
},
{
"name": "DAPLink Attach",
"cwd": "${workspaceFolder}",
"executable": "${workspaceFolder}/build/debug/OriginCar.elf",
"request": "attach",
"type": "cortex-debug",
"device": "STM32F407ZG",
"svdFile": "${workspaceFolder}/../../stm32/stm32f407-gcc-framework/STM32F407.svd",
"servertype": "openocd",
"configFiles": ["${workspaceFolder}/openocd.cfg"],
"liveWatch": { "enabled": true, "samplesPerSecond": 4 }
}
]
}

6
.vscode/settings.json vendored Normal file
View File

@@ -0,0 +1,6 @@
{
"cortex-debug.armToolchainPath": "/opt/homebrew/bin",
"cortex-debug.openocdPath": "/opt/homebrew/bin/openocd",
"cortex-debug.armToolchainPrefix": "arm-none-eabi",
"cortex-debug.variableUseNaturalFormat": true
}

22
.vscode/tasks.json vendored Normal file
View File

@@ -0,0 +1,22 @@
{
"version": "2.0.0",
"tasks": [
{
"label": "Build Debug",
"type": "shell",
"command": "make",
"args": ["-j8", "BUILD=debug", "all"],
"options": { "cwd": "${workspaceFolder}" },
"group": { "kind": "build", "isDefault": true },
"problemMatcher": ["$gcc"]
},
{
"label": "Flash DAPLink",
"type": "shell",
"command": "make",
"args": ["BUILD=debug", "flash"],
"options": { "cwd": "${workspaceFolder}" },
"problemMatcher": []
}
]
}