First time im trying out MQTT. I have made myself a small project with an RFID chip and things are working good. But i struggle to use it to trigger an automation. My plan is to use the RFID to start and stop my alarm. But first i need to get the automation to trigger when i scan the chip.
I have set all the configurations and i do get a respons in Node-red debug when i scan my RFID chip.
Im not gonna use Node-red, i just used the debug function to see if it actually worked.
This is from debug. I did set my topic as “esprfid” in the software.
I went to configuration -> integration and added MQTT and set autodiscovery.
Nothing shows up here but i assume my device doesnt apply for autodiscovery.
I setup my esprfid (192.168.156.147) with the MQTT information.
And it does connect to my broker.
1584623808: New connection from 192.168.156.147 on port 1883.
1584623808: New client connected from 192.168.156.147 as esp826604cdde (p2, c1, k15, u'mqtt').
To test if my esorfid sends info too the broker i testet Node-red with a debug and also MQTT Explorer and get this info:
So the broker gets the info, but looks like home assistant cant pick it up from the broker?
Since listening to “#” at the developers tool doesnt give anything, nor does “esprfid”
No it didnt work. But i found out something and maybe someone know why.
I realised it was home assistant that couldnt read the data sent to the Mosquitto broker.
So i removed MQTT from the “integration” section and added this manually to the config file:
I can say almost the opposite - I kind of remember when mqtt config was in configuration.yaml but I followed the docs and switched to the integration config.
No issues either way.