Commit 290fc745 authored by Alessandro Rubini's avatar Alessandro Rubini

gui and stat: trivial: run immediately after command, not 1s later

Signed-off-by: Alessandro Rubini's avatarAlessandro Rubini <rubini@gnudd.com>
parent 3bc3b28a
......@@ -88,7 +88,7 @@ void wrc_mon_gui(void)
int64_t crtt;
int64_t total_asymmetry;
if (!last)
last = timer_get_tics();
last = timer_get_tics() - 1 - wrc_ui_refperiod;
if (time_before(timer_get_tics(), last + wrc_ui_refperiod))
return;
......@@ -276,7 +276,7 @@ int wrc_log_stats(void)
uint32_t nsec;
if (!last)
last = timer_get_tics();
last = timer_get_tics() - 1 - wrc_ui_refperiod;
if (time_before(timer_get_tics(), wrc_ui_refperiod + last))
return 0;
struct wr_servo_state *s =
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment