首页 > 解决方案 > 在 release/v4.2 SDK 中构建 aws_iot(事物影子)示例时出错

问题描述

大家好,在 release/v3.3 中有一个 aws_iot 示例,它在 esp-idf 的 release/v4.2 中不存在。因此,我复制了 aws_iot(事物影子)示例,并根据我的要求在 thing_shadow.c 文件和组件中的 aws_iot 文件夹中进行了所需的更改,从 v3.3 到 v4.2。但是在当前 SDK(v4.2) 中构建示例时,出现以下错误。

错误:

警告:缺少子模块组件/aws_iot/aws-iot-device-sdk-embedded-C... 在 esp-idf 中尝试“git submodule update --init components/aws_iot/aws-iot-device-sdk-embedded-C”根目录...错误:pathspec 'components/aws_iot/aws-iot-device-sdk-embedded-C' 与 git 已知的任何文件都不匹配。/home/harshitha/esp32/esp-idf/make/project.mk:672:目标配方'/home/harshitha/esp32/esp-idf/components/aws_iot/aws-iot-device-sdk-embedded-C/ .git' failed make: *** [/home/harshitha/esp32/esp-idf/components/aws_iot/aws-iot-device-sdk-embedded-C/.git] 错误1 我该如何解决这个问题? 有人可以建议在当前 SDK version4.2 中进行所需的更改以解决此问题。

标签: gitgithubsdkaws-iotesp-idf

解决方案


解决方案 1:在您的 SDK 中添加“esp-aws-iot”作为组件

  1. 转到安装 IDF SDK 的位置,例如C:\ESP-IDF\esp-idf\components
  2. 在该目录中打开命令提示符并使用此命令获取 idf 包 git clone --recursive https://github.com/espressif/esp-aws-iot

编辑:看起来你安装组件的路径从你的帖子中可能是错误的:“/home/harshitha/esp32/esp-idf/components/ aws_iot /aws-iot-device-sdk-embedded-C”应该是:“/home/harshitha/esp32/esp-idf/components/ esp-aws-iot /aws-iot-device-sdk-embedded-C”

参考:https ://github.com/espressif/esp-aws-iot


推荐阅读