SCL  1.0
Standard Control Library : Control, dynamics, physics, and simulation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Friends Macros Groups Pages
SControllerGc.hpp
1 /* This file is part of scl, a control and simulation library
2 for robots and biomechanical models.
3 
4 scl is free software; you can redistribute it and/or
5 modify it under the terms of the GNU Lesser General Public
6 License as published by the Free Software Foundation; either
7 version 3 of the License, or (at your option) any later version.
8 
9 Alternatively, you can redistribute it and/or
10 modify it under the terms of the GNU General Public License as
11 published by the Free Software Foundation; either version 2 of
12 the License, or (at your option) any later version.
13 
14 scl is distributed in the hope that it will be useful,
15 but WITHOUT ANY WARRANTY; without even the implied warranty of
16 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 GNU General Public License for more details.
18 
19 You should have received a copy of the GNU Lesser General Public
20 License and a copy of the GNU General Public License along with
21 scl. If not, see <http://www.gnu.org/licenses/>.
22 */
23 /*
24  * \file SControllerGc.hpp
25  *
26  * Created on: Dec 29, 2010
27  *
28  * Copyright (C) 2010
29  *
30  * Author: Samir Menon <smenon@stanford.edu>
31  */
32 
33 #ifndef SCONTROLLERGC_HPP_
34 #define SCONTROLLERGC_HPP_
35 
36 #include <vector>
37 #include <list>
38 #include <string>
39 
40 #include <scl/control/data_structs/SControllerBase.hpp>
41 
42 
43 namespace scl
44 {
45 
56  {
57  public:
59  Eigen::VectorXd des_force_gc_;
60 
62  Eigen::VectorXd des_q_;
64  Eigen::VectorXd des_dq_;
66  Eigen::VectorXd des_ddq_;
67 
70  Eigen::VectorXd force_gc_max_,force_gc_min_;
71 
77  Eigen::VectorXd kp_, kv_, ka_, ki_;
78 
85  sFloat integral_gain_time_pre_, integral_gain_time_curr_;
86 
89  Eigen::VectorXd integral_force_;
90 
91  /* ********************************************************
92  * Initialization Functions
93  * ******************************************************** */
95  SControllerGc();
96 
97  /* Initialization function. Sets all the control parameters */
98  sBool init(const std::string & arg_controller_name,
99  SRobotParsed* arg_robot_ds,
100  SRobotIO* arg_robot_io_ds,
101  /* The remaining variables initialize the gc controller */
102  const Eigen::VectorXd & arg_kp,
103  const Eigen::VectorXd & arg_kv,
104  const Eigen::VectorXd & arg_ka,
105  const Eigen::VectorXd & arg_ki,
106  const Eigen::VectorXd & arg_fgc_max,
107  const Eigen::VectorXd & arg_fgc_min);
108 
117  };
118 }
119 
120 #endif /* SGCCONTROLLER_HPP_ */
Eigen::VectorXd des_dq_
Definition: SControllerGc.hpp:64
Definition: SRobotIO.hpp:107
Eigen::VectorXd integral_force_
Definition: SControllerGc.hpp:89
sFloat integral_gain_time_pre_
Definition: SControllerGc.hpp:85
Eigen::VectorXd des_ddq_
Definition: SControllerGc.hpp:66
Definition: SRobotParsed.hpp:51
SControllerGc()
Definition: SControllerGc.cpp:45
bool sBool
Definition: DataTypes.hpp:54
Definition: SControllerBase.hpp:48
Eigen::VectorXd des_force_gc_
Definition: SControllerGc.hpp:59
Eigen::VectorXd force_gc_max_
Definition: SControllerGc.hpp:70
Eigen::VectorXd des_q_
Definition: SControllerGc.hpp:62
Definition: SControllerGc.hpp:55
double sFloat
Definition: DataTypes.hpp:72
Eigen::VectorXd kp_
Definition: SControllerGc.hpp:77