- battery calc now more efficent
- new battery values now every 0.5s
This commit is contained in:
@@ -88,13 +88,14 @@ class Battery : public Component {
|
||||
uint8_t batteryPercent = 0;
|
||||
uint8_t batteryLowPercent = 10;
|
||||
uint8_t bufferPos = 0;
|
||||
uint8_t calulationDelayMultiplier = 10;
|
||||
uint8_t calulationDelayMultiplier = 5;
|
||||
uint8_t loopCounter = 0;
|
||||
uint16_t adcBuffer[bufferSize];
|
||||
uint32_t r1 = 0;
|
||||
uint32_t r2 = 0;
|
||||
bool calculatetNewValues = false;
|
||||
double batteryVoltage = 0;
|
||||
double batteryVoltageFactor;
|
||||
|
||||
const float capacityVoltages[21] = {9.82, 10.83, 11.06, 11.12, // 0 5 10 15
|
||||
11.18, 11.24, 11.3, 11.36, // 20 25 30 35
|
||||
|
||||
Reference in New Issue
Block a user