SDRAngel
4.11.5
Developer docs for <a href="https://github.com/f4exb/sdrangel">SDRangel<\a>, an Open Source Qt5 / OpenGL 3.0+ SDR and signal analyzer frontend to various hardware.
|
#include <upchannelizer.h>
Classes | |
struct | FilterStage |
class | MsgChannelizerNotification |
class | MsgSetChannelizer |
Signals | |
void | outputSampleRateChanged () |
Public Member Functions | |
UpChannelizer (BasebandSampleSource *sampleSink) | |
virtual | ~UpChannelizer () |
void | configure (MessageQueue *messageQueue, int sampleRate, int centerFrequency) |
void | set (MessageQueue *messageQueue, unsigned int log2Interp, unsigned int filterChainHash) |
int | getOutputSampleRate () const |
virtual void | start () |
virtual void | stop () |
virtual void | pull (Sample &sample) |
virtual void | pullAudio (int nbSamples) |
virtual bool | handleMessage (const Message &cmd) |
Processing of a message. Returns true if message has actually been processed. More... | |
Public Member Functions inherited from BasebandSampleSource | |
BasebandSampleSource () | |
virtual | ~BasebandSampleSource () |
void | feed (SampleSourceFifo *sampleFifo, int nbSamples) |
SampleSourceFifo & | getSampleSourceFifo () |
MessageQueue * | getInputMessageQueue () |
Get the queue for asynchronous inbound communication. More... | |
virtual void | setMessageQueueToGUI (MessageQueue *queue) |
MessageQueue * | getMessageQueueToGUI () |
void | setDeviceSampleSourceFifo (SampleSourceFifo *deviceSampleFifo) |
Protected Types | |
typedef std::vector< FilterStage * > | FilterStages |
Protected Member Functions | |
void | applyConfiguration () |
void | applySetting (unsigned int log2Decim, unsigned int filterChainHash) |
bool | signalContainsChannel (Real sigStart, Real sigEnd, Real chanStart, Real chanEnd) const |
Real | createFilterChain (Real sigStart, Real sigEnd, Real chanStart, Real chanEnd) |
double | setFilterChain (const std::vector< unsigned int > &stageIndexes) |
returns offset in ratio of sample rate More... | |
void | freeFilterChain () |
Protected Member Functions inherited from BasebandSampleSource | |
void | handleWriteToFifo (SampleSourceFifo *sampleFifo, int nbSamples) |
Protected Attributes | |
FilterStages | m_filterStages |
bool | m_filterChainSetMode |
std::vector< Sample > | m_stageSamples |
BasebandSampleSource * | m_sampleSource |
Modulator. More... | |
int | m_outputSampleRate |
int | m_requestedInputSampleRate |
int | m_requestedCenterFrequency |
int | m_currentInputSampleRate |
int | m_currentCenterFrequency |
SampleVector | m_sampleBuffer |
Sample | m_sampleIn |
QMutex | m_mutex |
Protected Attributes inherited from BasebandSampleSource | |
MessageQueue | m_inputMessageQueue |
Queue for asynchronous inbound communication. More... | |
MessageQueue * | m_guiMessageQueue |
Input message queue to the GUI. More... | |
SampleSourceFifo | m_sampleFifo |
Internal FIFO for multi-channel processing. More... | |
SampleSourceFifo * | m_deviceSampleFifo |
Reference to the device FIFO for single channel processing. More... | |
Additional Inherited Members | |
Protected Slots inherited from BasebandSampleSource | |
void | handleInputMessages () |
void | handleWriteToFifo (int nbSamples) |
void | handleWriteToDeviceFifo (int nbSamples) |
Definition at line 37 of file upchannelizer.h.
|
protected |
Definition at line 123 of file upchannelizer.h.
UpChannelizer::UpChannelizer | ( | BasebandSampleSource * | sampleSink | ) |
Definition at line 31 of file upchannelizer.cpp.
|
virtual |
Definition at line 44 of file upchannelizer.cpp.
References freeFilterChain().
|
protected |
Definition at line 194 of file upchannelizer.cpp.
References UpChannelizer::MsgChannelizerNotification::create(), createFilterChain(), freeFilterChain(), BasebandSampleSource::getInputMessageQueue(), m_currentCenterFrequency, m_currentInputSampleRate, m_filterChainSetMode, m_filterStages, m_mutex, m_outputSampleRate, m_requestedCenterFrequency, m_requestedInputSampleRate, m_sampleSource, and MessageQueue::push().
Referenced by handleMessage().
|
protected |
Definition at line 234 of file upchannelizer.cpp.
References HBFilterChainConverter::convertToIndexes(), UpChannelizer::MsgChannelizerNotification::create(), UpChannelizer::FilterStage::FilterStage(), freeFilterChain(), BasebandSampleSource::getInputMessageQueue(), m_currentCenterFrequency, m_currentInputSampleRate, m_filterChainSetMode, m_filterStages, m_mutex, m_outputSampleRate, m_requestedCenterFrequency, m_requestedInputSampleRate, m_sampleSource, MessageQueue::push(), and setFilterChain().
Referenced by handleMessage().
void UpChannelizer::configure | ( | MessageQueue * | messageQueue, |
int | sampleRate, | ||
int | centerFrequency | ||
) |
Definition at line 49 of file upchannelizer.cpp.
References MessageQueue::push().
Referenced by UDPSource::handleMessage(), AMMod::handleMessage(), WFMMod::handleMessage(), NFMMod::handleMessage(), SSBMod::handleMessage(), FreeDVMod::handleMessage(), and ATVMod::handleMessage().
|
protected |
Definition at line 315 of file upchannelizer.cpp.
References UpChannelizer::FilterStage::FilterStage(), m_filterStages, m_stageSamples, UpChannelizer::FilterStage::ModeCenter, UpChannelizer::FilterStage::ModeLowerHalf, UpChannelizer::FilterStage::ModeUpperHalf, and signalContainsChannel().
Referenced by applyConfiguration().
|
protected |
Definition at line 408 of file upchannelizer.cpp.
References m_filterStages, and m_stageSamples.
Referenced by applyConfiguration(), applySetting(), and ~UpChannelizer().
|
inline |
Definition at line 89 of file upchannelizer.h.
Referenced by ATVMod::handleMessage().
|
virtual |
Processing of a message. Returns true if message has actually been processed.
Implements BasebandSampleSource.
Definition at line 133 of file upchannelizer.cpp.
References applyConfiguration(), applySetting(), DSPConfigureChannelizer::getCenterFrequency(), UpChannelizer::MsgSetChannelizer::getFilterChainHash(), Message::getIdentifier(), BasebandSampleSource::getInputMessageQueue(), UpChannelizer::MsgSetChannelizer::getLog2Interp(), DSPSignalNotification::getSampleRate(), DSPConfigureChannelizer::getSampleRate(), m_filterChainSetMode, m_outputSampleRate, m_requestedCenterFrequency, m_requestedInputSampleRate, m_sampleSource, Message::match(), outputSampleRateChanged(), and MessageQueue::push().
|
signal |
|
virtual |
Implements BasebandSampleSource.
Definition at line 61 of file upchannelizer.cpp.
References m_filterStages, m_mutex, m_sampleBuffer, m_sampleIn, m_sampleSource, m_stageSamples, and BasebandSampleSource::pull().
|
inlinevirtual |
Reimplemented from BasebandSampleSource.
Definition at line 94 of file upchannelizer.h.
void UpChannelizer::set | ( | MessageQueue * | messageQueue, |
unsigned int | log2Interp, | ||
unsigned int | filterChainHash | ||
) |
Definition at line 55 of file upchannelizer.cpp.
References MessageQueue::push().
Referenced by LocalSource::handleMessage(), and FileSource::handleMessage().
|
protected |
returns offset in ratio of sample rate
Definition at line 372 of file upchannelizer.cpp.
References UpChannelizer::FilterStage::FilterStage(), m_filterStages, m_stageSamples, UpChannelizer::FilterStage::ModeCenter, UpChannelizer::FilterStage::ModeLowerHalf, and UpChannelizer::FilterStage::ModeUpperHalf.
Referenced by applySetting().
|
protected |
Definition at line 305 of file upchannelizer.cpp.
Referenced by createFilterChain().
|
virtual |
Implements BasebandSampleSource.
Definition at line 115 of file upchannelizer.cpp.
References m_outputSampleRate, m_requestedCenterFrequency, m_requestedInputSampleRate, m_sampleSource, and BasebandSampleSource::start().
|
virtual |
Implements BasebandSampleSource.
Definition at line 127 of file upchannelizer.cpp.
References m_sampleSource, and BasebandSampleSource::stop().
|
protected |
Definition at line 132 of file upchannelizer.h.
Referenced by applyConfiguration(), and applySetting().
|
protected |
Definition at line 131 of file upchannelizer.h.
Referenced by applyConfiguration(), and applySetting().
|
protected |
Definition at line 125 of file upchannelizer.h.
Referenced by applyConfiguration(), applySetting(), and handleMessage().
|
protected |
Definition at line 124 of file upchannelizer.h.
Referenced by applyConfiguration(), applySetting(), createFilterChain(), freeFilterChain(), pull(), and setFilterChain().
|
protected |
Definition at line 135 of file upchannelizer.h.
Referenced by applyConfiguration(), applySetting(), and pull().
|
protected |
Definition at line 128 of file upchannelizer.h.
Referenced by applyConfiguration(), applySetting(), handleMessage(), and start().
|
protected |
Definition at line 130 of file upchannelizer.h.
Referenced by applyConfiguration(), applySetting(), handleMessage(), and start().
|
protected |
Definition at line 129 of file upchannelizer.h.
Referenced by applyConfiguration(), applySetting(), handleMessage(), and start().
|
protected |
Definition at line 133 of file upchannelizer.h.
Referenced by pull().
|
protected |
Definition at line 134 of file upchannelizer.h.
Referenced by pull().
|
protected |
Modulator.
Definition at line 127 of file upchannelizer.h.
Referenced by applyConfiguration(), applySetting(), handleMessage(), pull(), start(), and stop().
|
protected |
Definition at line 126 of file upchannelizer.h.
Referenced by createFilterChain(), freeFilterChain(), pull(), and setFilterChain().