|
|
|
@ -52,7 +52,7 @@ void CController::Stop()
|
|
|
|
|
|
|
|
|
|
|
|
reader.Close();
|
|
|
|
reader.Close();
|
|
|
|
dstar_device.CloseDevice();
|
|
|
|
dstar_device.CloseDevice();
|
|
|
|
dmrsf_device.CloseDevice();
|
|
|
|
dmr_device.CloseDevice();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
bool CController::CheckTCModules() const
|
|
|
|
bool CController::CheckTCModules() const
|
|
|
|
@ -157,13 +157,13 @@ bool CController::InitDevices()
|
|
|
|
{
|
|
|
|
{
|
|
|
|
dstar_device.OpenDevice(deviceset.front().first, deviceset.front().second, 921600);
|
|
|
|
dstar_device.OpenDevice(deviceset.front().first, deviceset.front().second, 921600);
|
|
|
|
deviceset.pop_front();
|
|
|
|
deviceset.pop_front();
|
|
|
|
dmrsf_device.OpenDevice(deviceset.front().first, deviceset.front().second, 921600);
|
|
|
|
dmr_device.OpenDevice(deviceset.front().first, deviceset.front().second, 921600);
|
|
|
|
deviceset.pop_front();
|
|
|
|
deviceset.pop_front();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// and start them up!
|
|
|
|
// and start them up!
|
|
|
|
dstar_device.Start();
|
|
|
|
dstar_device.Start();
|
|
|
|
dmrsf_device.Start();
|
|
|
|
dmr_device.Start();
|
|
|
|
|
|
|
|
|
|
|
|
deviceset.clear();
|
|
|
|
deviceset.clear();
|
|
|
|
|
|
|
|
|
|
|
|
@ -190,7 +190,7 @@ void CController::ReadReflectorThread()
|
|
|
|
dstar_device.AddPacket(packet);
|
|
|
|
dstar_device.AddPacket(packet);
|
|
|
|
break;
|
|
|
|
break;
|
|
|
|
case ECodecType::dmr:
|
|
|
|
case ECodecType::dmr:
|
|
|
|
dmrsf_device.AddPacket(packet);
|
|
|
|
dmr_device.AddPacket(packet);
|
|
|
|
break;
|
|
|
|
break;
|
|
|
|
case ECodecType::c2_1600:
|
|
|
|
case ECodecType::c2_1600:
|
|
|
|
case ECodecType::c2_3200:
|
|
|
|
case ECodecType::c2_3200:
|
|
|
|
@ -284,7 +284,7 @@ void CController::Codec2toAudio(std::shared_ptr<CTranscoderPacket> packet)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
// the only thing left is to encode the two ambe, so push the packet onto both AMBE queues
|
|
|
|
// the only thing left is to encode the two ambe, so push the packet onto both AMBE queues
|
|
|
|
dstar_device.AddPacket(packet);
|
|
|
|
dstar_device.AddPacket(packet);
|
|
|
|
dmrsf_device.AddPacket(packet);
|
|
|
|
dmr_device.AddPacket(packet);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
void CController::ProcessC2Thread()
|
|
|
|
void CController::ProcessC2Thread()
|
|
|
|
@ -329,7 +329,7 @@ void CController::RouteDstPacket(std::shared_ptr<CTranscoderPacket> packet)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
// codec_in is dstar, the audio has just completed, so now calc the M17 and DMR
|
|
|
|
// codec_in is dstar, the audio has just completed, so now calc the M17 and DMR
|
|
|
|
codec2_queue.push(packet);
|
|
|
|
codec2_queue.push(packet);
|
|
|
|
dmrsf_device.AddPacket(packet);
|
|
|
|
dmr_device.AddPacket(packet);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
else if (packet->AllCodecsAreSet())
|
|
|
|
else if (packet->AllCodecsAreSet())
|
|
|
|
{
|
|
|
|
{
|
|
|
|
|