USRP Hardware Driver and USRP Manual Version: 4.1.0.3
UHD and USRP Manual
core_iface.hpp
Go to the documentation of this file.
1//
2// Copyright 2020 Ettus Research, a National Instruments Brand
3//
4// SPDX-License-Identifier: GPL-3.0-or-later
5//
6
7#pragma once
8
10#include <uhd/types/ranges.hpp>
11#include <stdint.h>
12#include <string>
13#include <vector>
14
15namespace uhd { namespace rfnoc { namespace rf_control {
16
25{
26public:
27 virtual ~core_iface() = default;
28
33 virtual std::string get_tx_antenna(const size_t chan) const = 0;
34
39 virtual std::vector<std::string> get_tx_antennas(const size_t chan) const = 0;
40
45 virtual void set_tx_antenna(const std::string& ant, const size_t chan) = 0;
46
51 virtual std::string get_rx_antenna(const size_t chan) const = 0;
52
57 virtual std::vector<std::string> get_rx_antennas(const size_t chan) const = 0;
58
63 virtual void set_rx_antenna(const std::string& ant, const size_t chan) = 0;
64
69 virtual double get_tx_frequency(const size_t chan) = 0;
70
84 virtual double set_tx_frequency(const double freq, size_t chan) = 0;
85
88 virtual void set_tx_tune_args(const uhd::device_addr_t& args, const size_t chan) = 0;
89
94 virtual uhd::freq_range_t get_tx_frequency_range(const size_t chan) const = 0;
95
100 virtual double get_rx_frequency(const size_t chan) = 0;
101
114 virtual double set_rx_frequency(const double freq, const size_t chan) = 0;
115
118 virtual void set_rx_tune_args(const uhd::device_addr_t& args, const size_t chan) = 0;
119
124 virtual uhd::freq_range_t get_rx_frequency_range(const size_t chan) const = 0;
125
128 virtual std::vector<std::string> get_tx_gain_names(const size_t chan) const = 0;
129
132 virtual uhd::gain_range_t get_tx_gain_range(const size_t chan) const = 0;
133
137 const std::string& name, const size_t chan) const = 0;
138
143 virtual double get_tx_gain(const size_t chan) = 0;
144
149 virtual double get_tx_gain(const std::string& name, const size_t chan) = 0;
150
161 virtual double set_tx_gain(const double gain, const size_t chan) = 0;
162
170 virtual double set_tx_gain(
171 const double gain, const std::string& name, const size_t chan) = 0;
172
175 virtual std::vector<std::string> get_rx_gain_names(const size_t chan) const = 0;
176
179 virtual uhd::gain_range_t get_rx_gain_range(const size_t chan) const = 0;
180
184 const std::string& name, const size_t chan) const = 0;
185
190 virtual double get_rx_gain(const size_t chan) = 0;
191
196 virtual double get_rx_gain(const std::string& name, const size_t chan) = 0;
197
205 virtual double set_rx_gain(const double gain, const size_t chan) = 0;
206
214 virtual double set_rx_gain(
215 const double gain, const std::string& name, const size_t chan) = 0;
216
221 virtual void set_rx_agc(const bool enable, const size_t chan) = 0;
222
225 virtual meta_range_t get_tx_bandwidth_range(size_t chan) const = 0;
226
231 virtual double get_tx_bandwidth(const size_t chan) = 0;
232
239 virtual double set_tx_bandwidth(const double bandwidth, const size_t chan) = 0;
240
243 virtual meta_range_t get_rx_bandwidth_range(size_t chan) const = 0;
244
249 virtual double get_rx_bandwidth(const size_t chan) = 0;
250
257 virtual double set_rx_bandwidth(const double bandwidth, const size_t chan) = 0;
258
259 /**************************************************************************
260 * LO Controls
261 *************************************************************************/
267 virtual std::vector<std::string> get_rx_lo_names(const size_t chan) const = 0;
268
277 virtual std::vector<std::string> get_rx_lo_sources(
278 const std::string& name, const size_t chan) const = 0;
279
289 const std::string& name, const size_t chan) const = 0;
290
300 virtual void set_rx_lo_source(
301 const std::string& src, const std::string& name, const size_t chan) = 0;
302
311 virtual const std::string get_rx_lo_source(
312 const std::string& name, const size_t chan) = 0;
313
323 bool enabled, const std::string& name, const size_t chan) = 0;
324
330 virtual bool get_rx_lo_export_enabled(const std::string& name, const size_t chan) = 0;
331
339 virtual double set_rx_lo_freq(
340 double freq, const std::string& name, const size_t chan) = 0;
341
350 virtual double get_rx_lo_freq(const std::string& name, const size_t chan) = 0;
351
357 virtual std::vector<std::string> get_tx_lo_names(const size_t chan) const = 0;
358
367 virtual std::vector<std::string> get_tx_lo_sources(
368 const std::string& name, const size_t chan) const = 0;
369
379 const std::string& name, const size_t chan) = 0;
380
390 virtual void set_tx_lo_source(
391 const std::string& src, const std::string& name, const size_t chan) = 0;
392
401 virtual const std::string get_tx_lo_source(
402 const std::string& name, const size_t chan) = 0;
403
413 const bool enabled, const std::string& name, const size_t chan) = 0;
414
420 virtual bool get_tx_lo_export_enabled(const std::string& name, const size_t chan) = 0;
421
431 virtual double set_tx_lo_freq(
432 const double freq, const std::string& name, const size_t chan) = 0;
433
445 virtual double get_tx_lo_freq(const std::string& name, const size_t chan) = 0;
446};
447
448}}} // namespace uhd::rfnoc::rf_control
Definition: device_addr.hpp:38
Definition: core_iface.hpp:25
virtual double set_rx_lo_freq(double freq, const std::string &name, const size_t chan)=0
virtual meta_range_t get_rx_bandwidth_range(size_t chan) const =0
virtual double get_rx_bandwidth(const size_t chan)=0
virtual std::string get_rx_antenna(const size_t chan) const =0
virtual void set_rx_lo_source(const std::string &src, const std::string &name, const size_t chan)=0
virtual double set_tx_lo_freq(const double freq, const std::string &name, const size_t chan)=0
virtual uhd::freq_range_t get_rx_frequency_range(const size_t chan) const =0
virtual double get_rx_gain(const size_t chan)=0
virtual bool get_tx_lo_export_enabled(const std::string &name, const size_t chan)=0
virtual double get_tx_gain(const size_t chan)=0
virtual bool get_rx_lo_export_enabled(const std::string &name, const size_t chan)=0
virtual double get_tx_bandwidth(const size_t chan)=0
virtual double set_tx_gain(const double gain, const size_t chan)=0
virtual double set_rx_bandwidth(const double bandwidth, const size_t chan)=0
virtual double get_tx_gain(const std::string &name, const size_t chan)=0
virtual double set_rx_gain(const double gain, const size_t chan)=0
virtual void set_rx_tune_args(const uhd::device_addr_t &args, const size_t chan)=0
virtual double set_rx_gain(const double gain, const std::string &name, const size_t chan)=0
virtual void set_rx_lo_export_enabled(bool enabled, const std::string &name, const size_t chan)=0
virtual void set_rx_agc(const bool enable, const size_t chan)=0
virtual void set_tx_lo_source(const std::string &src, const std::string &name, const size_t chan)=0
virtual void set_rx_antenna(const std::string &ant, const size_t chan)=0
virtual meta_range_t get_tx_bandwidth_range(size_t chan) const =0
virtual double get_tx_frequency(const size_t chan)=0
virtual std::string get_tx_antenna(const size_t chan) const =0
virtual std::vector< std::string > get_rx_lo_names(const size_t chan) const =0
virtual std::vector< std::string > get_rx_gain_names(const size_t chan) const =0
virtual double get_rx_gain(const std::string &name, const size_t chan)=0
virtual uhd::gain_range_t get_rx_gain_range(const std::string &name, const size_t chan) const =0
virtual double set_tx_bandwidth(const double bandwidth, const size_t chan)=0
virtual uhd::gain_range_t get_tx_gain_range(const std::string &name, const size_t chan) const =0
virtual double set_tx_gain(const double gain, const std::string &name, const size_t chan)=0
virtual std::vector< std::string > get_tx_gain_names(const size_t chan) const =0
virtual const std::string get_tx_lo_source(const std::string &name, const size_t chan)=0
virtual uhd::gain_range_t get_rx_gain_range(const size_t chan) const =0
virtual double set_tx_frequency(const double freq, size_t chan)=0
virtual std::vector< std::string > get_tx_antennas(const size_t chan) const =0
virtual double get_rx_frequency(const size_t chan)=0
virtual std::vector< std::string > get_rx_lo_sources(const std::string &name, const size_t chan) const =0
virtual double get_tx_lo_freq(const std::string &name, const size_t chan)=0
virtual uhd::freq_range_t get_tx_frequency_range(const size_t chan) const =0
virtual freq_range_t get_rx_lo_freq_range(const std::string &name, const size_t chan) const =0
virtual std::vector< std::string > get_tx_lo_sources(const std::string &name, const size_t chan) const =0
virtual const std::string get_rx_lo_source(const std::string &name, const size_t chan)=0
virtual void set_tx_tune_args(const uhd::device_addr_t &args, const size_t chan)=0
virtual uhd::gain_range_t get_tx_gain_range(const size_t chan) const =0
virtual void set_tx_lo_export_enabled(const bool enabled, const std::string &name, const size_t chan)=0
virtual std::vector< std::string > get_tx_lo_names(const size_t chan) const =0
virtual double set_rx_frequency(const double freq, const size_t chan)=0
virtual std::vector< std::string > get_rx_antennas(const size_t chan) const =0
virtual void set_tx_antenna(const std::string &ant, const size_t chan)=0
virtual freq_range_t get_tx_lo_freq_range(const std::string &name, const size_t chan)=0
virtual double get_rx_lo_freq(const std::string &name, const size_t chan)=0
Definition: build_info.hpp:12
Definition: ranges.hpp:66