USRP Hardware Driver and USRP Manual  Version: 004.000.000.HEAD-0-g8773fb2c
UHD and USRP Manual
window_block_ctrl.hpp
Go to the documentation of this file.
1 //
2 // Copyright 2014 Ettus Research LLC
3 //
4 // This program is free software: you can redistribute it and/or modify
5 // it under the terms of the GNU General Public License as published by
6 // the Free Software Foundation, either version 3 of the License, or
7 // (at your option) any later version.
8 //
9 // This program is distributed in the hope that it will be useful,
10 // but WITHOUT ANY WARRANTY; without even the implied warranty of
11 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 // GNU General Public License for more details.
13 //
14 // You should have received a copy of the GNU General Public License
15 // along with this program. If not, see <http://www.gnu.org/licenses/>.
16 //
17 
18 #ifndef INCLUDED_LIBUHD_RFNOC_WINDOW_BLOCK_CTRL_HPP
19 #define INCLUDED_LIBUHD_RFNOC_WINDOW_BLOCK_CTRL_HPP
20 
23 
24 namespace uhd {
25  namespace rfnoc {
26 
39 {
40 public:
42 
43  static const size_t MAX_COEFF_VAL = 32767;
44  static const boost::uint32_t SR_WINDOW_LEN = 131; // Note: AXI config bus uses 129 & 130
45  static const boost::uint32_t RB_MAX_WINDOW_LEN = 0;
46  static const boost::uint32_t AXIS_WINDOW_LOAD = AXIS_CONFIG_BUS+0; // 2*0+0
47  static const boost::uint32_t AXIS_WINDOW_LOAD_TLAST = AXIS_CONFIG_BUS+1; // 2*0+1
48 
50  //
51  // \p coeffs size determines the window length. If it longer than
52  // the maximum window length, throws a uhd::value_error.
53  virtual void set_window(const std::vector<int> &coeffs) = 0;
54 
56  virtual size_t get_max_len() const = 0;
57 
59  virtual size_t get_window_len() const = 0;
60 
61 }; /* class window_block_ctrl*/
62 
63 }} /* namespace uhd::rfnoc */
64 
65 #endif /* INCLUDED_LIBUHD_RFNOC_WINDOW_BLOCK_CTRL_HPP */
#define UHD_RFNOC_BLOCK_OBJECT(class_name)
This macro must be put in the public section of an RFNoC.
Definition: block_ctrl_base.hpp:74
Definition: sink_block_ctrl_base.hpp:36
STL namespace.
Definition: build_info.hpp:25
#define UHD_RFNOC_API
Definition: config.hpp:103
Definition: source_block_ctrl_base.hpp:35
Block controller for the standard windowing RFNoC block.
Definition: window_block_ctrl.hpp:38