My T4EU1C switch is going unavailable in home assistant. Seems to stay available as long as it is in use. Just tried blocking internet access. Will report back if it helps. I notice there is an issue on GitHub about switches going unavailable. This could be the same issue.
EDIT: I can confirm that not allowing the switch to contact the internet appears to have solved this problem so far. It’s a shame that the WiFi light is always flashing like this.
Small contribution from Spain. To capture the Api Key, you can simply put the sonoff on pairing mode, connect your tablet or mobile (in my case an Ipad) to the wifi created by the sonoff (pwd:12345678) and launch from the navigator (in my case safari) “http://10.10.7.1/device”. The sonoff will inmediately return the device ID and the Api Key.
Started to notice that since I blocked the internet on my routers fitewall, the switch loses WiFi every few minutes (is it rebooting/watchdog). This also makes it go unavailable. Might flash this soon. Anyone else having this issue? Turned internet back on for now and it seems to be staying connected to WiFi for longer but expect it to go unavailable again.
Given up with this now, with internet blocked SONOFF keeps disconnecting from WiFi every minute or so. With internet open it stays connected to WiFi but keeps going out of Lan mode and showing unavailable.
T4EU1C now has remains of a bit of solder on R10 and Tasmota 6.7.1 installed. My touch panel is working with no modifications.
I’ve recently become frustrated with my Sonoff S31s and the extensive delays in updates for power usage (my poor washing machine automations!), so went ahead with the custom_component as described above.
Not sure what I’m doing wrong – I’ve restricted outbound internet to make sure they stay in LAN mode, and have double-checked the IDs vs the API keys. I can see in the debug log all kinds of entries w/ the data I’m after but I don’t see any devices in Home Assistant…
EDIT
OK I lied - I can now see them in HomeAssistant (and there was much rejoicing?)
But they are coming back as unavailable – I’m guessing the message structure doesn’t match what the component is expecting?
You didn’t mention what kind of device you were using – on the S31, I had to put it in pairing mode and THEN hold the pairing button for an additional 10s or so to get it to go into a mode that let me do the wifi pairing method (i.e. joining the ad-hoc wifi network w/ the complicated Spaceballs-esque password of ‘12345678’).
I just posted an update to support it as a switch, but I haven’t added the temperature to the component yet. I will do in due course if you can confirm that it is working as a switch now
What firmware version is it running? I saw some info that said LAN mode wasn’t supported with the multi gang T1s, but they may we’ll be out of date as the same page had lots of information I know to be out of date!
its running 3.3.0 firmware. using eweling app lan mode is working, i can control the tx 3gang without internet enabled. THe only problem is that i cannot get the apikey. with sonoff mini i used the 10.10.7.1/device while connected to the itead wifi, now i reset the device through ewelink app but i cannot see the itead wifi…how to get the apikey?
edit: it was my error, i have now device id and apykey, but added to HA i see only a switch, instead of 3 switch…ho to get all of them?
Yep, its getting harder to get the key, here’s my docs I’ve written on it. Basically, for these 3.3 devices, I think you need to sniff the LAN, there a couple of pointers on how to go about this in the docs
All its working! I got the api Key with http://10.10.7.1/device
The 3gang Is working with the outlet parameter set for each gang
No issues! Its US model