This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
我正在尝试使用内置 API、以便通过 UART 与电路板连接。 我无法编译代码、因为我收到未声明 SOC_ModuleID 的错误。 我尝试在 SDK 1.02版和2.00版中编译、但每个版本都有相同的问题。
这是我收到的错误消息。
在/home/parallels/ti/mmwave_sdk_02_00_00_04/packages/ti/control/mmwave/mmwave.h:164:0文件中、
从 driver.cpp:13:
/home/parallels/ti/mmwave_sdk_02_00_00_04/packages/ti/drivers/soc/soc.h:347:61:error:‘SOC_ModuleId’has not been declared (OC_ModuleId’未声明)
extern Int32_t SOC_setPeripheralClock (SOC_Handle handle、SOC_ModuleId 模块、SOC_PeripheralClkSource clkSource clkSource、
^μ A
/home/parallels/ti/mmwave_sdk_02_00_00_04/packages/ti/drivers/soc/soc.h:348:57:‘S:尚未声明‘OC_ModuleId’
extern Int32_t SOC_initPeripheralRam (SOC_Handle handle、SOC_ModuleId 模块、Int32_t* errCode);
问题出在包含 soc.h 我包含了 mmwave.h、其中包括 SoC.h 当我在主代码中不使用代码进行编译并且仅使用 mmWave.h 进行编译时、我会收到错误 此错误位于 soc.h 中、我在下载和构建 SDK 时未修改该错误。 编译和错误如下:
G++-Wall -std=c++11 -o 驱动程序 driver.cpp -i/home/Parallels/ti/mmwave_sdk_01_02_00_05/packages/
在/home/parallels/ti/mmwave_sdk_01_02_00_05/packages/ti/control/mmwave/mmwave.h:164:0文件中、
从 driver.cpp:13:
/home/parallels/ti/mmwave_sdk_01_02_00_05/packages/ti/drivers/soc/soc.h:346:61:error:‘SOC_ModuleId’has not been declared (OC_ModuleId’未声明)
extern Int32_t SOC_setPeripheralClock (SOC_Handle handle、SOC_ModuleId 模块、SOC_PeripheralClkSource clkSource、uint8_t clkDivisor、Int32_t* errCode);
^μ A
/home/parallels/ti/mmwave_sdk_01_02_00_05/packages/ti/drivers/soc/soc.h:347:57:‘S:尚未声明‘OC_ModuleId’
extern Int32_t SOC_initPeripheralRam (SOC_Handle handle、SOC_ModuleId 模块、Int32_t* errCode);
我的整个 driver.cpp 文件如下所示:
#include
#include
使用命名空间 std;
int main()
{
}
当我编译下面的代码时、这会导致上面的错误。 感谢您抽出时间为我提供帮助。
Davis