mirror of
https://github.com/mikecarper/MeshCore.git
synced 2026-09-16 18:12:36 +00:00
Harden nRF52 OTA, USB sessions, and T096 controls
Bind Companion replies to request transports, make dual-CDC USB sessions nonblocking and reconnect-safe, and harden nRF52 watchdog/OTA storage paths. Fix T096 button debounce, display wake, sleep races, and the compact message layout; add exact WisBlock OTA profiles plus expanded native/static/HIL documentation.
This commit is contained in:
@@ -184,8 +184,14 @@ void loop() {
|
||||
external_watchdog.loop();
|
||||
#endif
|
||||
|
||||
if (the_mesh.getNodePrefs()->powersaving_enabled
|
||||
&& !board.isUsbDataConnected()) {
|
||||
bool can_power_save = the_mesh.getNodePrefs()->powersaving_enabled
|
||||
&& !board.isUsbDataConnected();
|
||||
#if defined(MOMENTARY_BUTTON_WAKE_FROM_SLEEP) \
|
||||
&& MOMENTARY_BUTTON_WAKE_FROM_SLEEP \
|
||||
&& defined(PIN_USER_BTN) && defined(DISPLAY_CLASS)
|
||||
can_power_save = can_power_save && !user_btn.needsPolling();
|
||||
#endif
|
||||
if (can_power_save) {
|
||||
uint32_t sleep_secs = the_mesh.getPowerSaveSleepSeconds(30);
|
||||
#ifdef HAS_EXTERNAL_WATCHDOG
|
||||
if (sleep_secs > 0) external_watchdog.feed();
|
||||
|
||||
Reference in New Issue
Block a user