Page 1 of 1

Clean disconnection of wifi by calling esp_wifi_stop()

Posted: Fri Nov 01, 2019 10:44 am
by Zeni241
Why I get message :

Code: Select all

E (21326) event: system_event_sta_disconnected_handle_default 294 esp_wifi_inter
nal_reg_rxcb ret=0x3014
When I call

Code: Select all

esp_wifi_stop();
.
How can I stop WiFi in clean way so that mqtt don't get "lwt" message?

Re: Clean disconnection of wifi by calling esp_wifi_stop()

Posted: Sat Jan 18, 2020 7:50 am
by nopnop2002
Unregister handler before stopping wifi