set now in main at the top

This commit is contained in:
smayzy 2026-05-10 19:25:58 +02:00
parent 85075c1efb
commit d65f4a3baa

View File

@ -704,6 +704,7 @@ int main(int argc, char **argv) {
bat_state.previous_ms = now;
while(1) {
now = now_ms();
ch = tolower(getch());
switch (ch) {
case 'q' :
@ -719,8 +720,9 @@ int main(int argc, char **argv) {
}
break;
}
if (!is_receiver) calc_data(&tel, &bat_state, now);
now = now_ms();
if (now - t100 >= 100 * delay) {
win_int(&tel.speed, use_color);
win_int(&tel.rpm, use_color);