Fix for clock drift between radio and duplex HS

This commit is contained in:
Andy CA6JAU 2018-08-19 21:20:43 -03:00
parent 0f1bc29114
commit 06d8efa446
2 changed files with 11 additions and 5 deletions

View file

@ -255,14 +255,20 @@ void CDMRTX::createData(uint8_t slotIndex)
if (m_fifo[slotIndex].getData() > 0U && m_frameCount >= STARTUP_COUNT) {
for (unsigned int i = 0U; i < DMR_FRAME_LENGTH_BYTES; i++) {
m_poBuffer[i] = m_fifo[slotIndex].get();
m_markBuffer[i] = MARK_NONE;
if (i == 8U)
m_markBuffer[i] = slotIndex == 0U ? MARK_SLOT1 : MARK_SLOT2;
else
m_markBuffer[i] = MARK_NONE;
}
} else {
m_abort[slotIndex] = false;
// Transmit an idle message
for (unsigned int i = 0U; i < DMR_FRAME_LENGTH_BYTES; i++) {
m_poBuffer[i] = m_idle[i];
m_markBuffer[i] = MARK_NONE;
if (i == 8U)
m_markBuffer[i] = slotIndex == 0U ? MARK_SLOT1 : MARK_SLOT2;
else
m_markBuffer[i] = MARK_NONE;
}
}
@ -287,7 +293,7 @@ void CDMRTX::createCACH(uint8_t txSlotIndex, uint8_t rxSlotIndex)
::memcpy(m_poBuffer, m_shortLC + m_cachPtr, 3U);
m_markBuffer[0U] = MARK_NONE;
m_markBuffer[1U] = MARK_NONE;
m_markBuffer[2U] = rxSlotIndex == 1U ? MARK_SLOT1 : MARK_SLOT2;
m_markBuffer[2U] = MARK_NONE;
bool at = false;
if (m_frameCount >= STARTUP_COUNT)

View file

@ -107,7 +107,7 @@ and wait to complete the upgrading process.
You could use example files from MMDVM_HS/configs folder and overwrite the Config.h file, in order to compile a firmware with default settings. There are a specific config file for each ZUMspot or any MMDVM_HS compatible boards. In general, there are two possible compilation ways:
- Board with USB interface
- Boards with USB interface:
Boards with STM32_USB_HOST option enabled in Config.h (ZUMspot Libre Kit, ZUMspot USB, GIBSpot USB, NanoDV USB, etc). Those boards need to have the USB bootloader installed. For example:
@ -115,7 +115,7 @@ Boards with STM32_USB_HOST option enabled in Config.h (ZUMspot Libre Kit, ZUMspo
make bl
make dfu
- Board with GPIO interface
- Boards with GPIO interface:
Boards with STM32_USART1_HOST option enabled in Config.h (ZUMspot RPi, MMDVM_HS_Hat, MMDVM_HS_Dual_Hat, Nano hotSPOT, etc). No USB bootloader needed. For example: