Merge pull request #1413 from entr0p1/powermgt-nrf52840-v2

nRF52840 Power Management v2 Phase 1 - LPCOMP Wake and startup lockout
This commit is contained in:
ripplebiz
2026-01-24 21:51:06 +11:00
committed by GitHub
17 changed files with 667 additions and 24 deletions

View File

@@ -30,6 +30,14 @@
#define AREF_VOLTAGE (3.0)
// Power management boot protection threshold (millivolts)
// Set to 0 to disable boot protection
#define PWRMGT_VOLTAGE_BOOTLOCK 3300 // Won't boot below this voltage (mV)
// LPCOMP wake configuration (voltage recovery from SYSTEMOFF)
// AIN2 = P0.04 = BATTERY_PIN / PIN_VBAT_READ
#define PWRMGT_LPCOMP_AIN 2
#define PWRMGT_LPCOMP_REFSEL 1 // 2/8 VDD (~3.68-4.04V)
////////////////////////////////////////////////////////////////////////////////
// Number of pins