Chat freely about anything...

User avatar
By RogerClark
#4831 Hi,
I've been looking at some of the demo code, and I can see how to connect to a AP, but it looks like when the code is rebooted, that the SDK automatically takes care of connecting to an AP

Does the SDK always do this, if the last command to the wifi was to make a connection to an AP?

I presume the only way to determine if the SDK has finished connecting to an AP is to keep calling wifi_station_get_connect_status(); on a timer e.g. ever second untill the connection is established ??
User avatar
By Athena
#5648 Call wifi_station_set_auto_connect(0); in user_init() to disable auto_connecting to AP.

You could refer to user_esp_platform_check_ip() to check if the connection to AP succeeded.

Thanks for your interest in ESP8266 ! Merry Christmas!