|
FERS 1.0.0
The Flexible Extensible Radar Simulator
|
Functions | |
| void | runPulsedFinalizer (radar::Receiver *receiver, const std::vector< std::unique_ptr< radar::Target > > *targets, std::shared_ptr< core::ProgressReporter > reporter) |
| The main function for a dedicated pulsed-mode receiver finalizer thread. | |
| void | finalizeCwReceiver (radar::Receiver *receiver, pool::ThreadPool *pool, std::shared_ptr< core::ProgressReporter > reporter) |
| The finalization task for a continuous-wave (CW) mode receiver. | |
| void | renderWindow (std::vector< ComplexType > &window, RealType length, RealType start, RealType fracDelay, std::span< const std::unique_ptr< serial::Response > > responses) |
| Renders a time-window of I/Q data from a collection of raw radar responses. | |
| void | applyThermalNoise (std::span< ComplexType > window, RealType noiseTemperature, std::mt19937 &rngEngine) |
| Applies thermal (Johnson-Nyquist) noise to a window of I/Q samples. | |
| RealType | quantizeAndScaleWindow (std::span< ComplexType > window) |
| Simulates ADC quantization and scales a window of complex I/Q samples. | |
| void processing::applyThermalNoise | ( | std::span< ComplexType > | window, |
| RealType | noiseTemperature, | ||
| std::mt19937 & | rngEngine | ||
| ) |
Applies thermal (Johnson-Nyquist) noise to a window of I/Q samples.
Simulates the addition of white Gaussian noise based on the receiver's noise temperature and the simulation bandwidth.
| window | A span of I/Q data to which noise will be added. |
| noiseTemperature | The effective noise temperature in Kelvin. |
| rngEngine | A random number generator engine to use for noise generation. |
Definition at line 113 of file signal_processor.cpp.
References params::boltzmannK(), noise::WgnGenerator::getSample(), params::oversampleRatio(), and params::rate().
Referenced by finalizeCwReceiver(), and runPulsedFinalizer().
Here is the call graph for this function:
Here is the caller graph for this function:| void processing::finalizeCwReceiver | ( | radar::Receiver * | receiver, |
| pool::ThreadPool * | pool, | ||
| std::shared_ptr< core::ProgressReporter > | reporter | ||
| ) |
The finalization task for a continuous-wave (CW) mode receiver.
This function is submitted to the main thread pool when a CW receiver finishes its operation. It processes the entire collected I/Q buffer, applies interference and noise, and writes the final data to a file.
| receiver | A pointer to the CW-mode receiver to finalize. |
| pool | A pointer to the main thread pool for parallelizing sub-tasks. |
| reporter | Shared pointer to the progress reporter for status updates. |
Definition at line 218 of file finalizer.cpp.
References applyThermalNoise(), fers_signal::downsample(), logging::FATAL, radar::Receiver::getMutableCwData(), radar::Object::getName(), radar::Receiver::getNoiseTemperature(), radar::Receiver::getPulsedInterferenceLog(), radar::Receiver::getRngEngine(), radar::Radar::getTiming(), logging::INFO, LOG, params::oversampleRatio(), quantizeAndScaleWindow(), params::rate(), and params::startTime().
Referenced by core::runEventDrivenSim().
Here is the call graph for this function:
Here is the caller graph for this function:| RealType processing::quantizeAndScaleWindow | ( | std::span< ComplexType > | window | ) |
Simulates ADC quantization and scales a window of complex I/Q samples.
This function first finds the maximum absolute value in the I/Q data to determine the full-scale range. It then simulates the quantization process based on the configured number of ADC bits. If no quantization is specified (adc_bits=0), it normalizes the data to a maximum amplitude of 1.0.
| window | The window of complex I/Q samples to quantize and scale. |
Definition at line 134 of file signal_processor.cpp.
References params::adcBits().
Referenced by finalizeCwReceiver(), and runPulsedFinalizer().
Here is the call graph for this function:
Here is the caller graph for this function:| void processing::renderWindow | ( | std::vector< ComplexType > & | window, |
| RealType | length, | ||
| RealType | start, | ||
| RealType | fracDelay, | ||
| std::span< const std::unique_ptr< serial::Response > > | responses | ||
| ) |
Renders a time-window of I/Q data from a collection of raw radar responses.
This function orchestrates the process of converting abstract Response objects into a concrete vector of complex I/Q samples for a specific time window. It handles the superposition of multiple signals arriving at the receiver during the window and can use a thread pool for parallel processing.
| window | The output vector where the rendered I/Q samples will be added. |
| length | The duration of the time window in seconds. |
| start | The start time of the window in seconds. |
| fracDelay | A fractional sample delay to apply for fine-grained timing. |
| responses | A span of unique pointers to the Response objects to be rendered. |
Definition at line 81 of file signal_processor.cpp.
References params::oversampleRatio(), and params::rate().
Referenced by runPulsedFinalizer().
Here is the call graph for this function:
Here is the caller graph for this function:| void processing::runPulsedFinalizer | ( | radar::Receiver * | receiver, |
| const std::vector< std::unique_ptr< radar::Target > > * | targets, | ||
| std::shared_ptr< core::ProgressReporter > | reporter | ||
| ) |
The main function for a dedicated pulsed-mode receiver finalizer thread.
This function runs in a loop, dequeuing and processing RenderingJobs for a specific receiver. It handles all expensive rendering, signal processing, and I/O for that receiver's data.
| receiver | A pointer to the pulsed-mode receiver to process. |
| targets | A pointer to the world's list of targets for interference calculation. |
| reporter | Shared pointer to the progress reporter for status updates. |
Definition at line 70 of file finalizer.cpp.
References core::RenderingJob::active_cw_sources, serial::addChunkToFile(), applyThermalNoise(), simulation::calculateDirectPathContribution(), simulation::calculateReflectedPathContribution(), radar::Receiver::checkFlag(), fers_signal::downsample(), core::RenderingJob::duration, logging::FATAL, radar::Receiver::FLAG_NODIRECT, radar::Object::getName(), radar::Receiver::getNoiseTemperature(), radar::Receiver::getRngEngine(), radar::Object::getRotation(), radar::Radar::getTiming(), radar::Receiver::getWindowLength(), radar::Receiver::getWindowPrf(), radar::Receiver::getWindowSkip(), core::RenderingJob::ideal_start_time, logging::INFO, LOG, params::oversampleRatio(), PI, quantizeAndScaleWindow(), params::rate(), renderWindow(), core::RenderingJob::responses, and radar::Receiver::waitAndDequeueFinalizerJob().
Referenced by core::runEventDrivenSim().
Here is the call graph for this function:
Here is the caller graph for this function: