Agora  1.2.0
Agora project
radio_calibrate_analog.cc File Reference

Implementation file for the radio analog calibration functions , i.e. DC offset and IQ imbalance. More...

#include <chrono>
#include <thread>
#include "comms-lib.h"
#include "matplotlibcpp.h"
#include "radio_lib.h"
#include "radio_soapysdr.h"
Include dependency graph for radio_calibrate_analog.cc:

Functions

static size_t CheckTone (size_t channel, std::vector< Radio * > &rx_devs, std::vector< float > tone_levels, double fft_bin)
 
static void PlotTones (size_t channel, std::vector< Radio * > &rx_devs, std::vector< float > tone_levels, double fft_bin)
 
static void AdjustRxGains (size_t channel, std::vector< Radio * > &rx_devs, std::vector< float > tone_levels, const std::string &gain_stage, double min_setting, double max_setting)
 
static void MeasureCorrection (RadioSoapySdr *ref, size_t channel, size_t num_samples, size_t rx_center_tone, size_t tx_center_tone, const std::vector< float > &window, double window_gain)
 

Variables

static constexpr bool kIQImbalancePlot = false
 
static constexpr double kToneTargetLevel = -10.0f
 

Detailed Description

Implementation file for the radio analog calibration functions , i.e. DC offset and IQ imbalance.

Function Documentation

◆ AdjustRxGains()

static void AdjustRxGains ( size_t  channel,
std::vector< Radio * > &  rx_devs,
std::vector< float >  tone_levels,
const std::string &  gain_stage,
double  min_setting,
double  max_setting 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ CheckTone()

static size_t CheckTone ( size_t  channel,
std::vector< Radio * > &  rx_devs,
std::vector< float >  tone_levels,
double  fft_bin 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ MeasureCorrection()

static void MeasureCorrection ( RadioSoapySdr ref,
size_t  channel,
size_t  num_samples,
size_t  rx_center_tone,
size_t  tx_center_tone,
const std::vector< float > &  window,
double  window_gain 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ PlotTones()

static void PlotTones ( size_t  channel,
std::vector< Radio * > &  rx_devs,
std::vector< float >  tone_levels,
double  fft_bin 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

Variable Documentation

◆ kIQImbalancePlot

constexpr bool kIQImbalancePlot = false
staticconstexpr

◆ kToneTargetLevel

constexpr double kToneTargetLevel = -10.0f
staticconstexpr