51单片机c_cpp_properties.json配置
时间: 2023-08-08 20:09:59 浏览: 200
c_cpp_properties.json
在使用 VSCode 进行 51 单片机开发时,需要配置 C/C++ 扩展的 c_cpp_properties.json 文件,以下是一个示例配置:
```json
{
"configurations": [
{
"name": "Win32",
"includePath": [
"${workspaceFolder}/**",
"C:/Keil_v5/ARM/INC",
"C:/Keil_v5/C51/INC"
],
"defines": [
"_DEBUG",
"UNICODE",
"_UNICODE"
],
"compilerPath": "C:/Keil_v5/C51/BIN/C51.EXE",
"cStandard": "c11",
"cppStandard": "c++17",
"intelliSenseMode": "msvc-x64",
"browse": {
"path": [
"${workspaceFolder}/**"
],
"limitSymbolsToIncludedHeaders": true,
"databaseFilename": ""
}
}
],
"version": 4
}
```
其中,"compilerPath" 需要根据自己的 Keil 安装路径进行修改。"includePath" 需要添加自己使用的头文件路径。
阅读全文