-
Notifications
You must be signed in to change notification settings - Fork 639
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
SonOff Touch stability issues #327
Comments
Original comment by Kruno M (Bitbucket: Kruu51, GitHub: Unknown): Yes, I also got my first Touch. Flashed it and the same problem here. But When I disable mqtt and domoticz it works OK for now. |
Original comment by Yann LEFEBVRE (Bitbucket: Battosai30, GitHub: Battosai30): I tried with 1.10.0 => same result So I just simplified the button routines to that :
And it works. I can spam the button, it does not seems to crash and MQTT is well updated. It confims my first diagnostic and it explains why no one else has this kind of problem on others sonoff modules. As the crash does not always lead to a complete reset, I suspect a memory leak or something of this kind. I have not more time this week to investigate but I found that :
You're shifting unsigned char by more that 8 without any cast or conversion, so the differents values may be lost during the shifting. I added a conversion but it didn't solve the issue. |
The issue you are describing it's the default behaviour for ESPurna buttons (double click means AP mode, long click reset). But you are right it does not make sense for wall switches like the TOUCH or the T1, instead I have changed the default behaviour to:
So it will toggle on press and only reset on long long click (more than 10 seconds holding the button). Changing that configuration in the hardware.h file should fix the "stability" issues you describe. But you are right about the casting issue in the buttonStore method. |
Original comment by Yann LEFEBVRE (Bitbucket: Battosai30, GitHub: Battosai30): Ow ok, it makes sense :) Thank you I will test it ;) |
Removing milestone: 1.11.3 (automated comment) |
Originally reported by: Yann LEFEBVRE (Bitbucket: Battosai30, GitHub: Battosai30)
Hi,
I tested your firmware but I met a lot of stability problems and I think I localised it. So I have stability issues when I press the button several times in a row (sometimes just a double click is enough). Sometimes the module reboots and sometimes it just restart the wifi connexion. I also noticed that joining my network (beforehand added in web interface) could be very long.
I tried .bin 1.10.1 and I tried recompiled in Arduino with minimalist function activated and the results are the same. First I thought it was a power issue, so I added a capacitor => no effect and I tested with another supply source ==> no effect too. So I rewrote my own little firmware to connect to my wifi, and upload information on my MQTT broker and it works very well. I think I found some potentials problem sources but did not had the time to test it for now.
Regards
The text was updated successfully, but these errors were encountered: