diff options
| author | Selene ToyKeeper | 2024-03-26 04:31:04 -0600 |
|---|---|---|
| committer | Selene ToyKeeper | 2024-03-26 04:31:04 -0600 |
| commit | 39d2e9f2b7d221c1e7a2f6018ba7646e3ec22413 (patch) | |
| tree | fd29c395b561959508e9af3d68bd9a0bfb6cd9a2 /hw/hank/emisar-d3aa/hwdef.h | |
| parent | d3aa: got weak battery detection actually working, (diff) | |
| download | anduril-39d2e9f2b7d221c1e7a2f6018ba7646e3ec22413.tar.gz anduril-39d2e9f2b7d221c1e7a2f6018ba7646e3ec22413.tar.bz2 anduril-39d2e9f2b7d221c1e7a2f6018ba7646e3ec22413.zip | |
weak battery detection: use different thresholds for AA and Li-Ion
(also, fixed bug where a totally empty li-ion didn't get limited)
Diffstat (limited to 'hw/hank/emisar-d3aa/hwdef.h')
| -rw-r--r-- | hw/hank/emisar-d3aa/hwdef.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/hw/hank/emisar-d3aa/hwdef.h b/hw/hank/emisar-d3aa/hwdef.h index 7cd2849..7fbffbe 100644 --- a/hw/hank/emisar-d3aa/hwdef.h +++ b/hw/hank/emisar-d3aa/hwdef.h @@ -119,8 +119,9 @@ enum CHANNEL_MODES { // (also helps protect firmware flashing adapters from overload) #define USE_RAMP_LEVEL_HARD_LIMIT #define USE_WEAK_BATTERY_PROTECTION -#define WEAK_BATTERY_TEST_MAX_LEVEL 75 // about 300 mA -#define WEAK_BATTERY_SAG_THRESHOLD (5*4) // 0.5 V +#define WEAK_BATTERY_TEST_MAX_LEVEL 75 // about 300 mA +#define WEAK_BATTERY_SAG_THRESHOLD_AA (3*4) // 0.3 V +#define WEAK_BATTERY_SAG_THRESHOLD_LIION (6*4) // 0.6 V // average drop across diode on this hardware #ifndef VOLTAGE_FUDGE_FACTOR |
