GNU Radio Radar Toolbox
msg_manipulator.h
Go to the documentation of this file.
1 /* -*- c++ -*- */
2 /*
3  * Copyright 2014 Communications Engineering Lab, KIT.
4  *
5  * This is free software; you can redistribute it and/or modify
6  * it under the terms of the GNU General Public License as published by
7  * the Free Software Foundation; either version 3, or (at your option)
8  * any later version.
9  *
10  * This software is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13  * GNU General Public License for more details.
14  *
15  * You should have received a copy of the GNU General Public License
16  * along with this software; see the file COPYING. If not, write to
17  * the Free Software Foundation, Inc., 51 Franklin Street,
18  * Boston, MA 02110-1301, USA.
19  */
20 
21 
22 #ifndef INCLUDED_RADAR_MSG_MANIPULATOR_H
23 #define INCLUDED_RADAR_MSG_MANIPULATOR_H
24 
25 #include <radar/api.h>
26 #include <gnuradio/block.h>
27 
28 namespace gr {
29  namespace radar {
30 
31  /*!
32  * \brief This block manipulates data in a msg with given identifier (symbol). All data are given as vectors and each index represents a dataset with identifier which should be processed. All other data is pushed through. The addition is performed before the multiplication.
33  *
34  * \param symbols Identifier (symbols) of data as vector
35  * \param const_add Value to add on the data
36  * \param const_mult Value to multiply on the data
37  *
38  * \ingroup radar
39  *
40  */
41  class RADAR_API msg_manipulator : virtual public gr::block
42  {
43  public:
44  typedef boost::shared_ptr<msg_manipulator> sptr;
45 
46  /*!
47  * \brief Return a shared_ptr to a new instance of radar::msg_manipulator.
48  *
49  * To avoid accidental use of raw pointers, radar::msg_manipulator's
50  * constructor is in a private implementation
51  * class. radar::msg_manipulator::make is the public interface for
52  * creating new instances.
53  */
54  static sptr make(std::vector<std::string> symbols, std::vector<float> const_add, std::vector<float> const_mult);
55  virtual void set_const_add(std::vector<float> val) = 0;
56  virtual void set_const_mult(std::vector<float> val) = 0;
57  };
58 
59  } // namespace radar
60 } // namespace gr
61 
62 #endif /* INCLUDED_RADAR_MSG_MANIPULATOR_H */
63 
boost::shared_ptr< msg_manipulator > sptr
Definition: msg_manipulator.h:44
Definition: crop_matrix_vcvc.h:28
This block manipulates data in a msg with given identifier (symbol). All data are given as vectors an...
Definition: msg_manipulator.h:41
#define RADAR_API
Definition: api.h:30