sistemato il loging ed aggiunto il rate di ricezione dati da server e rate aggiornamento ppi display
This commit is contained in:
parent
e286edc182
commit
fc1722d8eb
@ -135,15 +135,15 @@ class SimulationStateHub:
|
||||
# monotonic time to avoid issues with system clock changes.
|
||||
if now is not None and (now - self._last_real_summary_time) >= self._real_summary_interval_s:
|
||||
rate = self.get_real_rate(window_seconds=self._real_summary_interval_s)
|
||||
try:
|
||||
logger.info(
|
||||
"[SimulationStateHub] real states: recent_rate=%.1f ev/s total_targets=%d",
|
||||
rate,
|
||||
len(self._target_data),
|
||||
)
|
||||
except Exception:
|
||||
# never allow logging to raise
|
||||
pass
|
||||
#try:
|
||||
# logger.info(
|
||||
# "[SimulationStateHub] real states: recent_rate=%.1f ev/s total_targets=%d",
|
||||
# rate,
|
||||
# len(self._target_data),
|
||||
# )
|
||||
#except Exception:
|
||||
# # never allow logging to raise
|
||||
# pass
|
||||
self._last_real_summary_time = now
|
||||
except Exception:
|
||||
# Never allow diagnostic/logging instrumentation to break hub behavior
|
||||
|
||||
@ -212,10 +212,10 @@ class PPIDisplay(ttk.Frame):
|
||||
else:
|
||||
break
|
||||
rate = cnt / float(self._update_summary_interval_s) if self._update_summary_interval_s > 0 else float(cnt)
|
||||
try:
|
||||
logger.info("[PPIDisplay] update_real_targets: recent_rate=%.1f updates/s display_targets=%d", rate, len(targets))
|
||||
except Exception:
|
||||
pass
|
||||
#try:
|
||||
# logger.info("[PPIDisplay] update_real_targets: recent_rate=%.1f updates/s display_targets=%d", rate, len(targets))
|
||||
#except Exception:
|
||||
# pass
|
||||
self._last_update_summary_time = now
|
||||
except Exception:
|
||||
pass
|
||||
|
||||
Loading…
Reference in New Issue
Block a user