Hello,
I'm using nRF SDK v1.6.0 with nRF9160 development board. I did minimum changes to Asset_Tracker_v2 application (enable debug log, set up for my aws account and to use my shadow).
After that, immediately after connecting to the cloud and requesting shadow data, application disconnect from the cloud with error code -128.
Here is a debug log:
Here is my changes in prj.conf:
And changes in aws_iot_integration.c:
This problem is not related to the cloud settings as reducing shadow data size eliminate this issue. It's all about some buffer or another limit on application side.
So far I was able to trace the problem down to mqtt_client_tls_read function() from mqtt_transport_socket_tls.c file in which zsock_recv() call return 0, when shadow data was sent from AWS.
I've tried all different CONFIG_xxx_ LOG_LEVEL_DBG settings, but wasn't able to see any further information, why zsock_recv() may silently skip incoming data.