28 #include <armarx/control/deprecated_njoint_mp_controller/task_space/ControllerInterface.h>
38 remote(remote), properties(properties)
43 RetrieveHand::_deleteTSVMPController()
48 ARMARX_DEBUG <<
"dmpController_RetrieveHand exists, but need to be deleted.";
56 loopScheduler.waitForNextTick();
66 RetrieveHand::_runTSVMPController()
71 double phaseDist0 = 50;
72 double phaseDist1 = 10;
75 double posToOriRatio = 10;
77 double maxLinearVel = 1000;
78 double maxAngularVel = 10;
80 _deleteTSVMPController();
82 armarx::NJointTaskSpaceDMPControllerConfigPtr tsConfig =
112 armarx::NJointTaskSpaceDMPControllerInterfacePrx dmpController =
113 armarx::NJointTaskSpaceDMPControllerInterfacePrx::checkedCast(
115 "NJointTSDMPController",
"dmpController_RetrieveHand", tsConfig));
119 dmpController->learnDMPFromFiles(fileNames);
129 std::vector<double> goals;
134 <<
VAROUT(targetPoseInRoot) <<
", vec: \n"
145 dmpController->activateController();
147 dmpController->runDMP(goals, 1.0);
152 while (running.load() && not dmpController->isFinished())
155 loopScheduler.waitForNextTick();
158 ARMARX_DEBUG <<
"VMP Controller finished, try to delete controller";
159 dmpController->deactivateController();
160 while (dmpController->isControllerActive())
162 loopScheduler.waitForNextTick();
164 dmpController->deleteController();
166 running.store(
false);