pycom / pycom-libraries

MicroPython libraries and examples that work out of the box on Pycom's IoT modules
333 stars 375 forks source link

MQTT Example does not Work -- MQTT library returns OSError: [Errno 104] ECONNRESET #160

Closed ioankatsi closed 2 years ago

ioankatsi commented 2 years ago

The issue is the mqtt library seems to have connection handling isssues. While trying to connect to MQTT I get ECONNRESET.

What are the steps to reproduce this issue?

  1. Placing this file under /lib
  2. Use Lopy4
  3. Try to publish a message to an MQTT broker based on this tutorial

What happens?

You will receive this error:

Traceback (most recent call last): File "", line 26, in File "/flash/lib/mqtt.py", line 223, in connect OSError: [Errno 104] ECONNRESET

What it was expecting to happen?

Connect and publish message to MQTT

What versions of software are you using?