Tasmota power plug MQTT connecting problem

I am trying to connect a TASMOTA (not SONOFF) power plug with mqtt.
I use node-red-contrib-tasmota. I use the sensor node to communicate.
afbeelding

I have configured the broker node,

But the power plug as well as node-red don't seem to be able to find each other.

Node -red is running on 192.168.0.21, it reports,

I saw a topic on this before, and there the problem was another old not used broker that was in the way, but in my case there is no other broker config node, that I am aware of.

Any suggestions?

You need to set the ip of the mqtt brokker in the tasmota device, at the moment it looks like you set it to 127.0.0.1, which is local host. So Tasmota device is trying to connect to itself.

Fix the ip of the mqtt server and then add that ip to the tasmota device.

I don't think that's correct, the Tasmota console says it is trying to connect to a broker at 192.168.0.21.

Is your MQTT broker provided by node-red-contrib-tasmota?
What operating system does Node-red (and mqtt broker) run on?
How do you know the broker is running?
Is it set to accept network connections beyond localhost?
Edit - another question:
Does the broker require a username/password? To set up the password in Tasmota you have to tick the password box then enter the password and click Save.

There are various tools you can use to test your MQTT setup. See the useful articles at http://www.steves-internet-guide.com/

I have smart sockets flashed with Tasmota and my MQTT broker is Mosquitto (on Linux). It does need configuring to accept connections over the network.
I don't know about the Tasmota nodes though, I don't use those.
The sockets connect to Mosquiito and I just use the standard mqtt-in and mqtt-out nodes to communicate

@E1cid , I think I did it right, this is the config. of the Tasmota device,



So the Tasmota device is trying to connect to 192.168.0.21, as you can see in the Tasmota log, which is the ip of the RPI, where Node-red is installed and where the MQTT node is configured. Changing the localhost to IP 192.168.0.21 on the broker in Node-red doesn't solve the problem.

@jbudd and @E1cid, I ditched the Tasmota librairy and installed AEDES broker, now it is working.

Aedes is simple to install since it's within Node-red, and it works but it's better to use Mosquitto. For example Mosquitto supports quality of service.

1 Like

@jbudd
Aedes is simple to install since it's within Node-red, and it works but it's better to use Mosquitto. For example Mosquitto supports quality of service.

Ok, that sounds good. I will try, Thanks.

@jbudd , I cannot find Mosquitto in the librairy. How do I install?

@jbudd , ok I found one here,

@jbudd , Ok, that seems to be working correctly.

Thanks for the help. :grinning:

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.