发帖
2 0 0

BW20 二次开发 MQTT示例 头文件问题

Curiosity
注册会员

2

主题

1

回帖

90

积分

注册会员

积分
90
BW系列 89 2 2026-5-28 16:31:11
直接把 mqtt sample 里的头文件 复制到个人工程,报错:23:10: fatal error: MQTTClient.h: No such file or directory
。强行包含进来,报错 /component/network/mqtt/MQTTClient/MQTTFreertos.h:23:10: fatal error: FreeRTOS.h: No such file or directory

有没有老哥了解原因,有哪地方要配置
──── 0人觉得很赞 ────

使用道具 举报

修改工程目录 src/CMakeList.txt内容,target_include_directories(${CURRENT_LIB_NAME} PRIVATE ${MODULE_IFLAGS}
    ../../../component/network/mqtt/MQTTClient
    ../../../component/os/freertos/freertos_v10.4.3/Source/include
    ../../../component/os/freertos/freertos_v10.4.3/Source/portable/GCC/AmebaDplus_KM4/non_secure
    ../../../component/os/freertos/freertos_v10.4.3/Source/portable/GCC/AmebaDplus_KM4/secure
)
您需要登录后才可以回帖 立即登录
高级模式
返回
统计信息
  • 会员数: 31051 个
  • 话题数: 44939 篇