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.

小白求问,在SDK的程序加上了一个一模一样的语句,只是把LED_0改成了LED_1就报错了。

Other Parts Discussed in Thread: SYSCONFIG

请问出现这种问题的原因是什么?该怎么解决呢

  • CONFIG_GPIO_LED_0是自己定义的,应该在板级支持库中定义的,你的CONFIG_GPIO_LED_1应该是没有定义,所以报错。找到CONFIG_GPIO_LED_0定义的地方,看看还定义什么了,没有定义的话,自己按照硬件定义一个就好了。
  • 请问您知道CC1312的关于定义CONFIG_GPIO_LED_1的库在什么地方吗?第一次用这个产品,不太熟悉
  • 可以用sysconfig去定义引脚:

    SysConfig generates the driver configurations into the ti_drivers_config.c and ti_drivers_config.h files. Information on pins and resources used is present in both generated files. The SysConfig user interface can also be utilized to determine pins and resources used.
    •CONFIG_GPIO_LED_0 - Indicates that the board was initialized within mainThread() also toggled by CONFIG_GPIO_BUTTON_0
    •CONFIG_GPIO_LED_1 - Toggled by CONFIG_GPIO_BUTTON_1
    •CONFIG_GPIO_BUTTON_0 - Toggles CONFIG_GPIO_LED_0
    •CONFIG_GPIO_BUTTON_1 - Toggles CONFIG_GPIO_LED_1