mirror of
https://github.com/g4klx/MMDVMHost
synced 2025-12-22 08:05:49 +08:00
Small additions to the System Fusion controller.
This commit is contained in:
@@ -21,6 +21,14 @@
|
|||||||
|
|
||||||
// #define DUMP_YSF
|
// #define DUMP_YSF
|
||||||
|
|
||||||
|
/*
|
||||||
|
* TODO:
|
||||||
|
* AMBE FEC reconstruction.
|
||||||
|
* FICH regeneration.
|
||||||
|
* Callsign extraction + late entry.
|
||||||
|
* Uplink and downlink callsign addition.
|
||||||
|
*/
|
||||||
|
|
||||||
CYSFControl::CYSFControl(const std::string& callsign, IDisplay* display, unsigned int timeout, bool duplex) :
|
CYSFControl::CYSFControl(const std::string& callsign, IDisplay* display, unsigned int timeout, bool duplex) :
|
||||||
m_display(display),
|
m_display(display),
|
||||||
m_duplex(duplex),
|
m_duplex(duplex),
|
||||||
@@ -60,6 +68,9 @@ bool CYSFControl::writeModem(unsigned char *data)
|
|||||||
m_display->writeFusion("XXXXXX");
|
m_display->writeFusion("XXXXXX");
|
||||||
m_state = RS_RELAYING_RF_AUDIO;
|
m_state = RS_RELAYING_RF_AUDIO;
|
||||||
LogMessage("YSF, received RF header");
|
LogMessage("YSF, received RF header");
|
||||||
|
#if defined(DUMP_YSF)
|
||||||
|
openFile();
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
if (m_state != RS_RELAYING_RF_AUDIO)
|
if (m_state != RS_RELAYING_RF_AUDIO)
|
||||||
@@ -76,6 +87,10 @@ bool CYSFControl::writeModem(unsigned char *data)
|
|||||||
writeQueue(data);
|
writeQueue(data);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if defined(DUMP_YSF)
|
||||||
|
writeFile(data + 2U);
|
||||||
|
#endif
|
||||||
|
|
||||||
LogMessage("YSF, received RF end of transmission, %.1f seconds", float(m_frames) / 10.0F);
|
LogMessage("YSF, received RF end of transmission, %.1f seconds", float(m_frames) / 10.0F);
|
||||||
|
|
||||||
writeEndOfTransmission();
|
writeEndOfTransmission();
|
||||||
@@ -91,6 +106,10 @@ bool CYSFControl::writeModem(unsigned char *data)
|
|||||||
data[1U] = 0x00U;
|
data[1U] = 0x00U;
|
||||||
writeQueue(data);
|
writeQueue(data);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if defined(DUMP_YSF)
|
||||||
|
writeFile(data + 2U);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
|
|||||||
Reference in New Issue
Block a user