From f10a484c0c7cd64bd01412267a1de6c0f1cfc9ab Mon Sep 17 00:00:00 2001 From: Nikolaus Vahrenkamp <vahrenkamp@kit.edu> Date: Tue, 15 Jul 2014 13:41:02 +0200 Subject: [PATCH] apply a tiny velocity after the object has been grasped in ordeer to ensure that the object stays grasped --- .../statecharts/GraspingWithTorques/GraspingWithTorques.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/source/RobotAPI/statecharts/GraspingWithTorques/GraspingWithTorques.cpp b/source/RobotAPI/statecharts/GraspingWithTorques/GraspingWithTorques.cpp index f1f8a2234..60a123777 100644 --- a/source/RobotAPI/statecharts/GraspingWithTorques/GraspingWithTorques.cpp +++ b/source/RobotAPI/statecharts/GraspingWithTorques/GraspingWithTorques.cpp @@ -380,7 +380,8 @@ namespace armarx for (int j=0; j<jointNames->getSize(); j++) { - jointNamesAndValues[jointNames->getVariant(j)->getString()] = 0.0f; //set everything to zero + // we want to ensure that the object stayes grasped -> apply a small velocity (todo: find a better solution!) + jointNamesAndValues[jointNames->getVariant(j)->getString()] = 0.01f; //set everything to zero controlModes[jointNames->getVariant(j)->getString()] = eVelocityControl; } -- GitLab