buxtronix / am43

Control AM43 blinds with an ESP32
MIT License
76 stars 25 forks source link

MQTT connect failed, rc=-2 retrying in 5s. #17

Open awaismun opened 4 years ago

awaismun commented 4 years ago

Hi,

Thanks for this setup.

For some reason my MQTT connection is failing. This is what the serial monitor is returning: 'MQTT connect failed, rc=-2 retrying in 5s.'

These are my settings:

// MQTT server details.

define MQTT_ADDRESS "192.168.0.88"

define MQTT_USERNAME "username"

define MQTT_PASSWORD "password"

I am not sure if the MQTT_ADDRESS is right. I am using Zigbee2Mqtt and this is what I use for MQTT connection:

server: 'mqtt://homeassistant'

I have tried to use this but not working.

buxtronix commented 3 years ago

Perhaps using 'homeassistant.local' as the MQTT address will work. Else you may need to find out the actual IP address and specify that.