atc1441 / ATC_MiThermometer

Custom firmware for the Xiaomi Thermometer LYWSD03MMC and Telink Flasher via USB to Serial converter
2.82k stars 472 forks source link

Measure battery more seldom #43

Closed orrpan closed 3 years ago

orrpan commented 4 years ago

As I understand measuring the battery is the thing that drains it the most, is it possible to only do these measurements like once a day or at least once a hour?

atc1441 commented 4 years ago

Hey. that would be my plan to do but right now nothing can be more than 2-3 minutes apart because of the overflow Bug in the future there will be real working millis counter

tshcherban commented 4 years ago

As far as i can see from sources, currently battery is measured once per 5 minutes image @orrpan, have you tried to adjust Read battery delay? @atc1441 where the overflow bug is happening? Can you provide a bit more details?

TheNitek commented 4 years ago

Wouldn't it be possible to disable battery measurements completely? Personaly I don't care about the value, if the device is dead I'll just replace the battery, but I like the idea replacing the battery more seldom ;-)

atc1441 commented 4 years ago

Thats a good argument!

It can be simply disabled by removing the battery part in the app main loop