Thanks for your reply.
The poin is the APIs in the SDK differs from used in the awsFreertos.
For example:
aws_iot_mqtt_init is not found in amazonFreeRTOS.
As mentioned by Gordon, there are two versions AWS IoT Device SDK for C - Version 3 and Version 4.
The version of C-SDK libraries in Amazon FreeRTOS are same as version 4 and not version 3.
aws_iot_mqtt_init is an API which exists in version 3 of C-SDK and therefore is not expected to be in Amazon FreeRTOS. The corresponding API is IotMqtt_Init which exists both in Amazon FreeRTOS and version 4 of C-SDK. Note that there are still some minor differences between the libraries in Amazon FreeRTOS and C-SDK version 4 and we are working on making them same.
I have a couple of questions:
1- Is iot_mqtt_agent.c a part of the library or just a wrapper to handle MQTTv1/v2?
2- I’m trying to merge the greengrass demo with the OTA demo but the issue that the greengrass uses the mqtt agent APIs and the OTA uses the mqtt v2 APIs directly, so is it better to use the agent APIs or the MQTTv2 directly in both demos?
3- Can I create multiple MQTT clients?
4- If I have Single/Multiple MQTT clients, are the mqtt APIs thread save or should I use synchronization between tasks?
Excuse me, i bring up the topic here, i get the message that the API beween with AFR(Amazon FreeRTOS) and C-SDK will keep same finally in version 4. i checked the page - GitHub - aws/aws-iot-device-sdk-embedded-C at v3.1.2, now the API is not same with AFR(Amazon FreeRTOS), for example, C-SDK use aws_iot_mqtt_init, while AFR use MQTT_Init(in core_mqtt.c). So in the version 4, C-SDK will use the API in core_mqtt.c,same with AFR, right ?
BTW, what’s the plan for version 4?
Some things have changed since then. Our libraries are standalone consumable now and live in their own repositories. We also provide long term support (LTS) for our libraries - https://www.freertos.org/lts-libraries.html