You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
DEBUG |??:??:?? 1 SX126X_RXEN not defined, defaulting to RADIOLIB_NC
DEBUG |??:??:?? 1 SX126X_TXEN not defined, defaulting to RADIOLIB_NC
DEBUG |??:??:?? 1 Use MCU pin -1 as RXEN and pin -1 as TXEN to control RF switching
INFO |??:??:?? 1 Set RX gain to boosted mode; result: 0
E (3381) gpio: gpio_isr_handler_remove(482): GPIO isr service is not installed, call gpio_install_isr_service() first
INFO |??:??:?? 1 SX1262 init success
INFO |??:??:?? 1 Not using WIFI
DEBUG |??:??:?? 1 LoRA bitrate = 118.500000 bytes / sec
INFO |??:??:?? 1 PowerFSM init, USB power=1
DEBUG |??:??:?? 1 State: BOOT
DEBUG |??:??:?? 1 [Power] Battery: usbPower=0, isCharging=0, batMv=3100, batPct=0 <- Invalid first reading
DEBUG |??:??:?? 1 [Power] Low voltage counter: 1/10
INFO |??:??:?? 1 [RangeTest] Range Test Module - Disabled
INFO |??:??:?? 4 [PowerFSM] Loss of power in Powered
INFO |??:??:?? 5 [PowerFSM] Loss of power in Powered
DEBUG |??:??:?? 5 [PowerFSM] State: ON
INFO |??:??:?? 11 [EnvironmentTelemetry] Environment Telemetry: init
INFO |??:??:?? 11 [EnvironmentTelemetry] Init sensor: SHT31
[ 11659][W][Wire.cpp:301] begin(): Bus already started in Master Mode.
INFO |??:??:?? 11 [EnvironmentTelemetry] Opened SHT31 sensor on i2c bus
(...)
DEBUG |??:??:?? 21 [Power] Battery: usbPower=0, isCharging=0, batMv=3963, batPct=77 <- Correct second reading.
The text was updated successfully, but these errors were encountered:
dm5tt
changed the title
[Bug]: Battery voltage measurement always gets an invalid first reading after reset. Triggers "Low Battery" warning.
[Bug]: Battery voltage measurement always gets an invalid first reading after reset
Nov 7, 2024
Power::readPowerStatus is called on startup,
but AnalogBatteryLevel::getBattVoltage
skips the read because 5 seconds have not
elapsed since last_read_time_ms, which
is initialized to zero.
`batMv=3100` is reported because
AnalogBatteryLevel::last_read_value is
initialized as:
```
float last_read_value = (OCV[NUM_OCV_POINTS - 1] * NUM_CELLS);
```
Category
Other
Hardware
Other
Firmware Version
2.5.11 and master
Description
Hardware: HT-CT62 (ESP32C3)
Looks like the first reading coming from the ADC is always invalid and then triggering the first shot of the low voltage battery warning.
My variant.h configuration
Relevant log output
The text was updated successfully, but these errors were encountered: