mirror of
https://github.com/iNavFlight/inav.git
synced 2025-07-26 01:35:35 +03:00
Improve battery monitoring (#2705)
* increase battery voltage resolution to 10mV * increase battery voltage resolution to 10mV: update VBATT_HYSTERESIS * increase battery voltage resolution to 10mV: fix telemetry and other places where vbat calculations needs to be divided by 10 * increase battery voltage resolution to 10mV: revert blackbox data to 100mV resolution because modifying the viewer is not trivial * increase battery voltage resolution to 10mV: change new MSPv2 frame type names to follow convention * smartport telemetry: remove wrong and now irrelevant comments * Improve battery monitoring * improve battery monitoring: fix/simplify the batteryAdcToVoltage function * improve battery monitoring: Add OSD voltage decimals setting to OSD MISC menu * improve battery monitoring: clean the batteryConfig struct * improve battery monitoring: increase batteryConfig PG group version to 1 * improve battery monitoring: change capacity settings type from uin16_t to uint32_t (65Wh is not very large, it is about 6Ah for a 3S Li-Po) * improve battery monitoring: rename capacity settings * improve battery monitoring: improve OSD code * improve battery monitoring: simplified taskUpdateBattery * improve battery monitoring: use unfiltered vbat to decide if the battery is full
This commit is contained in:
parent
d0feb4d998
commit
f00194c167
35 changed files with 646 additions and 311 deletions
|
@ -87,9 +87,18 @@ static OSD_Entry menuMiscEntries[]=
|
|||
|
||||
OSD_SETTING_ENTRY("MIN THR", SETTING_MIN_THROTTLE),
|
||||
#ifdef USE_ADC
|
||||
OSD_SETTING_ENTRY("VBAT SCALE", SETTING_VBAT_SCALE),
|
||||
OSD_SETTING_ENTRY("VBAT CLMAX", SETTING_VBAT_MAX_CELL_VOLTAGE),
|
||||
#endif
|
||||
OSD_SETTING_ENTRY("VBATCELL MAX", SETTING_VBAT_MAX_CELL_VOLTAGE),
|
||||
OSD_SETTING_ENTRY("VBATCELL WARN", SETTING_VBAT_WARNING_CELL_VOLTAGE),
|
||||
OSD_SETTING_ENTRY("VBATCELL MIN", SETTING_VBAT_MIN_CELL_VOLTAGE),
|
||||
OSD_SETTING_ENTRY("BAT CAP UNIT", SETTING_BATTERY_CAPACITY_UNIT),
|
||||
OSD_SETTING_ENTRY("BAT CAPACITY", SETTING_BATTERY_CAPACITY),
|
||||
OSD_SETTING_ENTRY("BAT CAP WARN", SETTING_BATTERY_CAPACITY_WARNING),
|
||||
OSD_SETTING_ENTRY("BAT CAP CRIT", SETTING_BATTERY_CAPACITY_CRITICAL),
|
||||
#ifdef USE_OSD
|
||||
OSD_SETTING_ENTRY("OSD VOLT DECIMALS", SETTING_OSD_MAIN_VOLTAGE_DECIMALS),
|
||||
OSD_SETTING_ENTRY("STATS ENERGY UNIT", SETTING_OSD_STATS_ENERGY_UNIT),
|
||||
#endif /* USE_OSD */
|
||||
#endif /* USE_ADC */
|
||||
|
||||
{ "RC PREV", OME_Submenu, cmsMenuChange, &cmsx_menuRcPreview, 0},
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue