USRP Hardware Driver and USRP Manual  Version: 4.6.0.0
UHD and USRP Manual
fosphor_block_control.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 
9 #include <uhd/config.hpp>
11 
12 namespace uhd { namespace rfnoc {
13 
16  RATIO_1_1,
17  RATIO_1_8,
18  RATIO_1_64,
20 };
21 
100 {
101 public:
103 
104  // Block registers
105  static const uint32_t REG_ENABLE_ADDR;
106  static const uint32_t REG_CLEAR_ADDR;
107  static const uint32_t REG_RANDOM_ADDR;
108  static const uint32_t REG_DECIM_ADDR;
109  static const uint32_t REG_OFFSET_ADDR;
110  static const uint32_t REG_SCALE_ADDR;
111  static const uint32_t REG_TRISE_ADDR;
112  static const uint32_t REG_TDECAY_ADDR;
113  static const uint32_t REG_ALPHA_ADDR;
114  static const uint32_t REG_EPSILON_ADDR;
115  static const uint32_t REG_WF_CTRL_ADDR;
116  static const uint32_t REG_WF_DECIM_ADDR;
117 
124  virtual void set_enable_histogram(const bool enable_histogram) = 0;
125 
132  virtual bool get_enable_histogram() const = 0;
133 
140  virtual void set_enable_waterfall(const bool enable_waterfall) = 0;
141 
148  virtual bool get_enable_waterfall() const = 0;
149 
155  virtual void clear_history() = 0;
156 
164  virtual void set_enable_dither(const bool enable_dither) = 0;
165 
172  virtual bool get_enable_dither() const = 0;
173 
181  virtual void set_enable_noise(const bool enable_noise) = 0;
182 
189  virtual bool get_enable_noise() const = 0;
190 
201  virtual void set_histogram_decimation(const uint16_t decimation) = 0;
202 
209  virtual uint16_t get_histogram_decimation() const = 0;
210 
218  virtual void set_histogram_offset(const uint16_t offset) = 0;
219 
226  virtual uint16_t get_histogram_offset() const = 0;
227 
235  virtual void set_histogram_scale(const uint16_t scale) = 0;
236 
243  virtual uint16_t get_histogram_scale() const = 0;
244 
256  virtual void set_histogram_rise_rate(const uint16_t rise_rate) = 0;
257 
264  virtual uint16_t get_histogram_rise_rate() const = 0;
265 
277  virtual void set_histogram_decay_rate(const uint16_t decay_rate) = 0;
278 
285  virtual uint16_t get_histogram_decay_rate() const = 0;
286 
296  virtual void set_spectrum_alpha(const uint16_t alpha) = 0;
297 
305  virtual uint16_t get_spectrum_alpha() const = 0;
306 
315  virtual void set_spectrum_max_hold_decay(const uint16_t epsilon) = 0;
316 
324  virtual uint16_t get_spectrum_max_hold_decay() const = 0;
325 
332  virtual void set_waterfall_predivision(
333  const fosphor_waterfall_predivision_ratio waterfall_predivision) = 0;
334 
341  virtual fosphor_waterfall_predivision_ratio get_waterfall_predivision() const = 0;
342 
354  virtual void set_waterfall_mode(const fosphor_waterfall_mode waterfall_mode) = 0;
355 
362  virtual fosphor_waterfall_mode get_waterfall_mode() const = 0;
363 
373  virtual void set_waterfall_decimation(const uint16_t waterfall_decimation) = 0;
374 
381  virtual uint16_t get_waterfall_decimation() const = 0;
382 };
383 
384 }} // namespace uhd::rfnoc
fosphor_waterfall_predivision_ratio
Definition: fosphor_block_control.hpp:15
#define RFNOC_DECLARE_BLOCK(CLASS_NAME)
Definition: noc_block_base.hpp:22
Definition: build_info.hpp:12
Definition: noc_block_base.hpp:42
#define UHD_API
Definition: config.h:87
Definition: fosphor_block_control.hpp:99
fosphor_waterfall_mode
Definition: fosphor_block_control.hpp:14