From 22c7e564f09a86a3777aa88b4ab3ad25ddfe0216 Mon Sep 17 00:00:00 2001 From: 3djc Date: Mon, 22 Apr 2024 00:49:27 +0200 Subject: [PATCH] chore(color): display mixer period in statistic screen (#4901) --- radio/src/gui/colorlcd/view_statistics.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/radio/src/gui/colorlcd/view_statistics.cpp b/radio/src/gui/colorlcd/view_statistics.cpp index 3758f31fd..afc545f5b 100644 --- a/radio/src/gui/colorlcd/view_statistics.cpp +++ b/radio/src/gui/colorlcd/view_statistics.cpp @@ -24,6 +24,7 @@ #include "opentx.h" #include "tasks.h" #include "tasks/mixer_task.h" +#include "mixer_scheduler.h" class StatisticsViewPage : public PageTab { @@ -264,11 +265,16 @@ void DebugViewPage::build(Window* window) // Mixer data static std::string pad_STR_MS = " " + std::string(STR_MS); + static std::string pad_STR_PERIOD = std::string(STR_PERIOD) + ": "; new StaticText(line, rect_t{}, STR_TMIXMAXMS); new DynamicNumber( line, rect_t{}, [] { return DURATION_MS_PREC2(maxMixerDuration); }, PREC2 | COLOR_THEME_PRIMARY1, nullptr, pad_STR_MS.c_str()); + new DynamicNumber( + line, rect_t{}, [] { return getMixerSchedulerPeriod() / 1000; }, + COLOR_THEME_PRIMARY1, pad_STR_PERIOD.c_str(), pad_STR_MS.c_str()); + line = window->newLine(grid); line->padAll(PAD_TINY);