mirror of
https://github.com/tzapu/WiFiManager.git
synced 2026-04-27 00:55:52 +03:00
[GH-ISSUE #912] Would it be possible to not let autoConnect block the setup? #774
Labels
No labels
📶 WiFi
🕸️ HTTP
Branch
DEV Help Wanted
Discussion
Documentation
ESP32
Example
Good First Issue
Hotfix
In Progress
Incomplete
Needs Feeback
Priority
QA
Question
Task
Upstream/Dependancy
bug
duplicate
enhancement
invalid
pull-request
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/WiFiManager#774
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @markg85 on GitHub (Jul 13, 2019).
Original GitHub issue: https://github.com/tzapu/WiFiManager/issues/912
Hi,
Currently the autoConnect function blocks the setup till it either makes a wifi connection or sets itself up as AP in case it couldn't make a connection.
That on it's own is awesome!
However, i'm now playing with a usecase where i want to fade a light in as soon as the device turns on. That "fading in" is something that's run in the loop function. And that loop function only starts when the setup is done... which autoconnect is blocking... :)
Another thing i want to do is pulsate the light while a wifi connection is being made. Those are 2 reason why having it blocking it really inconvenient.
I could.... use interrupts and work around it that way, but that feels a bit hacky.
So therefore i'm wondering if it would be possible to make autoconnect non blocking?
An approach that i can think of would be to let WiFiManager know that i want to use auto connect (say with a new function: setAutoconnect(true)). Then have another new function like loop() or handle() that should be placed in the main loop function to handle the wifi connection as it's made.
Just curious...
Cheers,
Mark
@tablatronix commented on GitHub (Jul 13, 2019):
#379
#818
Development branch
#500
@markg85 commented on GitHub (Jul 13, 2019):
Ha, that's awesome!
I am hesitant to upgrade to the dev branch, but i think i'm going to give it a shot now. As with this it already has 3 features that i requested before...