mirror of
https://github.com/f4exb/sdrangel.git
synced 2024-11-24 17:08:36 -05:00
Compare commits
No commits in common. "4da9a34c873c143cc1f845ebc478b1734e08dd6f" and "0a94970a7065c43c07e1688c58f3f0a64e4a042d" have entirely different histories.
4da9a34c87
...
0a94970a70
2
.github/workflows/windows.yml
vendored
2
.github/workflows/windows.yml
vendored
@ -99,7 +99,7 @@ jobs:
|
||||
api-token: '${{ secrets.SIGNPATH_API_TOKEN }}'
|
||||
organization-id: '553b8f53-adf0-4fe5-be3d-283504a21a51'
|
||||
project-slug: 'sdrangel'
|
||||
signing-policy-slug: 'release-signing'
|
||||
signing-policy-slug: 'test-signing'
|
||||
github-artifact-id: '${{ steps.upload-unsigned-artifact.outputs.artifact-id }}'
|
||||
wait-for-completion: true
|
||||
output-artifact-directory: '${{ github.workspace }}\build\signed'
|
||||
|
@ -79,7 +79,6 @@ FreeDVDemod::FreeDVDemod(DeviceAPI *deviceAPI) :
|
||||
|
||||
FreeDVDemod::~FreeDVDemod()
|
||||
{
|
||||
stop();
|
||||
QObject::disconnect(
|
||||
m_networkManager,
|
||||
&QNetworkAccessManager::finished,
|
||||
|
@ -176,8 +176,6 @@ FreeDVDemodSink::~FreeDVDemodSink()
|
||||
{
|
||||
delete SSBFilter;
|
||||
delete[] m_SSBFilterBuffer;
|
||||
delete[] m_speechOut;
|
||||
delete[] m_modIn;
|
||||
}
|
||||
|
||||
void FreeDVDemodSink::feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end)
|
||||
@ -451,7 +449,7 @@ void FreeDVDemodSink::applyFreeDVMode(FreeDVDemodSettings::FreeDVMode mode)
|
||||
freedv_set_ext_vco(m_freeDV, 0);
|
||||
freedv_set_sync(m_freeDV, FREEDV_SYNC_MANUAL);
|
||||
|
||||
int nSpeechSamples = freedv_get_n_max_speech_samples(m_freeDV);
|
||||
int nSpeechSamples = freedv_get_n_speech_samples(m_freeDV);
|
||||
int nMaxModemSamples = freedv_get_n_max_modem_samples(m_freeDV);
|
||||
int Fs = freedv_get_modem_sample_rate(m_freeDV);
|
||||
int Rs = freedv_get_modem_symbol_rate(m_freeDV);
|
||||
|
@ -187,41 +187,39 @@ void DSPEngine::removeLastDeviceMIMOEngine()
|
||||
}
|
||||
}
|
||||
|
||||
QThread *DSPEngine::getDeviceEngineThread(int deviceIndex)
|
||||
QThread * DSPEngine::removeDeviceEngineAt(int deviceIndex)
|
||||
{
|
||||
if (deviceIndex >= m_deviceEngineReferences.size()) {
|
||||
return nullptr;
|
||||
} else {
|
||||
return m_deviceEngineReferences[deviceIndex].m_thread;
|
||||
}
|
||||
}
|
||||
|
||||
void DSPEngine::removeDeviceEngineAt(int deviceIndex)
|
||||
{
|
||||
if (deviceIndex >= m_deviceEngineReferences.size()) {
|
||||
return;
|
||||
}
|
||||
QThread *deviceThread = nullptr;
|
||||
|
||||
if (m_deviceEngineReferences[deviceIndex].m_deviceEngineType == 0) // source
|
||||
{
|
||||
DSPDeviceSourceEngine *deviceEngine = m_deviceEngineReferences[deviceIndex].m_deviceSourceEngine;
|
||||
m_deviceEngineReferences[deviceIndex].m_thread->exit();
|
||||
deviceThread = m_deviceEngineReferences[deviceIndex].m_thread;
|
||||
deviceThread->exit();
|
||||
m_deviceSourceEngines.removeAll(deviceEngine);
|
||||
}
|
||||
else if (m_deviceEngineReferences[deviceIndex].m_deviceEngineType == 1) // sink
|
||||
{
|
||||
DSPDeviceSinkEngine *deviceEngine = m_deviceEngineReferences[deviceIndex].m_deviceSinkEngine;
|
||||
m_deviceEngineReferences[deviceIndex].m_thread->exit();
|
||||
deviceThread = m_deviceEngineReferences[deviceIndex].m_thread;
|
||||
deviceThread->exit();
|
||||
m_deviceSinkEngines.removeAll(deviceEngine);
|
||||
}
|
||||
else if (m_deviceEngineReferences[deviceIndex].m_deviceEngineType == 2) // MIMO
|
||||
{
|
||||
DSPDeviceMIMOEngine *deviceEngine = m_deviceEngineReferences[deviceIndex].m_deviceMIMOEngine;
|
||||
m_deviceEngineReferences[deviceIndex].m_thread->exit();
|
||||
deviceThread = m_deviceEngineReferences[deviceIndex].m_thread;
|
||||
deviceThread->exit();
|
||||
m_deviceMIMOEngines.removeAll(deviceEngine);
|
||||
}
|
||||
|
||||
m_deviceEngineReferences.removeAt(deviceIndex);
|
||||
|
||||
return deviceThread;
|
||||
}
|
||||
|
||||
void DSPEngine::createFFTFactory(const QString& fftWisdomFileName)
|
||||
|
@ -53,8 +53,7 @@ public:
|
||||
DSPDeviceMIMOEngine *addDeviceMIMOEngine();
|
||||
void removeLastDeviceMIMOEngine();
|
||||
|
||||
QThread *getDeviceEngineThread(int deviceIndex);
|
||||
void removeDeviceEngineAt(int deviceIndex);
|
||||
QThread *removeDeviceEngineAt(int deviceIndex);
|
||||
|
||||
AudioDeviceManager *getAudioDeviceManager() { return &m_audioDeviceManager; }
|
||||
|
||||
|
@ -778,19 +778,10 @@ void RemoveDeviceSetFSM::removeUI()
|
||||
void RemoveDeviceSetFSM::stopEngine()
|
||||
{
|
||||
qDebug() << "RemoveDeviceSetFSM::stopEngine";
|
||||
QThread *thread = m_mainWindow->m_dspEngine->getDeviceEngineThread(m_deviceSetIndex);
|
||||
|
||||
if (thread)
|
||||
QThread *thread = m_mainWindow->m_dspEngine->removeDeviceEngineAt(m_deviceSetIndex);
|
||||
if (thread && !thread->isFinished()) // FIXME: Is there a race condition here? We might need to connect before calling thread->exit
|
||||
{
|
||||
bool finished = thread->isFinished();
|
||||
|
||||
if (!finished) {
|
||||
connect(thread, &QThread::finished, m_mainWindow, &MainWindow::engineStopped);
|
||||
}
|
||||
m_mainWindow->m_dspEngine->removeDeviceEngineAt(m_deviceSetIndex);
|
||||
if (finished) {
|
||||
emit m_mainWindow->engineStopped();
|
||||
}
|
||||
connect(thread, &QThread::finished, m_mainWindow, &MainWindow::engineStopped);
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -810,20 +801,12 @@ void RemoveDeviceSetFSM::removeDeviceSet()
|
||||
|
||||
DeviceAPI *deviceAPI = m_deviceUISet->m_deviceAPI;
|
||||
delete m_deviceUISet;
|
||||
if (m_deviceSourceEngine)
|
||||
{
|
||||
if (m_deviceSourceEngine) {
|
||||
delete deviceAPI->getSampleSource();
|
||||
delete m_deviceSourceEngine;
|
||||
}
|
||||
else if (m_deviceSinkEngine)
|
||||
{
|
||||
} else if (m_deviceSinkEngine) {
|
||||
delete deviceAPI->getSampleSink();
|
||||
delete m_deviceSinkEngine;
|
||||
}
|
||||
else
|
||||
{
|
||||
} else {
|
||||
delete deviceAPI->getSampleMIMO();
|
||||
delete m_deviceMIMOEngine;
|
||||
}
|
||||
delete deviceAPI;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user