Skip to content

Commit

Permalink
Fix for STM32F105 startup hang
Browse files Browse the repository at this point in the history
  • Loading branch information
juribeparada committed Aug 6, 2018
1 parent c2e785c commit f8ab4fe
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 3 deletions.
6 changes: 6 additions & 0 deletions Globals.h
Expand Up @@ -97,6 +97,12 @@ const uint16_t RX_BLOCK_SIZE = 2U;
const uint16_t TX_RINGBUFFER_SIZE = 500U;
const uint16_t RX_RINGBUFFER_SIZE = 600U;

#if defined(STM32F105xC)
const uint16_t TX_BUFFER_LEN = 2000U;
#else
const uint16_t TX_BUFFER_LEN = 4000U;
#endif

extern MMDVM_STATE m_modemState;

extern bool m_dstarEnable;
Expand Down
2 changes: 1 addition & 1 deletion NXDNTX.cpp
Expand Up @@ -45,7 +45,7 @@ const uint8_t NXDN_PREAMBLE[] = {0x57U, 0x75U, 0xFDU};
const uint8_t NXDN_SYNC = 0x5FU;

CNXDNTX::CNXDNTX() :
m_buffer(4000U),
m_buffer(TX_BUFFER_LEN),
m_modFilter(),
m_sincFilter(),
m_modState(),
Expand Down
2 changes: 1 addition & 1 deletion P25TX.cpp
Expand Up @@ -43,7 +43,7 @@ const q15_t P25_LEVELD = -1260;
const uint8_t P25_START_SYNC = 0x77U;

CP25TX::CP25TX() :
m_buffer(4000U),
m_buffer(TX_BUFFER_LEN),
m_modFilter(),
m_lpFilter(),
m_modState(),
Expand Down
4 changes: 4 additions & 0 deletions SerialRB.h
Expand Up @@ -32,7 +32,11 @@ Boston, MA 02110-1301, USA.
#include <Arduino.h>
#endif

#if defined(STM32F105xC)
const uint16_t SERIAL_RINGBUFFER_SIZE = 370U;
#else
const uint16_t SERIAL_RINGBUFFER_SIZE = 1000U;
#endif

class CSerialRB {
public:
Expand Down
2 changes: 1 addition & 1 deletion YSFTX.cpp
Expand Up @@ -44,7 +44,7 @@ const uint8_t YSF_END_SYNC = 0xFFU;
const uint8_t YSF_HANG = 0x00U;

CYSFTX::CYSFTX() :
m_buffer(4000U),
m_buffer(TX_BUFFER_LEN),
m_modFilter(),
m_modState(),
m_poBuffer(),
Expand Down

0 comments on commit f8ab4fe

Please sign in to comment.