Loading...
Searching...
No Matches
pwr_cal.hpp
Go to the documentation of this file.
//
// Copyright 2020 Ettus Research, a National Instruments Brand
//
// SPDX-License-Identifier: GPL-3.0-or-later
//
#pragma once
#include <uhd/cal/container.hpp>
#include <uhd/config.hpp>
#include <uhd/types/ranges.hpp>
#include <boost/none.hpp>
#include <boost/optional.hpp>
#include <cstdint>
#include <map>
#include <memory>
#include <string>
namespace uhd { namespace usrp { namespace cal {
class UHD_API pwr_cal : public container
{
public:
using sptr = std::shared_ptr<pwr_cal>;
virtual void add_power_table(const std::map<double, double>& gain_power_map,
const double min_power,
const double max_power,
const double freq,
const boost::optional<int> temperature = boost::none) = 0;
virtual void clear() = 0;
virtual void set_temperature(const int temperature) = 0;
virtual int get_temperature() const = 0;
virtual void set_ref_gain(const double gain) = 0;
virtual double get_ref_gain() const = 0;
virtual uhd::meta_range_t get_power_limits(const double freq,
const boost::optional<int> temperature = boost::none) const = 0;
virtual double get_power(const double gain,
const double freq,
const boost::optional<int> temperature = boost::none) const = 0;
virtual double get_gain(const double power_dbm,
const double freq,
const boost::optional<int> temperature = boost::none) const = 0;
static sptr make(
const std::string& name, const std::string& serial, const uint64_t timestamp);
static sptr make();
};
}}} // namespace uhd::usrp::cal
uhd::usrp::cal::container
Definition container.hpp:23
uhd::usrp::cal::pwr_cal
Definition pwr_cal.hpp:49
uhd::usrp::cal::pwr_cal::make
static sptr make(const std::string &name, const std::string &serial, const uint64_t timestamp)
Factory for new cal data sets.
uhd::usrp::cal::pwr_cal::make
static sptr make()
Default factory.
uhd::usrp::cal::pwr_cal::set_ref_gain
virtual void set_ref_gain(const double gain)=0
uhd::usrp::cal::pwr_cal::set_temperature
virtual void set_temperature(const int temperature)=0
uhd::usrp::cal::pwr_cal::get_gain
virtual double get_gain(const double power_dbm, const double freq, const boost::optional< int > temperature=boost::none) const =0
uhd::usrp::cal::pwr_cal::get_temperature
virtual int get_temperature() const =0
Return the current default temperature.
uhd::usrp::cal::pwr_cal::get_ref_gain
virtual double get_ref_gain() const =0
uhd::usrp::cal::pwr_cal::get_power_limits
virtual uhd::meta_range_t get_power_limits(const double freq, const boost::optional< int > temperature=boost::none) const =0
uhd::usrp::cal::pwr_cal::clear
virtual void clear()=0
uhd::usrp::cal::pwr_cal::get_power
virtual double get_power(const double gain, const double freq, const boost::optional< int > temperature=boost::none) const =0
uhd::usrp::cal::pwr_cal::sptr
std::shared_ptr< pwr_cal > sptr
Definition pwr_cal.hpp:51
uhd::usrp::cal::pwr_cal::add_power_table
virtual void add_power_table(const std::map< double, double > &gain_power_map, const double min_power, const double max_power, const double freq, const boost::optional< int > temperature=boost::none)=0
UHD_API
#define UHD_API
Definition config.h:87
config.hpp
container.hpp
uhd::usrp::cal
Definition container.hpp:15
uhd::usrp
Definition container.hpp:15
uhd
Definition build_info.hpp:12
ranges.hpp
uhd::meta_range_t
Definition ranges.hpp:66