fix(flysky): battery charging animation and other timing issues (#5471)

This commit is contained in:
richardclli
2024-08-23 11:27:24 +10:00
committed by GitHub
parent e0ec49d84e
commit 2ef014db0f
8 changed files with 18 additions and 18 deletions
+2 -2
View File
@@ -130,7 +130,7 @@ void boardInit()
} else if (isChargerActive()) {
while (true) {
pwrOn();
uint32_t now = get_tmr10ms();
uint32_t now = timersGetMsTick();
if (pwrPressed()) {
press_end = now;
if (press_start == 0) press_start = now;
@@ -143,7 +143,7 @@ void boardInit()
uint32_t press_end_touch = press_end;
if (touchPanelEventOccured()) {
touchPanelRead();
press_end_touch = get_tmr10ms();
press_end_touch = timersGetMsTick();
}
press_start = 0;
handle_battery_charge(press_end_touch);