mirror of
https://github.com/meshtastic/firmware.git
synced 2025-06-22 04:54:47 +00:00
Fixes
This commit is contained in:
parent
1b852a254b
commit
fae59fa9c9
@ -1051,7 +1051,7 @@ int32_t Screen::runOnce()
|
|||||||
handleShutdownScreen();
|
handleShutdownScreen();
|
||||||
break;
|
break;
|
||||||
case Cmd::START_REBOOT_SCREEN:
|
case Cmd::START_REBOOT_SCREEN:
|
||||||
handleShutdownScreen();
|
handleRebootScreen();
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
DEBUG_MSG("BUG: invalid cmd\n");
|
DEBUG_MSG("BUG: invalid cmd\n");
|
||||||
|
@ -211,11 +211,12 @@ void AdminModule::handleSetConfig(const Config &c)
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool didSave = service.reloadConfig();
|
service.reloadConfig();
|
||||||
|
|
||||||
// Reboot 5 seconds after a config that requires rebooting is set
|
// Reboot 5 seconds after a config that requires rebooting is set
|
||||||
if (didSave && requiresReboot) {
|
if (requiresReboot) {
|
||||||
rebootAtMsec = millis() + 5 * 1000;
|
DEBUG_MSG("Rebooting due to config changes\n");
|
||||||
|
screen->startRebootScreen();
|
||||||
|
rebootAtMsec = millis() + (5 * 1000);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -98,6 +98,7 @@ class NimbleBluetoothServerCallback : public NimBLEServerCallbacks
|
|||||||
passkeyShowing = false;
|
passkeyShowing = false;
|
||||||
screen->stopBluetoothPinScreen();
|
screen->stopBluetoothPinScreen();
|
||||||
}
|
}
|
||||||
|
bluetoothPhoneAPI->setInitalState();
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void onDisconnect(NimBLEServer* pServer, ble_gap_conn_desc *desc)
|
virtual void onDisconnect(NimBLEServer* pServer, ble_gap_conn_desc *desc)
|
||||||
@ -127,6 +128,9 @@ bool NimbleBluetooth::isActive()
|
|||||||
|
|
||||||
void NimbleBluetooth::setup()
|
void NimbleBluetooth::setup()
|
||||||
{
|
{
|
||||||
|
// Uncomment for testing
|
||||||
|
// NimbleBluetooth::clearBonds();
|
||||||
|
|
||||||
DEBUG_MSG("Initialise the NimBLE bluetooth module\n");
|
DEBUG_MSG("Initialise the NimBLE bluetooth module\n");
|
||||||
|
|
||||||
NimBLEDevice::init(getDeviceName());
|
NimBLEDevice::init(getDeviceName());
|
||||||
|
@ -209,8 +209,9 @@ void NRF52Bluetooth::shutdown()
|
|||||||
|
|
||||||
void NRF52Bluetooth::setup()
|
void NRF52Bluetooth::setup()
|
||||||
{
|
{
|
||||||
Bluefruit.Periph.clearBonds();
|
// Uncomment for testing
|
||||||
Bluefruit.Central.clearBonds();
|
// Bluefruit.Periph.clearBonds();
|
||||||
|
// Bluefruit.Central.clearBonds();
|
||||||
|
|
||||||
// Initialise the Bluefruit module
|
// Initialise the Bluefruit module
|
||||||
DEBUG_MSG("Initialise the Bluefruit nRF52 module\n");
|
DEBUG_MSG("Initialise the Bluefruit nRF52 module\n");
|
||||||
|
@ -8,7 +8,6 @@ void powerCommandsCheck()
|
|||||||
{
|
{
|
||||||
if (rebootAtMsec && millis() > rebootAtMsec) {
|
if (rebootAtMsec && millis() > rebootAtMsec) {
|
||||||
DEBUG_MSG("Rebooting\n");
|
DEBUG_MSG("Rebooting\n");
|
||||||
screen->startRebootScreen();
|
|
||||||
#if defined(ARCH_ESP32)
|
#if defined(ARCH_ESP32)
|
||||||
ESP.restart();
|
ESP.restart();
|
||||||
#elif defined(ARCH_NRF52)
|
#elif defined(ARCH_NRF52)
|
||||||
|
Loading…
Reference in New Issue
Block a user