tasmota and light on off

142 views
Skip to first unread message

devilx

unread,
Jun 5, 2024, 2:05:54 PMJun 5
to TasmotaUsers
he will save everyone I flashed an esp8266 with tasmota, connected to the relays and configured with Alexa. in tasmota I configured the relays as rele_i, I turn the light on and off with a press. In Alexa to turn on and off I have to press the button twice. basically if I tell Alexa turn on the light it sends the on command and immediately an off but the light stays on if I say turn off the light it doesn't work
example da console
19:05:13.991 RSL: RESULT = {"POWER2":"ON"}
19:05:13.994 RSL: POWER2 = ON
19:05:14.207 RSL: RESULT = {"POWER2":"OFF"}
19:05:14.209 RSL: POWER2 = OFF
but i send 1 comand on no two comand

Justin Adie

unread,
Jun 5, 2024, 4:11:48 PMJun 5
to devilx, SonoffUsers
1. Tell us more about the relay you are using. 
2. why do you configure the relay as inverted?  
3. when you say “turn the light on and off with a press”, explain what type of button you are pressing and how it is connected to the device.  
4. share the output of the console command : status 0 
5. Alexa is a voice interface.  Explain what you mean by “press the button twice”.  What button?  
6. explain what emulation you are using to link the tasmotised device with Alexa
7. make sure that the web logs are more verbose when you are trying to debug.  Issue via the console: weblog 4



--
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/6874e1e7-0175-4ba8-9a02-c7611a941d97n%40googlegroups.com.

devilx

unread,
Jun 5, 2024, 4:48:45 PMJun 5
to TasmotaUsers
I have a wemos d1 mini connected to a 16 relay board, which in turn controls 220v relays, to turn on the lights. I made Alexa recognize Tasmota as a device and it found all my lights. The control panel of the tasmota everything works perfectly. from alexa if iodine alexa turn on the kitchen light, it turns on. If I say Alexa turn off the kitchen lights it doesn't do anything. If I say Alexa again, turn on the kitchen lights, it turns them off
Alexa doesn't recognize the turn off lights command.

devilx

unread,
Jun 5, 2024, 4:50:14 PMJun 5
to TasmotaUsers
STATUS 0

21:49:33.816 RSL: STATUS = {"Status":{"Module":18,"DeviceName":"Wemos2","FriendlyName":["Filodiffusione","Faretti Letto","Led letto","Stanza Giochi","","Camino","Fari Soggiorno",""],"Topic":"tasmota_0FE688","ButtonTopic":"0","Power":"00000000","PowerLock":"00000000","PowerOnState":3,"LedState":1,"LedMask":"FFFF","SaveData":1,"SaveState":1,"SwitchTopic":"0","SwitchMode":[6,3,0,0,0,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"ButtonRetain":0,"SwitchRetain":0,"SensorRetain":0,"PowerRetain":0,"InfoRetain":0,"StateRetain":0,"StatusRetain":0}}
21:49:33.821 RSL: STATUS1 = {"StatusPRM":{"Baudrate":115200,"SerialConfig":"8N1","GroupTopic":"tasmotas","OtaUrl":"http://ota.tasmota.com/tasmota/release/tasmota-IT.bin.gz","RestartReason":"Software/System restart","Uptime":"0T03:03:44","StartupUTC":"2024-06-05T17:45:49","Sleep":50,"CfgHolder":4617,"BootCount":21,"BCResetTime":"2024-06-01T21:59:40","SaveCount":108,"SaveAddress":"F8000"}}
21:49:33.825 RSL: STATUS2 = {"StatusFWR":{"Version":"14.0.0(release-tasmota)","BuildDateTime":"2024-05-14T13:56:02","Boot":31,"Core":"2_7_6","SDK":"2.2.2-dev(38a443e)","CpuFrequency":80,"Hardware":"ESP8266EX","CR":"419/699"}}
21:49:33.829 RSL: STATUS3 = {"StatusLOG":{"SerialLog":2,"WebLog":2,"MqttLog":0,"SysLog":0,"LogHost":"","LogPort":514,"SSId":["Libertino-WIFI",""],"TelePeriod":300,"Resolution":"55C180C0","SetOption":["00008009","2805C80001000600003C5A0A192800000000","00000080","00006000","00004000","00000000"]}}
21:49:33.840 RSL: STATUS4 = {"StatusMEM":{"ProgramSize":648,"Free":352,"Heap":24,"ProgramFlashSize":4096,"FlashSize":4096,"FlashChipId":"16405E","FlashFrequency":40,"FlashMode":"DOUT","Features":["0410","8F9AC787","04368001","000000CF","010013C0","C000F981","00004004","00001000","54000020","00000080","00000000"],"Drivers":"1,2,!3,!4,!5,!6,7,!8,9,10,12,!16,!18,!19,20,!21,!22,!24,26,!27,29,!30,!35,!37,!45,62,!68","Sensors":"1,2,3,4,5,6","I2CDriver":"7"}}
21:49:33.846 RSL: STATUS5 = {"StatusNET":{"Hostname":"tasmota-0FE688-1672","IPAddress":"192.168.1.65","Gateway":"192.168.1.254","Subnetmask":"255.255.255.0","DNSServer1":"192.168.1.254","DNSServer2":"0.0.0.0","Mac":"D8:BF:C0:0F:E6:88","Webserver":2,"HTTP_API":1,"WifiConfig":4,"WifiPower":17.0}}
21:49:33.850 RSL: STATUS6 = {"StatusMQT":{"MqttHost":"","MqttPort":1883,"MqttClientMask":"DVES_%06X","MqttClient":"DVES_0FE688","MqttUser":"DVES_USER","MqttCount":0,"MAX_PACKET_SIZE":1200,"KEEPALIVE":30,"SOCKET_TIMEOUT":4}}
21:49:33.856 RSL: STATUS7 = {"StatusTIM":{"UTC":"2024-06-05T20:49:33Z","Local":"2024-06-05T21:49:33","StartDST":"2024-03-31T02:00:00","EndDST":"2024-10-27T03:00:00","Timezone":"+01:00","Sunrise":"04:48","Sunset":"20:48"}}
21:49:33.860 RSL: STATUS10 = {"StatusSNS":{"Time":"2024-06-05T21:49:33"}}
21:49:33.867 RSL: STATUS11 = {"StatusSTS":{"Time":"2024-06-05T21:49:33","Uptime":"0T03:03:44","UptimeSec":11024,"Heap":24,"SleepMode":"Dynamic","Sleep":50,"LoadAvg":19,"MqttCount":0,"POWER1":"OFF","POWER2":"OFF","POWER3":"OFF","POWER4":"OFF","POWER5":"OFF","POWER6":"OFF","POWER7":"OFF","POWER8":"OFF","Wifi":{"AP":1,"SSId":"Libertino-WIFI","BSSId":"98:9B:CB:97:99:1F","Channel":6,"Mode":"11n","RSSI":54,"Signal":-73,"LinkCount":1,"Downtime":"0T00:00:06"}}}

Justin Adie

unread,
Jun 5, 2024, 5:43:14 PMJun 5
to devilx, TasmotaUsers
You haven't answered all the questions.  In particular how did you establish the link with Alexa.  What emulation mode did you use?  What language are your echo devices set to use?  

You also have not shared logs (with weblog turned to 4) of what happens when you instruct Alexa to turn on and turn off the lights.  


Philip Knowles

unread,
Jun 6, 2024, 1:29:52 AMJun 6
to Justin Adie, devilx, TasmotaUsers
It sounds like Alexa is sending a 'toggle' command (which will appear in the Console as powerx 2). If that's what happening then the issue is in the Alexa Skill not Tasmota.


From: 'Justin Adie' via TasmotaUsers <sonof...@googlegroups.com>
Sent: Wednesday, June 5, 2024 10:42:55 PM
To: devilx <liber...@gmail.com>
Cc: TasmotaUsers <sonof...@googlegroups.com>
Subject: Re: tasmota and light on off
 

devilx

unread,
Jun 6, 2024, 1:39:53 AMJun 6
to TasmotaUsers
the wemos is set as generic18 and hue bridge emulation. here's weblo4

when on light
06:35:14.545 HTP: API Hue (/fe688/lights/16672899/state) from 192.168.1.73
06:35:14.548 HTP: POST argomenti Hue ({"on":true})
06:35:14.555 SRC: Hue
06:35:14.559 RSL: RESULT = {"POWER3":"ON"}
06:35:14.561 RSL: POWER3 = ON
06:35:14.564 HTP: Hue Result ([{"success":{"/lights/16672899/state/on":true}}])
06:35:14.644 HTP: API Hue (/fe688/lights/16672899) from 192.168.1.73
06:35:14.648 /lights path=/lights/16672899
06:35:14.657 HTP: Hue Result ({"state":{"on":true,"alert":"none","effect":"none","reachable":true},"type":"Extended color light","name":"Led letto","modelid":"Generic","manufacturername":"Tasmota","uniqueid":"d8:bf:c0:0f:e6:88:00:11-03"})
06:35:14.893 SRC: PulseTimer
06:35:14.897 RSL: RESULT = {"POWER3":"OFF"}
06:35:14.900 RSL: POWER3 = OFF
06:35:15.826 WIF: Controllo connessione...

when off light
6:35:15.826 WIF: Controllo connessione...
06:35:35.768 WIF: Controllo connessione...
06:35:51.222 WIF: Sending Gratuitous ARP
06:35:55.804 WIF: Controllo connessione...
06:35:56.304 UDP: Packet (119)
06:35:56.306 UDP: HUE
06:36:01.250 RSL: STATE = {"Time":"2024-06-06T06:36:01","Uptime":"0T11:50:12","UptimeSec":42612,"Heap":25,"SleepMode":"Dynamic","Sleep":50,"LoadAvg":19,"MqttCount":0,"POWER1":"OFF","POWER2":"OFF","POWER3":"OFF","POWER4":"OFF","POWER5":"OFF","POWER6":"OFF","POWER7":"OFF","POWER8":"OFF","Wifi":{"AP":1,"SSId":"Libertino-WIFI","BSSId":"98:9B:CB:97:99:1F","Channel":1,"Mode":"11n","RSSI":44,"Signal":-78,"LinkCount":3,"Downtime":"0T00:00:15"}}
06:36:01.294 UDP: Packet (119)
06:36:01.296 UDP: HUE
06:36:06.346 UDP: Packet (119)
06:36:06.348 UDP: HUE
06:36:11.227 UDP: Packet (119)
06:36:11.229 UDP: HUE
06:36:14.104 UDP: Packet (119)
06:36:14.106 UDP: Packet (119)
06:36:14.107 UDP: Packet (119)
06:36:14.153 UDP: Packet (119)
06:36:15.778 WIF: Controllo connessione...
06:36:16.278 UDP: Packet (119)
06:36:16.280 UDP: HUE
06:36:33.753 HTP: API Hue (/fe688/lights/16672904) from 192.168.1.73
06:36:33.756 /lights path=/lights/16672904
06:36:33.765 HTP: Hue Result ({"state":{"on":false,"alert":"none","effect":"none","reachable":true},"type":"Extended color light","name":"","modelid":"Generic","manufacturername":"Tasmota","uniqueid":"d8:bf:c0:0f:e6:88:00:11-08"})
06:36:35.804 WIF: Controllo connessione...
06:36:44.703 HTP: API Hue (/fe688/lights/16672899) from 192.168.1.73
06:36:44.707 /lights path=/lights/16672899
06:36:44.716 HTP: Hue Result ({"state":{"on":false,"alert":"none","effect":"none","reachable":true},"type":"Extended color light","name":"Led letto","modelid":"Generic","manufacturername":"Tasmota","uniqueid":"d8:bf:c0:0f:e6:88:00:11-03"})
06:36:51.215 WIF: Sending Gratuitous ARP
06:36:55.789 WIF: Controllo connessione...
06:36:57.567 HTP: API Hue (/fe688/lights/16672900) from 192.168.1.73
06:36:57.570 /lights path=/lights/16672900
06:36:57.579 HTP: Hue Result ({"state":{"on":false,"alert":"none","effect":"none","reachable":true},"type":"Extended color light","name":"Stanza Giochi","modelid":"Generic","manufacturername":"Tasmota","uniqueid":"d8:bf:c0:0f:e6:88:00:11-04"})
06:37:02.521 HTP: API Hue (/fe688/lights/16672899/state) from 192.168.1.73
06:37:02.524 HTP: POST argomenti Hue ({"on":false})
06:37:02.530 SRC: Hue
06:37:02.535 RSL: RESULT = {"POWER3":"OFF"}
06:37:02.537 RSL: POWER3 = OFF
06:37:02.539 HTP: Hue Result ([{"success":{"/lights/16672899/state/on":false}}])
06:37:02.620 HTP: API Hue (/fe688/lights/16672899) from 192.168.1.73
06:37:02.624 /lights path=/lights/16672899
06:37:02.633 HTP: Hue Result ({"state":{"on":false,"alert":"none","effect":"none","reachable":true},"type":"Extended color light","name":"Led letto","modelid":"Generic","manufacturername":"Tasmota","uniqueid":"d8:bf:c0:0f:e6:88:00:11-03"})
06:37:07.371 UDP: Packet (119)
06:37:07.372 UDP: HUE
06:37:07.374 UDP: Packet (119)
06:37:08.371 UDP: Packet (119)
06:37:08.373 UDP: HUE
06:37:08.375 UDP: Packet (119)
06:37:09.296 UDP: Packet (119)
06:37:09.298 UDP: HUE
06:37:09.396 UDP: Packet (119)
06:37:10.349 UDP: Packet (119)
06:37:10.351 UDP: HUE
06:37:10.449 UDP: Packet (119)
06:37:15.789 WIF: Controllo connessione...
06:37:20.578 HTP: API Hue (/fe688/lights/16672901) from 192.168.1.73
06:37:20.582 /lights path=/lights/16672901
06:37:20.591 HTP: Hue Result ({"state":{"on":false,"alert":"none","effect":"none","reachable":true},"type":"Extended color light","name":"","modelid":"Generic","manufacturername":"Tasmota","uniqueid":"d8:bf:c0:0f:e6:88:00:11-05"})
06:37:35.790 WIF: Controllo connessione...
06:37:51.223 WIF: Sending Gratuitous ARP
06:37:52.953 HTP: API Hue (/fe688/lights/16672897) from 192.168.1.73
06:37:52.956 /lights path=/lights/16672897
06:37:52.964 HTP: Hue Result ({"state":{"on":false,"alert":"none","effect":"none","reachable":true},"type":"Extended color light","name":"Filodiffusione","modelid":"Generic","manufacturername":"Tasmota","uniqueid":"d8:bf:c0:0f:e6:88:00:11-01"})
06:37:55.804 WIF: Controllo connessione...
06:38:01.319 UDP: Packet (119)
06:38:01.321 UDP: HUE
06:38:06.238 UDP: Packet (119)
06:38:06.240 UDP: HUE
06:38:08.643 HTP: API Hue (/fe688/lights/16672899) from 192.168.1.73
06:38:08.647 /lights path=/lights/16672899
06:38:08.655 HTP: Hue Result ({"state":{"on":false,"alert":"none","effect":"none","reachable":true},"type":"Extended color light","name":"Led letto","modelid":"Generic","manufacturername":"Tasmota","uniqueid":"d8:bf:c0:0f:e6:88:00:11-03"})
06:38:11.241 UDP: Packet (119)
06:38:11.243 UDP: HUE
06:38:15.803 WIF: Controllo connessione...
06:38:16.271 UDP: Packet (119)
06:38:16.273 UDP: HUE
06:38:21.278 UDP: Packet (119)
06:38:21.280 UDP: HUE
06:38:35.769 WIF: Controllo connessione...
06:38:54.590 HTP: Hue Result ({"state":{"on":false,"alert":"none","effect":"none","reachable":true},"type":"Extended color light","name":"Led letto","modelid":"Generic","manufacturername":"Tasmota","uniqueid":"d8:bf:c0:0f:e6:88:00:11-03"})
06:38:54.679 HTP: API Hue (/fe688/lights/16672900) from 192.168.1.73
06:38:54.682 /lights path=/lights/16672900
06:38:54.691 HTP: Hue Result ({"state":{"on":false,"alert":"none","effect":"none","reachable":true},"type":"Extended color light","name":"Stanza Giochi","modelid":"Generic","manufacturername":"Tasmota","uniqueid":"d8:bf:c0:0f:e6:88:00:11-04"})
06:38:54.779 HTP: API Hue (/fe688/lights/16672901) from 192.168.1.73
06:38:54.782 /lights path=/lights/16672901
06:38:54.791 HTP: Hue Result ({"state":{"on":false,"alert":"none","effect":"none","reachable":true},"type":"Extended color light","name":"","modelid":"Generic","manufacturername":"Tasmota","uniqueid":"d8:bf:c0:0f:e6:88:00:11-05"})
06:38:54.879 HTP: API Hue (/fe688/lights/16672902) from 192.168.1.73
06:38:54.883 /lights path=/lights/16672902
06:38:54.892 HTP: Hue Result ({"state":{"on":false,"alert":"none","effect":"none","reachable":true},"type":"Extended color light","name":"Camino","modelid":"Generic","manufacturername":"Tasmota","uniqueid":"d8:bf:c0:0f:e6:88:00:11-06"})
06:38:54.980 HTP: API Hue (/fe688/lights/16672903) from 192.168.1.73
06:38:54.983 /lights path=/lights/16672903
06:38:54.993 HTP: Hue Result ({"state":{"on":false,"alert":"none","effect":"none","reachable":true},"type":"Extended color light","name":"Fari Soggiorno","modelid":"Generic","manufacturername":"Tasmota","uniqueid":"d8:bf:c0:0f:e6:88:00:11-07"})
06:38:55.079 HTP: API Hue (/fe688/lights/16672904) from 192.168.1.73
06:38:55.082 /lights path=/lights/16672904
06:38:55.090 HTP: Hue Result ({"state":{"on":false,"alert":"none","effect":"none","reachable":true},"type":"Extended color light","name":"","modelid":"Generic","manufacturername":"Tasmota","uniqueid":"d8:bf:c0:0f:e6:88:00:11-08"})
06:38:55.179 HTP: API Hue (/fe688/lights) from 192.168.1.73
06:38:55.237 HTP: Hue Result ({"16672897":{"state":{"on":false,"alert":"none","effect":"none","reachable":true},"type":"Extended color light","name":"Filodiffusione","modelid":"Generic","manufacturername":"Tasmota","uniqueid":"d8:bf:c0:0f:e6:88:00:11-01"},"16672898":{"state":{"on":false,"alert":"none","effect":"none","reachable":true},"type":"Extended color light","name":"Faretti Letto","modelid":"Generic","manufacturername":"Tasmota","uniqueid":"d8:bf:c0:0f:e6:88:00:11-02"},"16672899":{"state":{"on":false,"alert":"none","effect":"none","reachable":true},"type":"Extended color light","name":"Led letto","modelid":"Generic","manufacturername":"Tasmota","uniqueid":"d8:bf:c0:0f:e6:88:00:11-03"},"16672900":{"state":{"on":false,"alert":"none","effect":"none","reachable":true},"type":"Extended color light","name":"Stanza Giochi","modelid":"Generic","manufacturername":"Tasmota","uniqueid":"d8:bf:c0:0f:e6:88:00:11-04"},"16672901":{"state":{"on":false,"alert":"none","effect":"none","reachable":true},"type":"Extended color light","name":"","modelid":"Generic","manufacturername":"Tasmota","uniqueid":"d8:bf:c0:0f:e6:88:00:11-05"},"16672902":{"state":{"on":false,"alert":"none","effect":"none","reachable":true},"type":"Extended color light","name":"Camino","modelid":"Generic","manufacturername":"Tasmota","uniqueid":"d8:bf:c0:0f:e6:88:00:11-06"},"16672903":{"state":{"on":false,"alert":"none","effect":"none","reachable":true},"type":"Extended color light","name":"Fari Soggiorno","modelid":"Generic","manufacturername":"Tasmota","uniqueid":"d8:bf:c0:0f:e6:88:00:11-07"},"16672904":{"state":{"on":false,"alert":"none","effect":"none","reachable":true},"type":"Extended color light","name":"","modelid":"Generic","manufacturername":"Tasmota","uniqueid":"d8:bf:c0:0f:e6:88:00:11-08"}})
06:38:55.244 UDP: Packet (94)
06:38:55.245 UDP: HUE
06:38:55.253 UPP: Hue 3 pacchetti di risposta inviati a 192.168.1.73:50000
06:38:55.254 UDP: Packet (101)
06:38:55.761 WIF: Controllo connessione...
06:38:58.162 UDP: Packet (94)
06:38:58.164 UDP: HUE
06:38:58.171 UPP: Hue 3 pacchetti di risposta inviati a 192.168.1.73:50000
06:38:58.173 UDP: Packet (101)

not turn off, but i send comand alexa turn on light alexa turn off light



Justin Adie

unread,
Jun 6, 2024, 1:50:26 AMJun 6
to devilx, TasmotaUsers
You have a pulsetimer set on the tasmota device.  

Turn if off and see whether that fixes the problem.


Philip Knowles

unread,
Jun 6, 2024, 1:50:28 AMJun 6
to devilx, TasmotaUsers
Is it Hue Bridge Emulation V1 ?
From: sonof...@googlegroups.com <sonof...@googlegroups.com> on behalf of devilx <liber...@gmail.com>
Sent: Thursday, June 6, 2024 6:39:52 AM
To: TasmotaUsers <sonof...@googlegroups.com>

Subject: Re: tasmota and light on off

devilx

unread,
Jun 6, 2024, 2:31:52 PMJun 6
to TasmotaUsers
I tried disabling PulseTime, but still the same problem

Justin Adie

unread,
Jun 6, 2024, 3:17:26 PMJun 6
to devilx, TasmotaUsers
Please make sure you post the full logs each time you come back having tried something.

Last set of logs you provided clearly showed that the lights were being turned off by pulsetime and not by hue or Alexa or anything else.

Please also let us know what language you use for your echo devices.   Not all languages are supported equally. 



Philip Knowles

unread,
Jun 6, 2024, 11:10:43 PMJun 6
to Justin Adie, devilx, TasmotaUsers
There was no reply to is it Hue Bridge V1 in Alexa?
From: 'Justin Adie' via TasmotaUsers <sonof...@googlegroups.com>
Sent: Thursday, June 6, 2024 8:17:07 PM
To: devilx <liber...@gmail.com>
Cc: TasmotaUsers <sonof...@googlegroups.com>

devilx

unread,
Jun 7, 2024, 12:38:15 AMJun 7
to TasmotaUsers
yes as emulation in tasmota I chose bridge hue, but I don't know which version, how do I check?

Philip Knowles

unread,
Jun 7, 2024, 1:45:29 AMJun 7
to devilx, TasmotaUsers
In Alexa app it gives a choice between V1 and V2 when you  discover the device
Sent: Friday, June 7, 2024 5:38:15 AM

Justin Adie

unread,
Jun 7, 2024, 3:00:54 AMJun 7
to Philip Knowles, devilx, TasmotaUsers
By the by I don't get that choice using British English or French as the echo language whilst recognising tasmota hue emulated devices.  

Seeing the tasmota debug logs of what happens with each Alexa command will be instructive.




Philip Knowles

unread,
Jun 7, 2024, 10:59:58 AMJun 7
to Justin Adie, devilx, TasmotaUsers
Well I live in England and I see this in the Alexa app
From: Justin Adie <justi...@adieandco.com>
Sent: Friday, June 7, 2024 8:00:34 AM
To: Philip Knowles <knowles...@gmail.com>
Cc: devilx <liber...@gmail.com>; TasmotaUsers <sonof...@googlegroups.com>
1000001242.png

Justin Adie

unread,
Jun 7, 2024, 11:50:01 AMJun 7
to Philip Knowles, devilx, SonoffUsers
Weird!  For me I just tell the echo to find a new device and that’s it.  And when I join devices via the app I always just go to other and then click wifi/zigbee/matter and let everything pair without more intervention.  I guess there are multiple discovery journeys that Alexa supports - but I’d not come across that one.  Maybe it solves the OP’s issue - it would be poor design by Hue if they changed the implementation of on/off functionality between versions though! 





<1000001242.png>

devilx

unread,
Jun 7, 2024, 5:29:16 PMJun 7
to TasmotaUsers
I can't see which version v1 or v2 or . come, shall we do it?

Philip Knowles

unread,
Jun 8, 2024, 2:02:25 AMJun 8
to devilx, TasmotaUsers
On the Tasmota Hue page it specifically says to choose V1. It may be that Tasmota behaves as a V1 hub bridge. 
Sent: Friday, June 7, 2024 10:29:16 PM

devilx

unread,
Jun 8, 2024, 6:11:21 AMJun 8
to TasmotaUsers
on the page where you can choose the type of emulation the version is not ticked but only the key and tone

Justin Adie

unread,
Jun 8, 2024, 7:11:40 AMJun 8
to devilx, TasmotaUsers

devilx

unread,
Jun 9, 2024, 12:27:24 AMJun 9
to TasmotaUsers
this is my screen 
Immagine.jpg

Philip Knowles

unread,
Jun 9, 2024, 2:45:17 AMJun 9
to devilx, TasmotaUsers
No the Tasmota documents page says to use Hue Bridge V1. It's in the Alexa setup not Tasmota.

Sent: 09 June 2024 05:27

Justin Adie

unread,
Jun 9, 2024, 4:34:20 AMJun 9
to devilx, TasmotaUsers, Philip Knowles
@OP

To test Philip's suggestion

1. Delete all these devices (Camino, Faro Soggiorno etc) from Alexa.
2. Reboot the tasmota device
3. Run this command in console

Backlog0 weblog 4;pulsetime1 0; pulsetime2 0; pulsetime3 0; pulsetime4 0; pulsetime5 0; pulsetime6 0; pulsetime7 0; pulsetime8 0


4. Use voice commands to Alexa "Alexa find new devices". Or the equivalent discovery command in Italian.
5.  Once the devices have been found by Alexa go to the console and capture all the logs for the command "Alexa turn on Camino". Probably "Alexa accendi Camino" in italian
6. Paste the log into this email chain
7.  Go back to the console and capture all the logs from the command "Alexa turn off Camino" ("Alexa spegni Camino")
8.  Paste the logs into this email chain
9.  Send the logs to this group.

devilx

unread,
Jun 9, 2024, 1:49:06 PMJun 9
to TasmotaUsers
ok this log two light , problem the relay 220v  It always stays energized and acts like a switch, not a button
18:44:30.811 HTP: Menu principale
18:44:32.679 SRC: WebGui from 192.168.1.55
18:44:32.683 RSL: RESULT = {"POWER1":"OFF"}
18:44:32.686 RSL: POWER1 = OFF
18:44:33.306 SRC: WebGui from 192.168.1.55
18:44:33.311 RSL: RESULT = {"POWER1":"ON"}
18:44:33.314 RSL: POWER1 = ON
18:44:33.940 SRC: WebGui from 192.168.1.55
18:44:33.944 RSL: RESULT = {"POWER1":"OFF"}
18:44:33.947 RSL: POWER1 = OFF
18:44:34.328 CFG: Salvato nella flash in F7, Conteggio 165, Byte 4096
18:44:35.242 HTP: Console
18:44:43.525 WIF: Controllo connessione...
18:44:49.436 HTP: API Hue (/b23c0c/lights/186892481/state) from 192.168.1.73
18:44:49.439 HTP: POST argomenti Hue ({"on":true})
18:44:49.445 SRC: Hue
18:44:49.449 RSL: RESULT = {"POWER1":"ON"}
18:44:49.452 RSL: POWER1 = ON
18:44:49.454 HTP: Hue Result ([{"success":{"/lights/186892481/state/on":true}}])
18:44:49.536 HTP: API Hue (/b23c0c/lights/186892481) from 192.168.1.73
18:44:49.539 /lights path=/lights/186892481
18:44:49.548 HTP: Hue Result ({"state":{"on":true,"alert":"none","effect":"none","reachable":true},"type":"Extended color light","name":"Fari Cucina","modelid":"Generic","manufacturername":"Tasmota","uniqueid":"84:cc:a8:b2:3c:0c:00:11-01"})
18:44:50.406 CFG: Salvato nella flash in F6, Conteggio 166, Byte 4096

18:45:43.550 WIF: Controllo connessione...
18:45:52.073 HTP: API Hue (/b23c0c/lights/186892483/state) from 192.168.1.73
18:45:52.075 HTP: POST argomenti Hue ({"on":true})
18:45:52.082 SRC: Hue
18:45:52.086 RSL: RESULT = {"POWER3":"ON"}
18:45:52.089 RSL: POWER3 = ON
18:45:52.091 HTP: Hue Result ([{"success":{"/lights/186892483/state/on":true}}])
18:45:52.173 HTP: API Hue (/b23c0c/lights/186892483) from 192.168.1.73
18:45:52.175 /lights path=/lights/186892483
18:45:52.184 HTP: Hue Result ({"state":{"on":true,"alert":"none","effect":"none","reachable":true},"type":"Extended color light","name":"Led Soggiorno","modelid":"Generic","manufacturername":"Tasmota","uniqueid":"84:cc:a8:b2:3c:0c:00:11-03"})
18:45:52.324 CFG: Salvato nella flash in F5, Conteggio 167, Byte 4096

this off light

18:46:25.300 HTP: API Hue (/b23c0c/lights/186892481/state) from 192.168.1.73
18:46:25.303 HTP: POST argomenti Hue ({"on":false})
18:46:25.310 SRC: Hue
18:46:25.314 RSL: RESULT = {"POWER1":"OFF"}
18:46:25.317 RSL: POWER1 = OFF
18:46:25.319 HTP: Hue Result ([{"success":{"/lights/186892481/state/on":false}}])
18:46:25.380 CFG: Salvato nella flash in F4, Conteggio 168, Byte 4096
18:46:25.490 HTP: API Hue (/b23c0c/lights/186892481) from 192.168.1.73
18:46:25.494 /lights path=/lights/186892481
18:46:25.503 HTP: Hue Result ({"state":{"on":false,"alert":"none","effect":"none","reachable":true},"type":"Extended color light","name":"Fari Cucina","modelid":"Generic","manufacturername":"Tasmota","uniqueid":"84:cc:a8:b2:3c:0c:00:11-01"})

18:46:56.467 HTP: API Hue (/b23c0c/lights/186892483/state) from 192.168.1.73
18:46:56.469 HTP: POST argomenti Hue ({"on":false})
18:46:56.476 SRC: Hue
18:46:56.480 RSL: RESULT = {"POWER3":"OFF"}
18:46:56.483 RSL: POWER3 = OFF
18:46:56.485 HTP: Hue Result ([{"success":{"/lights/186892483/state/on":false}}])
18:46:56.567 HTP: API Hue (/b23c0c/lights/186892483) from 192.168.1.73
18:46:56.570 /lights path=/lights/186892483
18:46:56.580 HTP: Hue Result ({"state":{"on":false,"alert":"none","effect":"none","reachable":true},"type":"Extended color light","name":"Led Soggiorno","modelid":"Generic","manufacturername":"Tasmota","uniqueid":"84:cc:a8:b2:3c:0c:00:11-03"})
18:46:57.322 CFG: Salvato nella flash in FB, Conteggio 169, Byte 4096

it does not turn off the lights but de-energises the relay which has remained energized by the on command, in practice by saying light on the relay remains on and does not give the button-type push, by saying light off the relay de-energises and does not turn off the lights because another command would be needed to turn them off

Justin Adie

unread,
Jun 9, 2024, 1:53:18 PMJun 9
to devilx, SonoffUsers
That sounds like you are using DC loads on a triac based “relay”.   There is no zero crossing so the triacs never turn off.  same with SCRs. 

Perhaps post a photograph of your setup and a link to the relay board you are using.


devilx

unread,
Jun 9, 2024, 2:02:21 PMJun 9
to TasmotaUsers
this is how the house relays are connected to the 16 relay board
schematic.jpg

Justin Adie

unread,
Jun 9, 2024, 2:08:58 PMJun 9
to devilx, SonoffUsers
So these are all momentary buttons? 

To turn on or off the actual light you must momentarily send a pulse via the relay.  

Please try this command in the console, assuming the light is off.

Backlog0 pulsetime1 2; power1 1; delay 20; power1 1

If I have understood correctly, the light will turn on and 20 seconds later will turn off.   

Please let us know the result.  



Philip Knowles

unread,
Jun 9, 2024, 2:11:50 PMJun 9
to devilx, TasmotaUsers
Right, the problem is that Alexa doesn't understand that you need to send a pulse for on and a pulse for off so it is just turning the relay on then off when you want to turn it off. You need it to just send a pulse for on and a pulse for off - Alexa has probably got a setting for that.

Sent: 09 June 2024 19:02

Justin Adie

unread,
Jun 9, 2024, 2:19:05 PMJun 9
to Philip Knowles, devilx, SonoffUsers
I’ve never seen that setting. Perhaps one could jury-rig something with routines but that would be bypassing many of the benefits of the Alexa NLP.  

My thought was your frequent go-to of dummy relays and rules.  Only publish the dummy relays to Alexa and then use rules like

On system#boot do pulsetime1 1 endon
On power17#state do power1 1 endon



Philip Knowles

unread,
Jun 9, 2024, 2:41:59 PMJun 9
to Justin Adie, devilx, SonoffUsers
He's got so many relays that it's probably not feasible to use dummy relays. It might be possible to use a 'blind' as they sometimes have pulse inputs.

From: Justin Adie <justi...@adieandco.com>
Sent: 09 June 2024 19:18
To: Philip Knowles <knowles...@gmail.com>; devilx <liber...@gmail.com>
Cc: SonoffUsers <sonof...@googlegroups.com>

devilx

unread,
Jun 9, 2024, 4:15:23 PMJun 9
to TasmotaUsers
i have used this: Backlog0 pulsetime1 2; power1 1; delay 20; power1 1

21:13:54.782 HTP: API Hue (/b23c0c/lights/186892485) from 192.168.1.73
21:13:54.785 /lights path=/lights/186892485
21:13:54.794 HTP: Hue Result ({"state":{"on":false,"alert":"none","effect":"none","reachable":true},"type":"Extended color light","name":"Bagno Giorno","modelid":"Generic","manufacturername":"Tasmota","uniqueid":"84:cc:a8:b2:3c:0c:00:11-05"})
21:13:56.408 HTP: API Hue (/b23c0c/lights/186892481/state) from 192.168.1.73
21:13:56.410 HTP: POST argomenti Hue ({"on":true})
21:13:56.417 SRC: Hue
21:13:56.421 RSL: RESULT = {"POWER1":"ON"}
21:13:56.423 RSL: POWER1 = ON
21:13:56.425 HTP: Hue Result ([{"success":{"/lights/186892481/state/on":true}}])
21:13:56.508 HTP: API Hue (/b23c0c/lights/186892481) from 192.168.1.73
21:13:56.511 /lights path=/lights/186892481
21:13:56.521 HTP: Hue Result ({"state":{"on":true,"alert":"none","effect":"none","reachable":true},"type":"Extended color light","name":"Fari Cucina","modelid":"Generic","manufacturername":"Tasmota","uniqueid":"84:cc:a8:b2:3c:0c:00:11-01"})
21:13:56.705 SRC: PulseTimer
21:13:56.709 RSL: RESULT = {"POWER1":"OFF"}
21:13:56.711 RSL: POWER1 = OFF

21:14:51.520 WIF: Controllo connessione...
21:14:53.078 HTP: API Hue (/b23c0c/lights/186892481/state) from 192.168.1.73
21:14:53.080 HTP: POST argomenti Hue ({"on":false})
21:14:53.087 SRC: Hue
21:14:53.091 RSL: RESULT = {"POWER1":"OFF"}
21:14:53.094 RSL: POWER1 = OFF
21:14:53.096 HTP: Hue Result ([{"success":{"/lights/186892481/state/on":false}}])
21:14:53.177 HTP: API Hue (/b23c0c/lights/186892481) from 192.168.1.73
21:14:53.180 /lights path=/lights/186892481
21:14:53.189 HTP: Hue Result ({"state":{"on":false,"alert":"none","effect":"none","reachable":true},"type":"Extended color light","name":"Fari Cucina","modelid":"Generic","manufacturername":"Tasmota","uniqueid":"84:cc:a8:b2:3c:0c:00:11-01"})

not working 

devilx

unread,
Jun 9, 2024, 4:19:49 PMJun 9
to TasmotaUsers
in tasmota it is only possible to send an on impulse, not an on impulse that turns the light on and then turns it off immediately

Justin Adie

unread,
Jun 9, 2024, 4:49:30 PMJun 9
to devilx, SonoffUsers
That tells us that tasmota is working. 

Your problem is not tasmota related.  Rather it is caused by your choices of hardware; in the sense that you have a latching main relay, a momentary switch and an ordinary IoT relay.  

Your options are:

1. use virtual relays.  You will probably need to change to an ESP32 device (which also provides many more solutions).  With this route the state of the device (light) will be persistent however it may not be synchronised with the actual device. 
2. instead of using a single relay board, instead use modules that fit inside the backbox of your momentary switches.  I’d recommend choosing zigbee boxes and buy a zigbee coordinator that can use tasmota (the zigbee bridge pro for example).  This route will mean more devices but the state will always be reported accurately.  
3. use an intermediary such as node-red on a raspberrypi.  
4. change to normal relay/contactors and normal switches.  

In my home, I use a mixture of solution 2 and 3.  



devilx

unread,
Jun 10, 2024, 11:58:04 AMJun 10
to TasmotaUsers

Justin Adie

unread,
Jun 10, 2024, 12:09:06 PMJun 10
to devilx, TasmotaUsers
Tasmota is firmware that addresses gpio pins on an esp32 board.

A gpio pin set as output can either be on or off. 

What you do with that logic outside of the esp32 is up to you as the user.  

So tasmota can turn its pin on or off or it can pulse it on a given duty cycle.

None of this helps you because you have chosen to use a latching relay.   

I've responded yesterday with possible solutions, but this is not a tasmota issue.



On Mon, 10 Jun 2024, 16:58 devilx, <liber...@gmail.com> wrote:
in tasmota it is only possible to send an on impulse, not an on impulse that turns the light on and then turns it off immediately

--
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.

Philip Knowles

unread,
Jun 10, 2024, 5:09:45 PMJun 10
to devilx, TasmotaUsers
The problem isn't Tasmota (or Alexa) but the device you are operating. Alexa and Tasmota are speaking 'English' and device you are controlling is speaking 'French'. I suggested trying a garage door (rather than a socket) as the option in Alexa. Many garage doors have a pulse to open and a pulse to close..

Sent: 10 June 2024 16:58

To: TasmotaUsers <sonof...@googlegroups.com>
Subject: Re: tasmota and light on off
in tasmota it is only possible to send an on impulse, not an on impulse that turns the light on and then turns it off immediately

--
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.

devilx

unread,
Jun 16, 2024, 1:43:19 PMJun 16
to TasmotaUsers
Excuse me so you say to configure Alexa as a garage door and not as a light?

Philip Knowles

unread,
Jun 16, 2024, 3:28:41 PMJun 16
to devilx, TasmotaUsers
It's worth trying. Some garage door openers work on a pulse to open and a pulse to close so it may work

Sent: 16 June 2024 18:43

To: TasmotaUsers <sonof...@googlegroups.com>
Subject: Re: tasmota and light on off
Excuse me so you say to configure Alexa as a garage door and not as a light?

Il giorno lunedì 10 giugno 2024 alle 23:09:45 UTC+2 knowles...@gmail.com ha scritto:
The problem isn't Tasmota (or Alexa) but the device you are operating. Alexa and Tasmota are speaking 'English' and device you are controlling is speaking 'French'. I suggested trying a garage door (rather than a socket) as the option in Alexa. Many garage doors have a pulse to open and a pulse to close..

Sent: 10 June 2024 16:58

To: TasmotaUsers <sonof...@googlegroups.com>
Subject: Re: tasmota and light on off
in tasmota it is only possible to send an on impulse, not an on impulse that turns the light on and then turns it off immediately

--
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.

--
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.

devilx

unread,
Jun 16, 2024, 5:01:13 PMJun 16
to TasmotaUsers
what I don't understand is that my Alexa recognizes the Tasmota as a Philips light, how can I tell it's a gate. should I use a switch command?

Philip Knowles

unread,
Jun 17, 2024, 2:22:56 AMJun 17
to devilx, TasmotaUsers
The problem is the device Tasmota is controlling. Alexa sees it as an on/off switch device not a push for on/push for off. If you remove the device and manually add as a garage door opener rather than auto configure. If that doesn't work you will need to use Rules.
The device needs a pulse to switch it. Using pulsetime operates the device BUT Alexa sees the Tasmota output go ON then OFF so it thinks the light has been operated manually and is now OFF.
If you create a dummy relay (Relay1) on a spare GPIO which Alexa controls and Relay2 (which operates the device using pulsetime)
Then
Rule1 on relay1#state do relay2 1 endon
Otherwise you will need an external device to convert the on and off to pulses.
Sent: Sunday, June 16, 2024 10:01:13 PM

Justin Adie

unread,
Jun 17, 2024, 3:23:15 AMJun 17
to Philip Knowles, devilx, SonoffUsers
>>>Rule1 on relay1#state do relay2 1 endon

Can you now refer to relays by their name rather than power2 etc?  And would the command not be power2 2. ? 

I,e, you want the real relay to be toggled for each change in state of the virtual relay. 



Justin Adie

unread,
Jun 17, 2024, 5:33:42 AMJun 17
to Philip Knowles, devilx, SonoffUsers
My mistake. 

It should be 1 of course since this is a latching relay.  

The disadvantage of the way that the OP has wired everything is that Alexa will not be able to track the state of the light, even when using virtual relays.  Solution would be to wire the switches into the esp module or use switch modules. 

Since the OP is using a 16 relay module there may be an issue with available pins (although perhaps this is an i2c relay module) 

Philip Knowles

unread,
Jun 17, 2024, 6:09:39 AMJun 17
to Justin Adie, devilx, SonoffUsers
Sorry was typing on my phone and got confused with taking about relays earlier.

It should be
on power1#state do power2 1 endon
It will be power2 1 because it is sending a pulse (will be turned off by pulsetime) not 'toggling'
Every time relay1 changes state it will send a pulse. This isn't a complete solution because the manual switches could also have changed the state of the light and neither Alexa or Tasmota will be aware.
My honest opinion would be to use a Shelly1 and scrap the separate ESP and pulse driver

From: Justin Adie <justi...@adieandco.com>
Sent: 17 June 2024 08:22
To: Philip Knowles <knowles...@gmail.com>
Cc: devilx <liber...@gmail.com>; SonoffUsers <sonof...@googlegroups.com>

devilx

unread,
Jun 17, 2024, 3:27:33 PMJun 17
to TasmotaUsers
ok I understand that with hardware in my possession I can't do anything. I'll try the garage door solution and let you know

devilx

unread,
Jun 18, 2024, 12:37:47 AMJun 18
to TasmotaUsers
deleted a light, tried to manually make it recognize it as a garage door, but it doesn't work, alexa always recognizes it as a light.

Justin Adie

unread,
Jun 18, 2024, 3:08:26 AMJun 18
to devilx, TasmotaUsers
This will always be the case using hue emulation on a tasmota.

However tasmota may do things differently under the hood if you use a garage door opener configuration.  Personally I don't think it will help you but my fingers are crossed.

I have posted other solutions.  Changing the hardware you use or the wiring will work.

Another thing that may work is to change your invocation.  For example create a standard relay in tasmota, turn on hue emulation and have Alexa recognise the relay as a light set pulsetime for that relay to 1 second.  Let's say that the light is called light one.  Then create a rule in Alexa that listens for "Toggle Light One" and the action would be to turn on that particular light.   

Tasmota handles the pulse and Alexa will show the light being briefly on then off.  You cannot avoid the Alexa or Tasmota UI being wrong with your set up as there is no way that Tasmota can know the actual state of the light as there is a manual switch wired in parallel.

For a more natural invocation you could do this 

1. Set up the relay as before. Give it a friendly name that is unlikely to be used in speech.  Do not add the device to a group/room.
2.  Create two rules in Alexa.  One for turn on the light (using a sensible descriptive name). And the second for turn off the light.
3.  For both rules set the action to be turning on the relay.  


Changing the wiring would give you a neater solutions.  Spending a few $ to change to an esp32 module would also increase your options. 

devilx

unread,
Jun 20, 2024, 12:28:10 AMJun 20
to TasmotaUsers
which esp32 module do you recommend??

Philip Knowles

unread,
Jun 20, 2024, 5:59:04 AMJun 20
to devilx, TasmotaUsers
I would actually go for a Shelly 1. It will accept a mains input so could 'read' the status of your 'real' light switches and connect them direct to the Shelly. Flashed with Tasmota you can create the dummy relay to 'fool' Alexa. The real relay (Relay2) would send a pulse for on and another for off but the virtual relay (Rerlay1) would report the status to Alexa

Sent: 20 June 2024 05:28

Justin Adie

unread,
Jun 20, 2024, 6:52:56 AMJun 20
to Philip Knowles, devilx, SonoffUsers
Would the OP need 16 shelly 1 devices?  One for each switch/relay pair he/she is looking to automate?



Philip Knowles

unread,
Jun 20, 2024, 7:07:00 AMJun 20
to Justin Adie, devilx, SonoffUsers
Possibly but only for the devices that require the pulse to turn them on/off. The current setup won't work but the Shelly1 (or 2 or i4)  would actually work properly for Alexa (including monitoring the manual switches) 

From: Justin Adie <justi...@adieandco.com>
Sent: 20 June 2024 11:52

Justin Adie

unread,
Jun 20, 2024, 7:11:17 AMJun 20
to Philip Knowles, devilx, SonoffUsers
Would there not still be a difficulty in knowing the state of the light/end device as the switches etc are decoupled by the latching relay?  Alexa would still not necessarily send an “off” command if hue was reporting that the device were already off.  

Perhaps an idea to remove the latching relays from the equation.

Philip Knowles

unread,
Jun 20, 2024, 7:39:22 AMJun 20
to Justin Adie, devilx, SonoffUsers
No, because the Shelly can monitor the physical light switches (because it can accept a mains input), the dummy relay should be mirroring the actual state of the light (whether operated by Alexa or the switches). So
Alexa says switch on > physical relay in Shelly pulses (turns light on) > dummy relay goes on > Alexa sees light is on
Alexa says switch off (dummy relay is on) > Shelly pulses (turns light off) > dummy relay goes off > Alexa sees light is off
OR
Manual switch operated (dummy relay is on) > Shelly pulses (turns light off > dummy relay goes off > Alexa sees light is off 
Manual switch operated (dummy relay is off) > Shelly pulses (turns light on > dummy relay goes on > Alexa sees light is on

There's always a possibility of going out of sync (but resolved with a power off) 

From: Justin Adie <justi...@adieandco.com>
Sent: 20 June 2024 12:10
Reply all
Reply to author
Forward
0 new messages