From c6291156428e8cf7844e057ba30fab9410e13a36 Mon Sep 17 00:00:00 2001 From: David Rowe Date: Sun, 9 Aug 2020 13:06:53 +0930 Subject: [PATCH] flush output bits immediately to stop pause in BER reports --- src/rtl_fsk.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/rtl_fsk.c b/src/rtl_fsk.c index 01860cf..37ea103 100644 --- a/src/rtl_fsk.c +++ b/src/rtl_fsk.c @@ -174,7 +174,8 @@ static void rtlsdr_callback(unsigned char *buf, uint32_t len, void *ctx) fprintf(stderr, "Short write, bits lost, exiting!\n"); rtlsdr_cancel_async(dev); } - + if((FILE*)ctx == stdout) fflush((FILE*)ctx); + if (dashboard) { /* update buffer of timing samples */ if (norm_rx_timing_log_index < NORM_RX_TIMING_LOG_SZ)