Closed abhijitnathwani closed 4 years ago
The stacktrace seems to show libmosquitto in the callstack. Are you certain the crash is coming from the AWS IoT Device SDK? Why are you using two different MQTT clients (Mosquitto and the AWS IoT Device SDK) in the same application?
I'm not saying that the IoT SDK is bulletproof, just that the callstack looks like its coming during a Mosquitto callback.
Also, if you're not very far into your project, I would strongly recommend using the new V2 IoT SDK. The V2 SDK is a complete rework, built to improve reliability, performance, and security. This V1 SDK will no longer receive feature updates going forward.
Hi @graebm ,
the libmosquitto
is used to communicate with other processes running on the same device(kind of IPC).
I figured the application was failing as I didn't have return
in my wrapper publish function(strange though, it worked fine on Ubuntu without the return
keyword). The crash has been fixed for now.
For the new V2 IoT SDK I couldn't find proper documentation for the APIs used or the basic walkthrough of the sample codes as documented in the v1 SDK. Hence, it was difficult to follow. May be update some documentation so that others can follow better?
Documentation for the underlying MQTT classes can be found here Aws::Crt::Mqtt::MqttConnection. Unfortunately, we are still working on publishing documentation and for the Shadow and Jobs helper classes in the V2 IoT SDK.
The samples do have comments to help the reader see what's going on
We're working on it, thanks for the feedback.
Hi,
I have cross-compiled this SDK for
aarch64 linux
:I have written a cpp application that uses the SDK APIs to connect and publish data on AWS IoT. The application works fine on
Ubuntu 16.04
However, when I cross-compile and run the same application on
aarch64
, the connection is successfully established and when I try and publish the data, it crashes:On inspecting with
valgrind
:I see it is trying to
free
twice. However, I have not added anyalloc
ordealloc
. The allocations are happening from the SDK itself. what could be wrong here?Wrapper function to Publish the data: