This page describes how VrSigProc's are initialized and which member functions are called at each stage of the initialization process.
Construction, CONNECT (connect_proc()), VrMultiTask::start
The VrSigProc constructor handles the following:
- Initialize mutex
- Allocate vector of pointers to VrBuffers based on the number of outputs
Any subclass of VrSigProc should initialize any data that is not sample rate dependent.
connect_proc() connects the next unused input of the calling VrSigProc to the specified upstream output. This is done by creating the appropriate VrConnect object to link them together.
Today, it also sets the upstream module's SamplingFrequency. This behavior is not desirable and will be changed.
This is a two phase process. First, for all sinks for which VrSigProc::isConnectedToSource returns true, invoke VrSigProc::init_base. init_base recurses up the tree (towards the sources), and does a post-order traversal, calling VrSigProc::initialize one time for each module in the chain. Because of the post-order traversal, the calls to initialize start at the sources and proceed to the sinks.
The second phase calls VrSigProc::setup on all connected sinks. Setup records that it has been called by incrementing setupCalled, and if it has been called by each of its connectors on each of its downstream buffers it continues the setup process upstream by invoking VrSigProc::setup_upstream. The result of this process is that the "setup" phase proceeds from the sinks to the sources, but only after everything downstream has been setup. After returning from setup_upstream, each output buffer's VrBuffer::setup is invoked, passing the output type size.
VrSigProc::setup_upstream
Generated on Wed Aug 4 02:22:27 2004 for GNU Radio by
1.3.8