copercini / esp8266-aws_iot

Some examples using x.509 certificates and TLSv1.2 under Arduino IDE

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

AWS IoT shadow not working

martin-vl opened this issue · comments

I tested the mqtt_x509_DER example and works really nice. Only I am not receiving the shadow messages. Does someone knows what the reason could be?

Via the AWS IoT test console I send the following to the topic "$aws/things/iotTestDevice3/shadow/update":
{ "state" : { "desired" : { "light" : 1 } } }

In the AWS IoT console I see messages on .../shadow/update and .../shadow/update/delta. But when I subscribe with my ESP to "$aws/things/iotTestDevice3/shadow/update/delta" or "#" I don't receive any thing.

I also tested with the Python SDK and started the ThingShadowEcho.py and there it works fine, so the policy settings in AWS IoT are fine.

Is this a bug? Or I am doing something wrong?

I am seeing this behavior as well. Also, when I publish directly to
$aws/things/<thing-name>/shadow/update/delta through the AWS console, my device does receive the message.

But you are also not receiving a delta when you do an update?

The issue is solved by increasing the max package size.

Change line 26 in PubSubClient.h file to something like:
#define MQTT_MAX_PACKET_SIZE 1000

MQTT_MAX_PACKET_SIZE

Just update via setBufferSize