mirror of
https://github.com/g4klx/MMDVMHost
synced 2025-12-23 00:35:53 +08:00
Reset lastFrameValid when used up.
This commit is contained in:
@@ -1562,8 +1562,10 @@ void CDMRSlot::insertSilence(unsigned int count)
|
|||||||
for (unsigned int i = 0U; i < count; i++) {
|
for (unsigned int i = 0U; i < count; i++) {
|
||||||
// Only use our silence frame if its AMBE audio data
|
// Only use our silence frame if its AMBE audio data
|
||||||
if (fid == FID_ETSI || fid == FID_DMRA) {
|
if (fid == FID_ETSI || fid == FID_DMRA) {
|
||||||
if (i > 0U)
|
if (i > 0U) {
|
||||||
::memcpy(data, DMR_SILENCE_DATA, DMR_FRAME_LENGTH_BYTES + 2U);
|
::memcpy(data, DMR_SILENCE_DATA, DMR_FRAME_LENGTH_BYTES + 2U);
|
||||||
|
m_lastFrameValid = false;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (n == 0U) {
|
if (n == 0U) {
|
||||||
|
|||||||
@@ -848,6 +848,8 @@ void CDStarControl::insertSilence(unsigned int count)
|
|||||||
writeQueueDataNet(m_lastFrame);
|
writeQueueDataNet(m_lastFrame);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
m_lastFrameValid = false;
|
||||||
|
|
||||||
if (n == 0U)
|
if (n == 0U)
|
||||||
writeQueueDataNet(DSTAR_NULL_FRAME_SYNC_BYTES);
|
writeQueueDataNet(DSTAR_NULL_FRAME_SYNC_BYTES);
|
||||||
else
|
else
|
||||||
|
|||||||
Reference in New Issue
Block a user