Why does switchtopic publish on CMND?

11 views
Skip to first unread message

Roger Kaplan

unread,
May 23, 2024, 9:01:53 AMMay 23
to TasmotaUsers
This is something that's been bothering me-
Setting switchtopic (or buttontopic I think) will force Tasmota to publish the switch state every time it changes on the topic given. 
so "switchtopic MYSWITCH" will publish on CMND/MYSWITCH
Why is that? I thought that CMND is for sending messages TO Tasmota, and STAT is for current status?

Philip Knowles

unread,
May 23, 2024, 10:49:14 AMMay 23
to Roger Kaplan, TasmotaUsers
Switchtopic is sending a command because the change of state is telling something else to do something as a result.  In normal operation the switch commands (internally) the output to change state.

From: sonof...@googlegroups.com <sonof...@googlegroups.com> on behalf of Roger Kaplan <kapla...@gmail.com>
Sent: 23 May 2024 14:01
To: TasmotaUsers <sonof...@googlegroups.com>
Subject: Why does switchtopic publish on CMND?
 
--
You received this message because you are subscribed to the Google Groups "TasmotaUsers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sonoffusers...@googlegroups.com.
To view this discussion on the web, visit https://groups.google.com/d/msgid/sonoffusers/6a4c61e4-649f-473d-a24c-02a3c642be96n%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages