Hi, my end goal is to have rf switches working in Home assistant.
I’ve flash a Sonoff rf bridge with Tasmota and configured it
Home assistant has the MQTT broker working and is running out MQTT devices fine.
In the MQTT broker it can see the RF Bridge
In the console of the RF Bridge if I press the button I get this returned
RF_Bridge/tele/RESULT = {“Time”:“2019-12-31T19:25:54”,“RfReceived”:{“Sync”:10700,“Low”:370,“High”:1070,“Data”:“203BA2”,“RfKey”:“None”}}
In the configuration.yaml I’ve entered just the basics at the moment to try to get a response
So took a break for a day and came back to this and found the solution and thought I would share.
I was following https://www.youtube.com/watch?v=OfSbIFIJPuc and my code in Home assistant was taken from his video and I didn’t check it hard enough, in short I was listening for state_topic of “tele/RF_Bridge/RESULT” when in fact it was firing off “RF_Bridge/tele/RESULT”
this is how I found this out.
Under the MQTT tab in the developers tools section of Home Assistant in the listen to a topic I entered in tele/RF_Bridge/RESULT and start listening, I noticed that when I pressed the button I wasn’t getting a result returning, this meant either HA wasn’t receiving them or I had the event incorrect. I logged back into the webpage of the Sonoff bridge and started the console and pressed the button again, the event fired as expected, I then copied the topic from the console and pasted into HA and noticed “tele/RF_Bridge” was transposed. Sure enough when I press the RF button it worked as expected.
Useful reading
Also if you are unsure of the topic you can enter # in the topic line to listen to all MQTT events coming into Home assisitant
thanks Francisp, I saw this in the morning and tried this as well, needless to say it didn’t work because of the topic, I suspect this is a change Tasmota as the configuration webpage makes sure it pushes out topic then prefix, tried changing this order but it keeps reverting back.