Radio Control  Control Software and GUI for the Panoradio SDR, by DC9ST 2016
Signals | Public Member Functions | Private Attributes | List of all members
AudioDDC Class Reference

Class for controlling a single Audio DDC. More...

#include <audioddc.h>

Inheritance diagram for AudioDDC:

Signals

void send_new_lo_frequency (double frequency)
 send the current LO frequency (after it has been newly set, e.g. by a waterfall shift) More...
 

Public Member Functions

void init_lo (int address, int memsize, double master_frequency, int phase_width, double init_frequency)
 initializes LO IP core, required to run before using the DDC! More...
 
void init_capture (int address, int memsize, int capture_size)
 initializes Dual Capture IP core for IQ data, required to run before using the DDC! More...
 
void init_waterfall (WaterfallPlot *waterfall_audio, int max_frequency, double data_range_min, double data_range_max, double span_init, int data_size, int waterfall_depth)
 initializes the audio DDC, required to run after use! More...
 
double set_rx_frequency (double rx_frequency)
 sets LO frequency of DDC More...
 
void capture_and_show (double gain_correction)
 captures IQ data (after DDC) and shows them as a new line in the waterfall plot More...
 
void get_captured_data (double in[], double qu[])
 return the I&Q data for the last data capture (for debugging) More...
 
void correct_waterfall_size ()
 selects the correct size of the audio receiver's waterfall
 

Private Attributes

fft_basicfft_
 
DDS * local_oscillator_
 
Data_Capture_Dual * capture_data_
 
WaterfallPlotwaterfall_audio_
 
double * captured_data_i_
 
double * captured_data_q_
 
double * captured_data_fft_dbm_
 
int capture_max_size_
 
int data_size_
 
bool lo_initialized_
 
bool capture_initialized_
 
bool waterfall_initialized_
 

Detailed Description

Class for controlling a single Audio DDC.

Member Function Documentation

void AudioDDC::capture_and_show ( double  gain_correction)

captures IQ data (after DDC) and shows them as a new line in the waterfall plot

Parameters
gain_correctioncorrection factor in dB (will be subtracted from measured results in dbm) for the gain, that includes e.g. RF scaling gain, filter gain etc.
void AudioDDC::get_captured_data ( double  in[],
double  qu[] 
)
inline

return the I&Q data for the last data capture (for debugging)

Parameters
in[]array for writing the I data, array length = "data_size" (=size of data block to be captured and displayed)
qu[]array for writing the Q data, array length = "data_size" (=size of data block to be captured and displayed)
void AudioDDC::init_capture ( int  address,
int  memsize,
int  capture_size 
)

initializes Dual Capture IP core for IQ data, required to run before using the DDC!

Parameters
addressIP core address (from Vivado)
memsizeIP core memory size in k (from Vivado)
capture_sizedepth of capture memory in i/q sample pairs
void AudioDDC::init_lo ( int  address,
int  memsize,
double  master_frequency,
int  phase_width,
double  init_frequency 
)

initializes LO IP core, required to run before using the DDC!

Parameters
addressIP core address (from Vivado)
memsizeIP core memory size in k (from Vivado)
master_frequencyDDS master frequency in kHz (from Vivado)
phase_widthDDS phase width (from Vivado)
init_frequencyinital LO frequency in kHz
void AudioDDC::init_waterfall ( WaterfallPlot waterfall_audio,
int  max_frequency,
double  data_range_min,
double  data_range_max,
double  span_init,
int  data_size,
int  waterfall_depth 
)

initializes the audio DDC, required to run after use!

Parameters
*waterfall_audiopointer to waterfall display
max_frequencymaximum frequency the waterfall can be scrolled to in kHz (e.g. 125000 for 125 MHz)
data_range_minminimum data value in waterfall
data_range_maxmaximum data value in waterfall
span_initinitial frequency span of waterfall in kHz (= audio IQ signal's sample rate)
data_sizesize of data block to be captured and displayed
waterfall_depthdepth of waterfall display
void AudioDDC::send_new_lo_frequency ( double  frequency)
signal

send the current LO frequency (after it has been newly set, e.g. by a waterfall shift)

Parameters
frequencyLO frequency in kHz
double AudioDDC::set_rx_frequency ( double  rx_frequency)

sets LO frequency of DDC

Parameters
rx_frequencyin kHz
Returns
actually set frequency in kHz

The documentation for this class was generated from the following files: