mirror of
https://github.com/f4exb/sdrangel.git
synced 2024-11-26 17:58:43 -05:00
DSD demod: fixes for Serial DV (1)
This commit is contained in:
parent
7e7d6d6481
commit
6771e5e86c
@ -31,6 +31,7 @@ public:
|
||||
void pushSample(short sample) { m_decoder.run(sample); }
|
||||
short *getAudio(int& nbSamples) { return m_decoder.getAudio(nbSamples); }
|
||||
void resetAudio() { m_decoder.resetAudio(); }
|
||||
void enableMbelib(bool enable) { m_decoder.enableMbelib(enable); }
|
||||
|
||||
bool mbeDVReady() const { return m_decoder.mbeDVReady(); }
|
||||
void resetMbeDV() { m_decoder.resetMbeDV(); }
|
||||
|
@ -100,6 +100,8 @@ void DSDDemod::feed(const SampleVector::const_iterator& begin, const SampleVecto
|
||||
m_settingsMutex.lock();
|
||||
m_scopeSampleBuffer.clear();
|
||||
|
||||
m_dsdDecoder.enableMbelib(!DSPEngine::instance()->hasDVSerialSupport()); // disable mbelib if DV serial support is present and activated else enable it
|
||||
|
||||
for (SampleVector::const_iterator it = begin; it != end; ++it)
|
||||
{
|
||||
Complex c(it->real(), it->imag());
|
||||
|
@ -84,6 +84,10 @@ void DVSerialWorker::handleInputMessages()
|
||||
// upsample6(m_dvAudioSamples, m_audioSamples, SerialDV::MBE_AUDIO_BLOCK_SIZE);
|
||||
// decodeMsg->getAudioFifo()->write((const quint8 *) m_audioSamples, SerialDV::MBE_AUDIO_BLOCK_SIZE * 6, 10);
|
||||
}
|
||||
else
|
||||
{
|
||||
qDebug("DVSerialWorker::handleInputMessages: MsgMbeDecode: decode failed");
|
||||
}
|
||||
}
|
||||
|
||||
delete message;
|
||||
@ -100,7 +104,7 @@ void DVSerialWorker::upsample6(short *in, int nbSamplesIn, AudioFifo *audioFifo)
|
||||
|
||||
for (int j = 1; j < 7; j++)
|
||||
{
|
||||
upsample = (qint16) ((cur*i + prev*(6-i)) / 6);
|
||||
upsample = (qint16) ((cur*j + prev*(6-j)) / 6);
|
||||
m_audioBuffer[m_audioBufferFill].l = upsample;
|
||||
m_audioBuffer[m_audioBufferFill].r = upsample;
|
||||
++m_audioBufferFill;
|
||||
|
Loading…
Reference in New Issue
Block a user