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.

[参考译文] CC1354P10:构建 SimpleLink 示例时未启用扩展警告

Guru**** 2348500 points
请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

https://e2e.ti.com/support/wireless-connectivity/sub-1-ghz-group/sub-1-ghz/f/sub-1-ghz-forum/1479866/cc1354p10-simplelink-examples-are-built-without-extended-warnings-enabled

器件型号:CC1354P10

工具与软件:

构建(至少) WiSUN 示例时、`-Wall`、`-WExtra`和`-Werror`之类的警告似乎未启用。 这会导致警告被忽略、因此当您在将警告视为错误的项目中使用源代码时、编译会失败:

cc13xx_cc26xx/source/ti/devices/cc13x4_cc26x4/driverlib/cpu.h:355:24: warning: unused parameter 'ui32NewBasepri' [-Wunused-parameter]
355 | CPUbasepriSet(uint32_t ui32NewBasepri)

cc13xx_cc26xx/kernel/freertos/startup/startup_cc13x4_cc26x4_gcc_ns.c:170:15: warning: incompatible pointer types initializing 'uint32_t *' (aka 'unsigned int *') with an expression of type 'unsigned long *' [-Wincompatible-pointer-types]
170 | uint32_t *vtor = (unsigned long *)0xE000ED08;
| ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~

您构建时是否内部启用了警告?  

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    尊敬的 Marco:

    我不确定您所说的"内部启用"是什么意思。 我们通常不启用这些警告。

    谢谢、

    Marie H.

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    你(们)好

    哎呀 我建议您这样做、因为您的客户会这样做、而且当 SDK 标头发出警告时、他们在使用 SDK 时会遇到困难。

    谢谢! /Marco