ControllerInterface.ice
Go to the documentation of this file.
1/*
2 * This file is part of ArmarX.
3 *
4 * ArmarX is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License version 2 as
6 * published by the Free Software Foundation.
7 *
8 * ArmarX is distributed in the hope that it will be useful, but
9 * WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
12 *
13 * You should have received a copy of the GNU General Public License
14 * along with this program. If not, see <http://www.gnu.org/licenses/>.
15 *
16 * @package RobotAPI::NJointControllerInterface
17 * @author Mirko Waechter ( mirko dot waechter at kit dot edu )
18 * @date 2017
19 * @copyright http://www.gnu.org/licenses/gpl-2.0.txt
20 * GNU General Public License
21 */
22
23#pragma once
24
25#include <RobotAPI/interface/core/Trajectory.ice>
26#include <RobotAPI/interface/units/RobotUnit/NJointController.ice>
27
28module armarx
29{
30 class NJointBimanualCCDMPControllerConfig extends NJointControllerConfig
31 {
32
33 // dmp configuration
34 int kernelSize = 100;
35 string dmpMode = "MinimumJerk";
36 string dmpType = "Discrete";
37
38 // phaseStop technique
39 double phaseL = 10;
40 double phaseK = 10;
41 double phaseDist0 = 50;
42 double phaseDist1 = 10;
43 double phaseKpPos = 1;
44 double phaseKpOri = 0.1;
45 double posToOriRatio = 10;
46 double timeDuration = 10;
47
48 string defautLeader = "Left";
49
52
53 // float KoriFollower = 1;
54 // float KposFollower = 1;
55
58
59 Ice::FloatSeq leftKpos;
60 Ice::FloatSeq leftDpos;
61 Ice::FloatSeq leftKori;
62 Ice::FloatSeq leftDori;
63
64 Ice::FloatSeq rightKpos;
65 Ice::FloatSeq rightDpos;
66 Ice::FloatSeq rightKori;
67 Ice::FloatSeq rightDori;
68
69 float knull;
70 float dnull;
71
73
75
76 // Ice::FloatSeq Kpf;
77 // Ice::FloatSeq Kif;
78 // Ice::FloatSeq DesiredForce;
79
80 // float BoxWidth;
81
82 // float FilterTimeConstant;
83 };
84
85 interface NJointBimanualCCDMPControllerInterface extends NJointControllerInterface
86 {
87 void learnDMPFromFiles(string whichDMP, Ice::StringSeq trajfiles);
88 bool isFinished();
89 void runDMP(Ice::DoubleSeq leftGoals, Ice::DoubleSeq rightGoals);
90
91 void setViaPoints(double canVal, Ice::DoubleSeq point);
92 void setGoals(Ice::DoubleSeq goals);
93
96
97 string getLeaderName();
98 };
99
100 class NJointBimanualCCDMPVelocityControllerConfig extends NJointControllerConfig
101 {
102
103 // dmp configuration
104 int kernelSize = 100;
105 string dmpMode = "MinimumJerk";
106 string dmpType = "Discrete";
107
108 double timeDuration = 10;
109 string defautLeader = "Left";
110
113
116
117 Ice::FloatSeq leftKpos;
118 Ice::FloatSeq leftDpos;
119 Ice::FloatSeq leftKori;
120 Ice::FloatSeq leftDori;
121
122 Ice::FloatSeq rightKpos;
123 Ice::FloatSeq rightDpos;
124 Ice::FloatSeq rightKori;
125 Ice::FloatSeq rightDori;
126
127 float knull;
128 float dnull;
129
131 Ice::DoubleSeq initRatio;
132 };
133
134 interface NJointBimanualCCDMPVelocityControllerInterface extends NJointControllerInterface
135 {
136 void learnDMPFromFiles(string whichDMP, Ice::StringSeq trajfiles);
137 void learnDMPFromBothFiles(Ice::StringSeq leftFiles, Ice::StringSeq rightFiles);
139 void runDMP(Ice::DoubleSeq leftGoals, Ice::DoubleSeq rightGoals);
140
141 void setRatios(Ice::DoubleSeq ratios);
142
143 void setViaPoints(double canVal, Ice::DoubleSeq point);
144 void setGoals(Ice::DoubleSeq goals);
145
148
150 };
151};
void learnDMPFromFiles(string whichDMP, Ice::StringSeq trajfiles)
void setViaPoints(double canVal, Ice::DoubleSeq point)
void runDMP(Ice::DoubleSeq leftGoals, Ice::DoubleSeq rightGoals)
void learnDMPFromBothFiles(Ice::StringSeq leftFiles, Ice::StringSeq rightFiles)
void learnDMPFromFiles(string whichDMP, Ice::StringSeq trajfiles)
void setViaPoints(double canVal, Ice::DoubleSeq point)
void runDMP(Ice::DoubleSeq leftGoals, Ice::DoubleSeq rightGoals)
This file offers overloads of toIce() and fromIce() functions for STL container types.