From 0d734b753fb56fd6e381750b02df3ca6396f333d Mon Sep 17 00:00:00 2001 From: lwvmobile Date: Fri, 9 May 2025 21:11:23 -0400 Subject: [PATCH] Event History Setup: #287 Fix Flicker Bug in Ncurses Printer by casting lls as static int; Further Tweak to NcursesPrinter for responsiveness; --- src/dsd_frame_sync.c | 2 +- src/dsd_ncurses_printer.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/dsd_frame_sync.c b/src/dsd_frame_sync.c index 6d8acbd..c13e285 100644 --- a/src/dsd_frame_sync.c +++ b/src/dsd_frame_sync.c @@ -248,7 +248,7 @@ getFrameSync (dsd_opts * opts, dsd_state * state) //run ncurses printer more frequently when no sync to speed up responsiveness of it during no sync period //NOTE: Need to monitor and test this, if responsiveness issues arise, then disable this - if ( opts->use_ncurses_terminal == 1 && ((t % 600) == 0)) //t maxes out at 1800 (3 times each getFrameSync) + if ( opts->use_ncurses_terminal == 1 && ((t % 300) == 0)) //t maxes out at 1800 (6 times each getFrameSync) ncursesPrinter(opts, state); symbol = getSymbol (opts, state, 0); diff --git a/src/dsd_ncurses_printer.c b/src/dsd_ncurses_printer.c index 1d5a963..6a11cd3 100644 --- a/src/dsd_ncurses_printer.c +++ b/src/dsd_ncurses_printer.c @@ -103,14 +103,14 @@ void ncursesOpen (dsd_opts * opts, dsd_state * state) } +static int lls = -1; + void ncursesPrinter (dsd_opts * opts, dsd_state * state) { uint8_t idas = 0; int level = 0; int c = 0; - - int lls = -1; int i = 0; if (opts->audio_in_type != 1) //can't run getch/menu when using STDIN -