feedback-controller.hh
Go to the documentation of this file.
1 /*
2  * Copyright 2010 CNRS
3  *
4  * Florent Lamiraux
5  */
6 
7 #ifndef DG_TUTORIAL_FEEDBACK_CONTROLLER_HH
8 #define DG_TUTORIAL_FEEDBACK_CONTROLLER_HH
9 
10 #include <dynamic-graph/entity.h>
14 
15 namespace dynamicgraph {
16 namespace tutorial {
23 class FeedbackController : public Entity {
24  public:
28  FeedbackController(const std::string& inName);
29 
31 
33  virtual const std::string& getClassName(void) const { return CLASS_NAME; }
34 
36  virtual std::string getDocString() const {
37  return "Feedback controller aimed at maintaining the pendulum vertical\n";
38  }
46  void setGain(const ::dynamicgraph::Matrix& inGain) { gain_ = inGain; }
47 
51  ::dynamicgraph::Matrix getGain() const { return gain_; }
52 
57  public:
58  /*
59  \brief Class name
60  */
61  static const std::string CLASS_NAME;
62 
63  private:
67  double& computeForceFeedback(double& force, const int& inTime);
68 
77 
80 };
81 } // namespace tutorial
82 } // namespace dynamicgraph
83 
84 #endif // DG_TUTORIAL_FEEDBACK_CONTROLLER_HH
signal-ptr.h
dynamicgraph::tutorial::FeedbackController::getClassName
virtual const std::string & getClassName(void) const
Each entity should provide the name of the class it belongs to.
Definition: feedback-controller.hh:33
signal-time-dependent.h
dynamicgraph::SignalPtr< ::dynamicgraph::Vector, int >
dynamicgraph
dynamicgraph::tutorial::FeedbackController::computeForceFeedback
double & computeForceFeedback(double &force, const int &inTime)
Definition: feedback-controller.cpp:71
dynamicgraph::Entity
dynamicgraph::tutorial::FeedbackController::gain_
::dynamicgraph::Matrix gain_
Gain of the controller.
Definition: feedback-controller.hh:79
dynamicgraph::tutorial::FeedbackController::FeedbackController
FeedbackController(const std::string &inName)
Constructor by name.
Definition: feedback-controller.cpp:23
dynamicgraph::Matrix
Eigen::MatrixXd Matrix
dynamicgraph::tutorial::FeedbackController::stateSIN
SignalPtr< ::dynamicgraph::Vector, int > stateSIN
State of the inverted pendulum.
Definition: feedback-controller.hh:72
dynamicgraph::tutorial::FeedbackController::CLASS_NAME
static const std::string CLASS_NAME
Definition: feedback-controller.hh:61
dynamicgraph::tutorial::FeedbackController
Feedback controller for an inverted pendulum.
Definition: feedback-controller.hh:23
dynamicgraph::tutorial::FeedbackController::forceSOUT
SignalTimeDependent< double, int > forceSOUT
Force computed by the control law.
Definition: feedback-controller.hh:76
linear-algebra.h
dynamicgraph::tutorial::FeedbackController::getDocString
virtual std::string getDocString() const
Header documentation of the python class.
Definition: feedback-controller.hh:36
dynamicgraph::SignalTimeDependent< double, int >
dynamicgraph::tutorial::FeedbackController::getGain
::dynamicgraph::Matrix getGain() const
Get feedback gain.
Definition: feedback-controller.hh:51
dynamicgraph::tutorial::FeedbackController::~FeedbackController
~FeedbackController()
Definition: feedback-controller.cpp:69
dynamicgraph::tutorial::FeedbackController::setGain
void setGain(const ::dynamicgraph::Matrix &inGain)
Get feedback gain.
Definition: feedback-controller.hh:46


dynamic-graph-tutorial
Author(s): Nicolas Mansard, Olivier Stasse
autogenerated on Tue Jun 20 2023 02:35:58