source: flair-dev/trunk/include/FlairSensorActuator/UsRangeFinder.h@ 45

Last change on this file since 45 was 13, checked in by Bayard Gildas, 6 years ago

formatting script + include reformatted

File size: 2.5 KB
Line 
1// %flair:license{
2// This file is part of the Flair framework distributed under the
3// CECILL-C License, Version 1.0.
4// %flair:license}
5/*!
6 * \file UsRangeFinder.h
7 * \brief Base class for UsRangeFinder
8 * \author Guillaume Sanahuja, Copyright Heudiasyc UMR UTC/CNRS 7253
9 * \date 2014/01/22
10 * \version 4.0
11 */
12
13#ifndef USRANGEFINDER_H
14#define USRANGEFINDER_H
15
16#include <IODevice.h>
17
18namespace flair {
19namespace core {
20class cvmatrix;
21}
22namespace gui {
23class Tab;
24class TabWidget;
25class GroupBox;
26class Layout;
27class DataPlot1D;
28}
29}
30
31namespace flair {
32namespace sensor {
33/*! \class UsRangeFinder
34*
35* \brief Base class for UsRangeFinder
36*
37* Use this class to define a custom UsRangeFinder.
38*
39*/
40class UsRangeFinder : public core::IODevice {
41public:
42 /*!
43 * \brief Constructor
44 *
45 * Construct a UsRangeFinder. Control part.
46 *
47 * \param parent parent
48 * \param name name
49 */
50 UsRangeFinder(const core::FrameworkManager *parent, std::string name);
51
52 /*!
53 * \brief Constructor
54 *
55 * Construct a UsRangeFinder. Simulation part.
56 *
57 * \param parent parent
58 * \param name name
59 */
60 UsRangeFinder(const core::IODevice *parent, std::string name);
61
62 /*!
63 * \brief Destructor
64 *
65 */
66 ~UsRangeFinder();
67
68 /*!
69 * \brief Lock user interface
70 *
71 */
72 void LockUserInterface(void) const;
73
74 /*!
75 * \brief Unlock user interface
76 *
77 */
78 void UnlockUserInterface(void) const;
79
80 /*!
81 * \brief Use default plot
82 *
83 * Should no be used for the simulation part.
84 */
85 void UseDefaultPlot(void);
86
87 /*!
88 * \brief Plot
89 *
90 * \return DataPlot1D
91 */
92 gui::DataPlot1D *GetPlot(void) const;
93
94 /*!
95 * \brief Setup Layout
96 *
97 * \return a Layout available
98 */
99 gui::Layout *GetLayout(void) const;
100
101 /*!
102 * \brief Plot tab
103 *
104 * \return plot Tab
105 */
106 gui::Tab *GetPlotTab(void) const;
107
108 /*!
109 * \brief Value
110 *
111 * \return output value
112 */
113 float Value(void) const;
114
115protected:
116 /*!
117 * \brief Output matrix
118 *
119 * \return output matrix
120 */
121 core::cvmatrix *output;
122
123 /*!
124 * \brief Setup GroupBox
125 *
126 * \return a GroupBox available
127 */
128 gui::GroupBox *GetGroupBox(void) const;
129
130private:
131 /*!
132 * \brief Update using provided datas
133 *
134 * Reimplemented from IODevice.
135 *
136 * \param data data from the parent to process
137 */
138 void UpdateFrom(const core::io_data *data){};
139
140 gui::Tab *main_tab;
141 gui::TabWidget *tab;
142 gui::GroupBox *setup_groupbox;
143 gui::Tab *sensor_tab;
144 gui::DataPlot1D *plot;
145 gui::Tab *plot_tab;
146};
147} // end namespace sensor
148} // end namespace flair
149#endif // USRANGEFINDER_H
Note: See TracBrowser for help on using the repository browser.