From 7ca2015df43c47865e81e577689d2990bd5e3023 Mon Sep 17 00:00:00 2001 From: Nunu Date: Thu, 1 Feb 2024 10:03:03 +0100 Subject: [PATCH] fix #118 audio stops randomly --- app/messenger.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/messenger.c b/app/messenger.c index b17416c..c09acf1 100644 --- a/app/messenger.c +++ b/app/messenger.c @@ -624,9 +624,6 @@ uint8_t validate_char( uint8_t rchar ) { void MSG_StorePacket(const uint16_t interrupt_bits) { - // prevent listening to fsk data and squelch (kamilsss655) - AUDIO_AudioPathOff(); - //const uint16_t rx_sync_flags = BK4819_ReadRegister(BK4819_REG_0B); const bool rx_sync = (interrupt_bits & BK4819_REG_02_FSK_RX_SYNC) ? true : false; @@ -636,6 +633,9 @@ void MSG_StorePacket(const uint16_t interrupt_bits) { //UART_printf("\nMSG : S%i, F%i, E%i | %i", rx_sync, rx_fifo_almost_full, rx_finished, interrupt_bits); if (rx_sync) { + // prevent listening to fsk data and squelch (kamilsss655) + AUDIO_AudioPathOff(); + gFSKWriteIndex = 0; MSG_ClearPacketBuffer(); msgStatus = RECEIVING;