Can you turn off WiFi.listen() once it starts? and what is the purpose of WiFi.listening()? [SOLVED]

You’re totally right - WiFi.listen() will block the main user loop.

You could setup a interrupt routine that is called from a timer, which checks WiFi.listening() to know if the system is listening or not.

To exit listening, as a quick hack, you could set WLAN_SERIAL_CONFIG_DONE to 1 to cause WiFi.listening() to exit. But please keep in mind that access to internal variables will be replaced by an API in future versions.

Hope that helps! :slight_smile:

1 Like