From d67433962f4d250ac0d055d483a2611126254e76 Mon Sep 17 00:00:00 2001 From: DJ2LS <75909252+DJ2LS@users.noreply.github.com> Date: Sun, 29 Jan 2023 12:29:36 +0100 Subject: [PATCH] wait with command processing if IS_CODEC2_SIG_TRAFFIC --- tnc/data_handler.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/tnc/data_handler.py b/tnc/data_handler.py index f9220a90..8e932bae 100644 --- a/tnc/data_handler.py +++ b/tnc/data_handler.py @@ -237,12 +237,13 @@ class DATA: while True: data = self.data_queue_transmit.get() - # if we are already in ARQ_STATE lets wait with processing data + # if we are already in ARQ_STATE, or we're receiving codec2 traffic + # let's wait with processing data # this should avoid weird toggle states where both stations # stuck in IRS # # send transmission queued information once - if static.ARQ_STATE: + if static.ARQ_STATE or static.IS_CODEC2_SIG_TRAFFIC: self.log.debug(f"[TNC] TX DISPATCHER - waiting with processing command ", arq_state=static.ARQ_STATE) self.send_data_to_socket_queue( @@ -251,7 +252,7 @@ class DATA: status="queued", ) # now stay in while loop until state released - while static.ARQ_STATE: + while static.ARQ_STATE or static.IS_CODEC2_SIG_TRAFFIC: threading.Event().wait(0.01) # Dispatch commands known to command_dispatcher