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.

[参考译文] CC3220SF-LAUNCHXL:更改 IBM IOT 示例

Guru**** 2594620 points
Other Parts Discussed in Thread: CC3220SF

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

https://e2e.ti.com/support/wireless-connectivity/wi-fi-group/wifi/f/wi-fi-forum/778975/cc3220sf-launchxl-changing-ibm-iot-example

器件型号:CC3220SF-LAUNCHXL
主题中讨论的其他器件:CC3220SF

我正在从事一个学校项目、该项目在 CC1312R1 Launchpad 上无线接收传感器数据。 我获取此传感器数据并将其格式化为包含所有传感器数据的字符串(为简单起见)。 我想通过 I2C 接口将该字符串传输到 CC3220SF 、然后将该数据发布到 dev.ti.com/.../ 上 simplelink 示例中所布局的云接口上。

我很难确定需要更改此代码的哪些部分才能发布字符串、而不是按钮状态。 请提供任何帮助。

谢谢、

Andrew

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

    您需要编辑以下行: sprintf (publish_data、(const char *)"{\"d\":{\"button\":%d}"、buttonToggle);

    您将需要一个字符串、而不是按钮切换、对于%d、它将为%s

    BR、
    Vince