I have two ESP8266’s that each control one LED light strip mounted underneath basement step railings that light up with a moving pattern for two minutes when one of the motion sensors is triggered (motion at bottom, pattern moves up, motion at top, pattern moves down). Pretty slick!
I had bad WiFi connectivity problems early on but have resolved those - except for one issue. I shielded the cables, ensured the ESP8266’s were not near any interference - so now all is well… EXCEPT - whenever the wireless access point they are using is rebooted - or the router is rebooted - they lose their WiFi connection - but will not reconnect on their own. When I press the reboot button on each ESP8266 board they reboot and reconnect instantly. Then they will stay connected (even for several weeks at a time) - but once they are disconnected from the WiFi due to an aforementioned WAP or router reboot - they won’t reconnect unless I reboot the ESP8266. What is wrong with any retry/reconnect logic in the ESP8266’s?
Yes they are on a different IOT vlan than the rest of the network thatis only 2.4ghz and mDNS discovery is turned on with the correct bonjour services. Curently the firmware on both ESP8266’s is WLED 0.15.0 (build 2412100). There is an "experimental’ setting “disable WiFi sleep” which I am now trying… Other than that, any ideas?
If you have proper mesh system this shouldn’t be happening. Maybe your wifi coverage is not strong enough as you think and esp board can’t reconnect to other router.
In my case if i reboot one router that have esp devices connected to it they will reconnect to another router acting as ap without me noticing it.
Later they will reconnect again to the first router if it have stronger signal.
Edit:
Maybe it is just wifi roaming problem. Imho the best way to test this out is to plug another esp board close to this one and reboot router. See will it reconnect. If it doesn’t then it is wifi problem.
I wish it was that simple. I have Cat6 Ethernet going out to several wireless access points and the signal by the esp8266’s is very strong, 98% (-52dBm), so that’s not the issue -
HA is designed to run on a flat network, so this is the most likey choke point.
double check this stuff with some networking tools to make sure your data is making it thru or just flatten the network and try as a test to eliminate the question at least temporarily.
Data is making it through as it does work all the time (until there is a WiFi disconnection - e.g., the related access point is rebooted etc.) and I do have mDNS reflection turned on going in both directions. The experimental “disable wifi sleep” seems to be helping but not perfect. What networking tools do you suggest? Wouldn’t it not ever work if being on a different vlan was in fact the issue?
Try with another Firmware lile esphome if you can recreate the issue - if not it is a bug in WLED… If yes it might be low level arduino/esp-idf framework related
I had a similar problem with devices dropping WiFi and struggle to be back on line. I found that my home router could only handle about 25 WiFi connections. I got a Ubiquiti Access Point (I don’t recommend Ubiquity … bloatware) which can handle 300 WiFi connections. Once employed, I didn’t have WiFi problems.
To see if this is your problem, shutdown a couple WiFi devices and reboot your router.
Thank you @OldSurferDude. I am sure that is the cause of alot of issues when people have numerous devices connected to an all-in one router or to an access point that is connected to an all-in one router. Early on I had those issues and it took a while on a shoestring budget with about 2 years of endless manual tweaking but I switched to a wired only router and set up properly strategically placed access points all of which are connected by ethernet to the router (some through a switch). Here is my network topology and the current number of hardwired and wireless connections:
The only thing I can say is once every couple of months one of the access points will get disconnected and the vast majority of wireless devices connected to it seamlessly connect to the next nearest access point. You will note the “Upstairs EAP225 WAP” only has two clients connected at this time but that is because I just rebooted it about an hour ago. The WLEDs under discussion are right near both the basement and mid-house access points.
So it’s my opinion it may be the way I have the main IOT WiFi SSID set up (which they are currently using)? I do have a couple really lousy designed IOT devices for which I have set up a separate dedicated WiFi SSID for each (which do ultimately connect to the same IOT VLAN), and the WiFi connection settings for those are simplified and set up for the best reliability for those IOT devices (and sometimes implemented only on the nearest WAP), which has really solved their connectivity issues. However in this case the connectivity is great but the “re-connection” logic has a problem… Maybe I should set up another dedicated WiFi SSID for the WLED’s? In that case which specific WiFi settings would I customize for the ESP8266’s with this WLED firmare to maximize any “reconnect functionality” they have?
I think setting up a separate SSID would be an excellent experiment!
I’m not an expert, but I’m pretty sure that having multiple access points with the same SSID is problematic. In theory, Mesh networks are designed with multiple access points with a single SSID, but I don’t think an ad hoc “mesh” works so well.
Tasmotized ESPs have a fallback SSID. I have never employed this feature. I think that means that if the device cannot connect to the primary, it will try to connect to the fallback. I think I’ll experiment with that.
Yes but I am only hesitant because if the separate SSID is set up the same way as the SSID it is currently on, that would probably not resolve the issue, that is why I am fishing for ideas from folks…
Actually what I was thinking was set it up on a separate access point. On my router (access point) I can have up to 8 SSIDs, When I do that, though, they are all on the same WiFi channel. There is almost no difference between how the access point sees WiFi devices that connect using the different SSIDs of the access point.
Doing the experiment with different access points will tell you if the problem is the access point or the device. That is, if the two devices have the problem when using a different access point, it is something in the devices software/firmware. If the problem goes away when a separate access point is employed, it is something going on with the access point.
Note: be sure that the two access points are on different channels. There is a phone app (WiFi analyzer, I think), that can show you the channels that the access point is using.
I make the assumption that you have another access point.