1
0
mirror of https://github.com/f4exb/sdrangel.git synced 2026-06-02 22:14:45 -04:00

Multi device support: completely removed DSPEngine dependency on DSPDeviceEngine message queues

This commit is contained in:
f4exb
2016-05-12 23:45:27 +02:00
parent 7707858d57
commit f4c03bcab1
5 changed files with 10 additions and 12 deletions
@@ -18,12 +18,15 @@
#include <QDebug>
#include <QTimer>
#include <unistd.h>
#include "plugin/pluginapi.h"
#include "dsp/dspcommands.h"
#include "dsp/dspengine.h"
#include "sdrdaemonudphandler.h"
#include "sdrdaemoninput.h"
SDRdaemonUDPHandler::SDRdaemonUDPHandler(SampleFifo *sampleFifo, MessageQueue *outputMessageQueueToGUI) :
SDRdaemonUDPHandler::SDRdaemonUDPHandler(SampleFifo *sampleFifo, MessageQueue *outputMessageQueueToGUI, PluginAPI *pluginAPI) :
m_pluginAPI(pluginAPI),
m_sdrDaemonBuffer(m_rateDivider),
m_dataSocket(0),
m_dataAddress(QHostAddress::LocalHost),
@@ -88,7 +91,7 @@ void SDRdaemonUDPHandler::start()
// Need to notify the DSP engine to actually start
DSPSignalNotification *notif = new DSPSignalNotification(m_samplerate, m_centerFrequency * 1000); // Frequency in Hz for the DSP engine
DSPEngine::instance()->getInputMessageQueue()->push(notif);
m_pluginAPI->getDeviceInputMessageQueue()->push(notif);
m_elapsedTimer.start();
}
@@ -169,7 +172,7 @@ void SDRdaemonUDPHandler::processData()
if (change)
{
DSPSignalNotification *notif = new DSPSignalNotification(m_samplerate, m_centerFrequency * 1000); // Frequency in Hz for the DSP engine
DSPEngine::instance()->getInputMessageQueue()->push(notif);
m_pluginAPI->getDeviceInputMessageQueue()->push(notif);
SDRdaemonInput::MsgReportSDRdaemonStreamData *report = SDRdaemonInput::MsgReportSDRdaemonStreamData::create(
m_sdrDaemonBuffer.getSampleRateStream(),
m_samplerate,