From 5e4e37f8e5744ed546e89afd151eef164941be09 Mon Sep 17 00:00:00 2001 From: Luca Marchesano Date: Sat, 30 Jun 2018 14:10:41 +0200 Subject: [PATCH] Fixed modem startup problem --- Config.h | 2 +- IO.cpp | 12 ++---------- MMDVM_STM32F4xx.coproj | 8 ++++---- SerialPort.cpp | 2 +- YSFTX.cpp | 3 +-- 5 files changed, 9 insertions(+), 18 deletions(-) diff --git a/Config.h b/Config.h index 4691432..9fe0fdc 100644 --- a/Config.h +++ b/Config.h @@ -67,7 +67,7 @@ // #define SERIAL_REPEATER // To reduce CPU load, you can remove the DC blocker by commenting out the next line -#define USE_DCBLOCKER +// #define USE_DCBLOCKER // Constant Service LED once repeater is running // Do not use if employing an external hardware watchdog diff --git a/IO.cpp b/IO.cpp index 0e71dd6..90fe534 100644 --- a/IO.cpp +++ b/IO.cpp @@ -460,18 +460,10 @@ void CIO::process() } } else if (m_modemState == STATE_DSTARCAL) { q15_t GMSKVals[RX_BLOCK_SIZE]; -#if defined(USE_DCBLOCKER) - #if !defined (DSTARBOXCAR) - ::arm_fir_fast_q15(&m_gaussianFilter, dcSamples, GMSKVals, RX_BLOCK_SIZE); - #else - ::arm_fir_fast_q15(&m_boxcarFilter, dcSamples, GMSKVals, RX_BLOCK_SIZE); - #endif -#else - #if !defined (DSTARBOXCAR) +#if !defined (DSTARBOXCAR) ::arm_fir_fast_q15(&m_gaussianFilter, samples, GMSKVals, RX_BLOCK_SIZE); - #else +#else ::arm_fir_fast_q15(&m_boxcarFilter, samples, GMSKVals, RX_BLOCK_SIZE); - #endif #endif calDStarRX.samples(GMSKVals, RX_BLOCK_SIZE); } else if (m_modemState == STATE_RSSICAL) { diff --git a/MMDVM_STM32F4xx.coproj b/MMDVM_STM32F4xx.coproj index 2eaffbd..d3d976c 100644 --- a/MMDVM_STM32F4xx.coproj +++ b/MMDVM_STM32F4xx.coproj @@ -275,8 +275,8 @@ - + @@ -284,15 +284,15 @@ - + - + @@ -340,8 +340,8 @@ - + diff --git a/SerialPort.cpp b/SerialPort.cpp index a47cd4b..6f2a31d 100644 --- a/SerialPort.cpp +++ b/SerialPort.cpp @@ -88,7 +88,7 @@ const uint8_t MMDVM_DEBUG5 = 0xF5U; #define TCXO "NO TCXO" #endif -#define DESCRIPTION "MMDVM 20180615 48Khz(D-Star/DMR/System Fusion/P25/NXDN)" +#define DESCRIPTION "MMDVM 20180630 (D-Star/DMR/System Fusion/P25/NXDN)" #if defined(GITVERSION) #define concat(a, b, c) a " " b " GitID #" c "" diff --git a/YSFTX.cpp b/YSFTX.cpp index bfd5462..e358c99 100644 --- a/YSFTX.cpp +++ b/YSFTX.cpp @@ -69,7 +69,6 @@ m_txCount(0U) m_modFilter.pState = m_modState; } - void CYSFTX::process() { if (m_buffer.getData() == 0U && m_poLen == 0U && m_txCount == 0U) @@ -93,7 +92,7 @@ void CYSFTX::process() if (m_poLen > 0U) { // Transmit YSF data. uint16_t space = io.getSpace(); - + while (space > (4U * YSF_RADIO_SYMBOL_LENGTH)) { uint8_t c = m_poBuffer[m_poPtr++]; writeByte(c);