mirror of https://github.com/g4klx/MMDVM.git
Merge pull request #228 from m0vse/FM
Fix for Ack/Callsign corruption in FM branch
This commit is contained in:
commit
394ab8dfd1
|
@ -102,6 +102,9 @@ uint8_t CFMCTCSSTX::setParams(uint8_t frequency, uint8_t level)
|
|||
|
||||
m_length = entry->length;
|
||||
|
||||
if (m_values)
|
||||
delete[] m_values;
|
||||
|
||||
m_values = new q15_t[m_length];
|
||||
|
||||
q15_t arg = 0;
|
||||
|
|
|
@ -92,6 +92,7 @@ m_lowLevel(0)
|
|||
|
||||
uint8_t CFMKeyer::setParams(const char* text, uint8_t speed, uint16_t frequency, uint8_t highLevel, uint8_t lowLevel)
|
||||
{
|
||||
m_poLen=0;
|
||||
for (uint8_t i = 0U; text[i] != '\0'; i++) {
|
||||
for (uint8_t j = 0U; SYMBOL_LIST[j].c != 0U; j++) {
|
||||
if (SYMBOL_LIST[j].c == text[i]) {
|
||||
|
@ -118,6 +119,9 @@ uint8_t CFMKeyer::setParams(const char* text, uint8_t speed, uint16_t frequency,
|
|||
|
||||
m_audioLen = 24000U / frequency; // In samples
|
||||
|
||||
if (m_audio)
|
||||
delete[] m_audio;
|
||||
|
||||
m_audio = new bool[m_audioLen];
|
||||
|
||||
for (uint16_t i = 0U; i < m_audioLen; i++) {
|
||||
|
|
Loading…
Reference in New Issue