mirror of
https://github.com/g4klx/MMDVM.git
synced 2026-10-23 02:55:01 +02:00
Perform FM mode changing in a more conventional manner.
This commit is contained in:
@@ -70,6 +70,7 @@ const uint8_t MMDVM_FM_PARAMS2 = 0x61U;
|
||||
const uint8_t MMDVM_FM_PARAMS3 = 0x62U;
|
||||
const uint8_t MMDVM_FM_PARAMS4 = 0x63U;
|
||||
const uint8_t MMDVM_FM_DATA = 0x65U;
|
||||
const uint8_t MMDVM_FM_STATUS = 0x66U;
|
||||
|
||||
const uint8_t MMDVM_ACK = 0x70U;
|
||||
const uint8_t MMDVM_NAK = 0x7FU;
|
||||
@@ -1261,6 +1262,23 @@ void CSerialPort::writeFMData(const uint8_t* data, uint8_t length)
|
||||
writeInt(1U, reply, count);
|
||||
}
|
||||
|
||||
void CSerialPort::writeFMStatus()
|
||||
{
|
||||
if (m_modemState != STATE_FM && m_modemState != STATE_IDLE)
|
||||
return;
|
||||
|
||||
if (!m_fmEnable)
|
||||
return;
|
||||
|
||||
uint8_t reply[10U];
|
||||
|
||||
reply[0U] = MMDVM_FRAME_START;
|
||||
reply[1U] = 3U;
|
||||
reply[2U] = MMDVM_FM_STATUS;
|
||||
|
||||
writeInt(1U, reply, 3);
|
||||
}
|
||||
|
||||
void CSerialPort::writeCalData(const uint8_t* data, uint8_t length)
|
||||
{
|
||||
if (m_modemState != STATE_DSTARCAL)
|
||||
|
||||
Reference in New Issue
Block a user