28 #include <armarx/control/deprecated_njoint_mp_controller/task_space/ControllerInterface.h>
38 remote(remote), properties(properties)
43 RetrieveHand::_deleteTSVMPController()
49 ARMARX_DEBUG <<
"dmpController_RetrieveHand exists, but need to be deleted.";
57 loopScheduler.waitForNextTick();
67 RetrieveHand::_runTSVMPController()
72 double phaseDist0 = 50;
73 double phaseDist1 = 10;
76 double posToOriRatio = 10;
78 double maxLinearVel = 1000;
79 double maxAngularVel = 10;
81 _deleteTSVMPController();
83 armarx::NJointTaskSpaceDMPControllerConfigPtr tsConfig =
113 armarx::NJointTaskSpaceDMPControllerInterfacePrx dmpController =
114 armarx::NJointTaskSpaceDMPControllerInterfacePrx::checkedCast(
116 "NJointTSDMPController",
"dmpController_RetrieveHand", tsConfig));
120 dmpController->learnDMPFromFiles(fileNames);
130 std::vector<double> goals;
135 <<
VAROUT(targetPoseInRoot) <<
", vec: \n"
146 dmpController->activateController();
148 dmpController->runDMP(goals, 1.0);
153 while (running.load() && not dmpController->isFinished())
156 loopScheduler.waitForNextTick();
159 ARMARX_DEBUG <<
"VMP Controller finished, try to delete controller";
160 dmpController->deactivateController();
161 while (dmpController->isControllerActive())
163 loopScheduler.waitForNextTick();
165 dmpController->deleteController();
167 running.store(
false);