mirror of
https://github.com/meshtastic/firmware.git
synced 2025-02-08 21:51:46 +00:00
move the factory reset stuff above the ble bonds
This commit is contained in:
parent
67bc6b1419
commit
d57ac39b02
@ -97,6 +97,13 @@ bool NodeDB::resetRadioConfig()
|
|||||||
nvs_flash_erase();
|
nvs_flash_erase();
|
||||||
#endif
|
#endif
|
||||||
#ifdef NRF52_SERIES
|
#ifdef NRF52_SERIES
|
||||||
|
|
||||||
|
installDefaultDeviceState();
|
||||||
|
installDefaultRadioConfig();
|
||||||
|
installDefaultChannels();
|
||||||
|
saveToDisk();
|
||||||
|
saveChannelsToDisk();
|
||||||
|
|
||||||
Bluefruit.begin();
|
Bluefruit.begin();
|
||||||
|
|
||||||
DEBUG_MSG("Clearing bluetooth bonds!\n");
|
DEBUG_MSG("Clearing bluetooth bonds!\n");
|
||||||
@ -106,11 +113,6 @@ bool NodeDB::resetRadioConfig()
|
|||||||
Bluefruit.Periph.clearBonds();
|
Bluefruit.Periph.clearBonds();
|
||||||
Bluefruit.Central.clearBonds();
|
Bluefruit.Central.clearBonds();
|
||||||
|
|
||||||
installDefaultDeviceState();
|
|
||||||
installDefaultRadioConfig();
|
|
||||||
installDefaultChannels();
|
|
||||||
saveToDisk();
|
|
||||||
saveChannelsToDisk();
|
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
didFactoryReset = true;
|
didFactoryReset = true;
|
||||||
|
Loading…
Reference in New Issue
Block a user