Using the directions here I installed the updated firmware on my sonoff device
In my configuration.yaml. I have
platform: mqtt
name: “2nd Floor Hall Sonoff”
state_topic: “home/sonoff/2ndhall/1/stat/POWER”
command_topic: “home/sonoff/2ndhall/cmnd/power”
qos: 1
payload_on: “ON”
payload_off: “OFF”
retain: true
home/sonoff/2ndhall/1 ON
tele/home/sonoff/2ndhall/1/LWT Online
cmnd/2ndhall/POWER ON
My in my HA screen i have a switch which stays in the off position. When I toggle it on, It switches for a second, then back to off. There is no change on the state of the physical device.
the mqtt log shows
home/sonoff/2ndhall/cmnd/power ON
home/sonoff/2ndhall/cmnd/power ON
I’m struggling to get the switches to connect to the embedded MQTT
Can someone please explain how the topic works? I’ve read numerous conflicting posts
I have numerous sonoff switches - so using sonoff as the topic for all of them would surely kick each other off it they ever connected? Unless i’m missing something?
Right now in my config.yaml:
mqtt:
then on the switch:
Host: [IP of MQTT broker / HASSIO]
Port: 1883
Client: DVES_A4B30E
user: homeassistant
pass: xxxxxxxxxxxx
Topic: Studio_Right_Front_Light
Full Topic: lab/%topic%
I can control the lights etc from the console via the switches IP, so all good there - just scratching my head now!