How to re-apply wifi credentials with ESP-IDF without device restart?

wojo1206
Posts: 1
Joined: Mon Jun 24, 2019 6:10 pm

How to re-apply wifi credentials with ESP-IDF without device restart?

Postby wojo1206 » Mon Sep 09, 2019 7:38 pm

Using provisioning manager over BLE, once bad credentials have been applied, I have to clear NVS and reset the device to allow for accepting new wifi credentials. This brakes the BLE connection and UX suffers because user has to re-connect the device.

This is the typical message if you want to apply wifi credentials more than once during one session "wifi_prov_handlers: Failed to apply Wi-Fi Credentials".

I am looking for solution that allows new set of credentials without restarting the device. Digging into source I couldn't find obvious functions. I am pretty sure that wifi state has to be set to WIFI_PROV_STATE_IDLE somehow.

I am using ESP-IDF: v3.3 LTS

Who is online

Users browsing this forum: Baidu [Spider], Bing [Bot] and 123 guests