M17 mod: allow connection to Demod Analyzer

pull/1344/head
f4exb 2022-07-01 05:56:12 +02:00
rodzic ba36df3c01
commit 8bc1a204c5
3 zmienionych plików z 11 dodań i 9 usunięć

Wyświetl plik

@ -55,8 +55,8 @@ M17ModSource::M17ModSource() :
m_feedbackAudioBuffer.resize(1<<14);
m_feedbackAudioBufferFill = 0;
m_demodBuffer.resize(1<<12);
m_demodBufferFill = 0;
m_modBuffer.resize(1<<12);
m_modBufferFill = 0;
m_magsq = 0.0;
@ -193,10 +193,10 @@ void M17ModSource::modulateSample()
m_modSample.imag(0.0f);
}
m_demodBuffer[m_demodBufferFill] = t1 * std::numeric_limits<int16_t>::max();
++m_demodBufferFill;
m_modBuffer[m_modBufferFill] = t1 * std::numeric_limits<int16_t>::max();
++m_modBufferFill;
if (m_demodBufferFill >= m_demodBuffer.size())
if (m_modBufferFill >= m_modBuffer.size())
{
QList<ObjectPipe*> dataPipes;
MainCore::instance()->getDataPipes().getDataPipes(m_channel, "demod", dataPipes);
@ -210,12 +210,12 @@ void M17ModSource::modulateSample()
DataFifo *fifo = qobject_cast<DataFifo*>((*it)->m_element);
if (fifo) {
fifo->write((quint8*) &m_demodBuffer[0], m_demodBuffer.size() * sizeof(qint16), DataFifo::DataTypeI16);
fifo->write((quint8*) &m_modBuffer[0], m_modBuffer.size() * sizeof(qint16), DataFifo::DataTypeI16);
}
}
}
m_demodBufferFill = 0;
m_modBufferFill = 0;
}
}

Wyświetl plik

@ -93,8 +93,8 @@ private:
Real m_feedbackInterpolatorDistanceRemain;
bool m_feedbackInterpolatorConsumed;
QVector<qint16> m_demodBuffer;
int m_demodBufferFill;
QVector<qint16> m_modBuffer;
int m_modBufferFill;
Lowpass<Real> m_lowpass;

Wyświetl plik

@ -31,6 +31,7 @@ const QStringList DemodAnalyzerSettings::m_channelTypes = {
QStringLiteral("DABDemod"),
QStringLiteral("DSDDemod"),
QStringLiteral("M17Demod"),
QStringLiteral("M17Mmod"),
QStringLiteral("NFMDemod"),
QStringLiteral("NFMMod"),
QStringLiteral("PacketDemod"),
@ -51,6 +52,7 @@ const QStringList DemodAnalyzerSettings::m_channelURIs = {
QStringLiteral("sdrangel.channel.dabdemod"),
QStringLiteral("sdrangel.channel.dsddemod"),
QStringLiteral("sdrangel.channel.m17demod"),
QStringLiteral("sdrangel.channeltx.modm17"),
QStringLiteral("sdrangel.channel.nfmdemod"),
QStringLiteral("sdrangel.channeltx.modnfm"),
QStringLiteral("sdrangel.channel.packetdemod"),