25 #include <VirtualRobot/MathTools.h>
34 #include <simox/control/geodesics/util.h>
35 #include <simox/control/robot/NodeInterface.h>
39 NJointControllerRegistration<NJointTaskspaceSafetyImpedanceController>
41 "NJointTaskspaceSafetyImpedanceController");
45 const std::string nodeSetName,
49 std::shared_ptr<std::vector<::simox::control::environment::DistanceResult>> collisionPairs)
51 arm->kinematicChainName = nodeSetName;
52 VirtualRobot::RobotNodeSetPtr rtRns =
53 rtGetRobot()->getRobotNodeSet(arm->kinematicChainName);
54 arm->tcpName = rtRns->getTCP()->getName();
55 VirtualRobot::RobotNodeSetPtr nonRtRns =
56 nonRtRobotPtr->getRobotNodeSet(arm->kinematicChainName);
59 ARMARX_IMPORTANT <<
"Creating Taskspace Impedance controller with kinematic chain: "
60 << arm->kinematicChainName <<
" with num of joints: (RT robot) "
61 << rtRns->getSize() <<
", and (non-RT robot) " << nonRtRns->getSize();
64 arm->controller.ftsensor.initialize(rtRns,
robotUnit, cfg.ftConfig);
65 arm->jointNames.clear();
66 for (
size_t i = 0; i < rtRns->getSize(); ++i)
68 std::string jointName = rtRns->getNode(i)->getName();
69 arm->jointNames.push_back(jointName);
75 auto* casted_ct = ct->
asA<ControlTarget1DoFActuatorTorque>();
77 arm->targets.push_back(casted_ct);
79 const auto* torqueSensor = sv->
asA<SensorValue1DoFActuatorTorque>();
80 const auto* velocitySensor = sv->
asA<SensorValue1DoFActuatorVelocity>();
81 const auto* positionSensor = sv->
asA<SensorValue1DoFActuatorPosition>();
83 if (torqueSensor ==
nullptr)
87 if (velocitySensor ==
nullptr)
89 ARMARX_WARNING <<
"No velocity sensor available for " << jointName;
91 if (positionSensor ==
nullptr)
93 ARMARX_WARNING <<
"No position sensor available for " << jointName;
96 arm->sensorDevices.torqueSensors.push_back(torqueSensor);
97 arm->sensorDevices.velocitySensors.push_back(velocitySensor);
98 arm->sensorDevices.positionSensors.push_back(positionSensor);
102 arm->inertiaPtr = std::make_shared<simox::control::geodesics::metric::Inertia>(
110 arm->pointsOnArmIndex = 0;
115 arm->nonRtConfig = cfg;
119 const RobotUnitPtr& robotUnit,
120 const NJointControllerConfigPtr& config,
126 ConfigPtrT cfg = ConfigPtrT::dynamicCast(config);
136 std::vector<std::string> poseNodeNames;
139 const auto nodeset =
rtGetRobot()->getRobotNodeSet(pair.first);
140 std::string tcpName = nodeset->getTCP()->getName();
141 poseNodeNames.push_back(tcpName);
148 std::string actuatedNodeSet;
151 actuatedNodeSet = pair.second.actuatedJointsNodeSet;
158 auto actRns =
rtGetRobot()->getRobotNodeSet(actuatedNodeSet)->getNodeNames();
162 const bool reduceModel =
true;
166 std::string primitiveModelID =
"ApproxHand";
167 std::vector<std::string> primitiveModelIDs{primitiveModelID};
170 std::make_unique<simox::control::environment::CollisionRobot<hpp::fcl::OBBRSS>>(
172 collisionPairs = std::make_shared<std::vector<simox::control::environment::DistanceResult>>(
187 limb.emplace(pair.first, std::make_unique<ArmData>());
195 return "NJointTaskspaceSafetyImpedanceController";
201 std::string taskName =
getClassName() +
"AdditionalTask";
213 while (
getState() == eManagedIceObjectStarted)
219 c.waitForCycleDuration();
227 arm->nonRtConfig = arm->bufferConfigUserToNonRt.getUpToDateReadBuffer();
228 arm->bufferConfigNonRtToRt.getWriteBuffer() = arm->nonRtConfig;
229 arm->bufferConfigNonRtToRt.commitWrite();
237 for (
auto& pair :
limb)
240 pair.second->rtStatusInNonRT =
241 pair.second->bufferRtStatusToNonRt.getUpToDateReadBuffer();
242 rtSafe = rtSafe and pair.second->rtStatusInNonRT.rtSafe;
246 for (
auto& pair :
limb)
248 if (not pair.second->rtReady)
250 const auto& desiredPose =
251 pair.second->rtStatusInNonRT.desiredPose.topRightCorner<3, 1>();
252 const auto& currentPose =
253 pair.second->rtStatusInNonRT.currentPose.topRightCorner<3, 1>();
254 if ((desiredPose - currentPose).norm() >
255 pair.second->nonRtConfig.safeDistanceMMToGoal)
258 "new target \n\n [%.2f, %.2f, %.2f]\n\nis too far away from the "
259 "current pose\n\n [%.2f, %.2f, %.2f]",
260 pair.second->rtStatusInNonRT.desiredPose(0, 3),
261 pair.second->rtStatusInNonRT.desiredPose(1, 3),
262 pair.second->rtStatusInNonRT.desiredPose(2, 3),
263 pair.second->rtStatusInNonRT.currentPose(0, 3),
264 pair.second->rtStatusInNonRT.currentPose(1, 3),
265 pair.second->rtStatusInNonRT.currentPose(2, 3))
266 .deactivateSpam(1.0);
275 double timeMeasure = IceUtil::Time::now().toMicroSecondsDouble();
276 arm->rtConfig = arm->bufferConfigNonRtToRt.getUpToDateReadBuffer();
277 double time_update_non_rt_buffer =
278 IceUtil::Time::now().toMicroSecondsDouble() - timeMeasure;
280 arm->rtStatus.deltaT = deltaT;
281 arm->controller.ftsensor.updateStatus(
282 arm->rtConfig.ftConfig, arm->rtStatus.currentForceTorque, arm->rtStatus.deltaT, arm->rtFirstRun.load());
284 double time_update_ft = IceUtil::Time::now().toMicroSecondsDouble() - timeMeasure;
286 size_t nDoF = arm->sensorDevices.positionSensors.size();
287 double time_update_size = IceUtil::Time::now().toMicroSecondsDouble() - timeMeasure;
288 for (
size_t i = 0; i < nDoF; ++i)
290 arm->rtStatus.jointPosition[i] = arm->sensorDevices.positionSensors[i]->position;
291 arm->rtStatus.jointVelocity[i] = arm->sensorDevices.velocitySensors[i]->velocity;
292 arm->rtStatus.jointTorque[i] = arm->sensorDevices.torqueSensors[i]->torque;
295 double time_update_js = IceUtil::Time::now().toMicroSecondsDouble() - timeMeasure;
297 double time_update_rt_status = IceUtil::Time::now().toMicroSecondsDouble() - timeMeasure;
299 arm->bufferRtStatusToNonRt.getWriteBuffer() = arm->rtStatus;
300 arm->bufferRtStatusToNonRt.commitWrite();
301 arm->bufferRtStatusToUser.getWriteBuffer() = arm->rtStatus;
302 arm->bufferRtStatusToUser.commitWrite();
303 double time_write_rt_buffer = IceUtil::Time::now().toMicroSecondsDouble() - timeMeasure;
305 arm->controller.run(arm->rtConfig,
307 arm->collisionPairsPtr,
309 arm->pointsOnArmIndex,
312 double time_run_rt = IceUtil::Time::now().toMicroSecondsDouble() - timeMeasure;
314 for (
unsigned int i = 0; i < arm->rtStatus.desiredJointTorques.size(); i++)
316 arm->targets.at(i)->torque = arm->rtStatus.desiredJointTorques(i);
318 if (!arm->targets.at(i)->isValid())
320 arm->targets.at(i)->torque = 0;
323 arm->bufferRtStatusToOnPublish.getWriteBuffer() = arm->rtStatus;
324 arm->bufferRtStatusToOnPublish.commitWrite();
326 arm->bufferConfigRtToOnPublish.getWriteBuffer() = arm->rtConfig;
327 arm->bufferConfigRtToOnPublish.commitWrite();
329 arm->bufferConfigRtToUser.getWriteBuffer() = arm->rtConfig;
330 arm->bufferConfigRtToUser.commitWrite();
331 double time_rt_status_buffer = IceUtil::Time::now().toMicroSecondsDouble() - timeMeasure;
332 timeMeasure = IceUtil::Time::now().toMicroSecondsDouble() - timeMeasure;
335 if (timeMeasure > 300)
338 "update_non_rt_buffer: %.2f\n"
340 "update_size: %.2f\n"
342 "update_rt_status: %.2f\n"
343 "write_rt_buffer: %.2f\n"
345 "rt_status_buffer: %.2f\n"
347 time_update_non_rt_buffer,
348 time_update_ft - time_update_non_rt_buffer,
349 time_update_size - time_update_ft,
350 time_update_js - time_update_size,
351 time_update_rt_status - time_update_non_rt_buffer,
352 time_write_rt_buffer - time_update_rt_status,
353 time_run_rt - time_write_rt_buffer,
354 time_rt_status_buffer - time_run_rt,
356 .deactivateSpam(1.0f);
358 if (arm->rtFirstRun.load())
360 arm->rtFirstRun.store(
false);
361 arm->rtReady.store(
true);
371 double timeMeasure = IceUtil::Time::now().toMicroSecondsDouble();
375 std::vector<simox::control::environment::DistanceResult> results =
380 double collisionPairTime = IceUtil::Time::now().toMicroSecondsDouble() - timeMeasure;
382 for (
auto& pair :
limb)
385 pair.second->pointsOnArmIndex = 0;
386 pair.second->rtStatus.collisionPairTime = collisionPairTime;
395 timeMeasure = IceUtil::Time::now().toMicroSecondsDouble();
405 for (
auto& pair :
limb)
407 if (std::find(pair.second->jointNames.begin(),
408 pair.second->jointNames.end(),
414 pair.second->pointsOnArm->at(pair.second->pointsOnArmIndex) = i;
415 pair.second->pointsOnArmIndex++;
417 else if (std::find(pair.second->jointNames.begin(),
418 pair.second->jointNames.end(),
420 pair.second->jointNames.end() or
423 pair.second->pointsOnArm->at(pair.second->pointsOnArmIndex) = i;
424 pair.second->pointsOnArmIndex++;
429 double preFilterTime = IceUtil::Time::now().toMicroSecondsDouble() - timeMeasure;
431 if (preFilterTime > 100 or collisionPairTime > 100)
434 "preFilterTime: %.2f\n"
435 "collisionPairTime: %.2f\n",
438 .deactivateSpam(1.0f);
442 for (
auto& pair :
limb)
445 for (
size_t i = pair.second->pointsOnArmIndex; i < pair.second->pointsOnArm->size();
448 pair.second->pointsOnArm->at(i) = -1;
450 pair.second->rtStatus.preFilterTime = preFilterTime;
451 pair.second->rtStatus.activeCollPairsNum = pair.second->pointsOnArmIndex;
455 double deltaT = timeSinceLastIteration.toSecondsDouble();
456 for (
auto& pair :
limb)
458 limbRT(pair.second, deltaT);
466 double jointValue =
static_cast<double>(node->getJointValue());
468 if (node->isTranslationalJoint())
490 const Ice::Current& iceCurrent)
492 std::vector<float> tcpVel;
493 auto& arm =
limb.at(rns);
494 auto s = arm->bufferRtStatusToUser.getUpToDateReadBuffer();
495 for (
int i = 0; i <
s.currentTwist.size(); i++)
497 tcpVel.push_back(
s.currentTwist[i]);
505 const Ice::Current& iceCurrent)
512 limb.at(pair.first)->bufferConfigUserToNonRt.getWriteBuffer() = pair.second;
513 limb.at(pair.first)->bufferConfigUserToNonRt.commitWrite();
519 const std::string& nodeSetName,
520 const bool forceGuard,
521 const bool torqueGuard,
522 const Ice::Current& iceCurrent)
527 it->second.ftConfig.enableSafeGuardForce = forceGuard;
528 it->second.ftConfig.enableSafeGuardTorque = torqueGuard;
529 limb.at(nodeSetName)->controller.ftsensor.enableSafeGuard(forceGuard, torqueGuard);
531 <<
"reset safe guard with force torque sensors: safe? "
532 <<
limb.at(nodeSetName)->controller.ftsensor.isSafe(it->second.ftConfig);
533 limb.at(nodeSetName)->bufferConfigUserToNonRt.getWriteBuffer() = it->second;
534 limb.at(nodeSetName)->bufferConfigUserToNonRt.commitWrite();
539 <<
" found in the controllers.";
545 const Ice::Current& iceCurrent)
550 return limb.at(nodeSetName)->controller.ftsensor.ftSafe.load();
555 <<
" found in the controllers.";
564 const Ice::Current& iceCurrent)
568 for (
size_t i = 0; i < 4; ++i)
570 for (
int j = 0; j < 4; ++j)
572 pair.second.desiredPose(i, j) = targetPoseMap.at(pair.first)[i][j];
575 if (targetNullspaceMap.at(pair.first).size() > 0)
577 const size_t nDoF = pair.second.desiredNullspaceJointAngles.value().size();
579 <<
"the joint numbers does not match";
580 for (
size_t i = 0; i < nDoF; ++i)
582 pair.second.desiredNullspaceJointAngles.value()(i) =
583 targetNullspaceMap.at(pair.first)[i];
586 limb.at(pair.first)->bufferConfigUserToNonRt.getWriteBuffer() = pair.second;
587 limb.at(pair.first)->bufferConfigUserToNonRt.commitWrite();
595 for (
auto& pair :
limb)
598 pair.second->bufferConfigRtToUser.getUpToDateReadBuffer();
606 const auto nDoF = arm->controller.numOfJoints;
609 const auto checkNonNegative = [](
const auto&
v) {
ARMARX_CHECK((
v.array() >= 0).all()); };
611 if (!configData.desiredNullspaceJointAngles.has_value())
615 ARMARX_INFO <<
"No user defined nullspace target, reset to zero with "
617 configData.desiredNullspaceJointAngles = Eigen::VectorXf::Zero(nDoF);
618 arm->reInitPreActivate.store(
true);
623 arm->bufferConfigRtToUser.getUpToDateReadBuffer().desiredNullspaceJointAngles;
625 <<
"Controller is active, but no user defined nullspace target. \n"
626 "You should first get up-to-date config of this controller and then update "
628 " auto cfg = ctrl->getConfig(); \n"
629 " cfg.desiredPose = xxx;\n"
630 " ctrl->updateConfig(cfg);\n"
631 "Now, I decide by myself to use the existing values of nullspace target\n"
632 << currentValue.value();
633 configData.desiredNullspaceJointAngles = currentValue;
636 checkSize(configData.desiredNullspaceJointAngles.value());
637 checkSize(configData.kdNullspace);
638 checkSize(configData.kpNullspace);
640 checkNonNegative(configData.kdNullspace);
641 checkNonNegative(configData.kpNullspace);
642 checkNonNegative(configData.kdImpedance);
643 checkNonNegative(configData.kpImpedance);
668 if (configData.topPrioritySelfCollisionAvoidance)
672 !configData.topPriorityJointLimitAvoidance));
674 if (configData.topPriorityJointLimitAvoidance)
678 !configData.topPriorityJointLimitAvoidance));
689 auto rtData = arm->bufferConfigRtToOnPublish.getUpToDateReadBuffer();
690 auto rtStatus = arm->bufferRtStatusToOnPublish.getUpToDateReadBuffer();
691 datafields[
"deltaT"] =
new Variant(rtStatus.deltaT);
1086 debugObs->setDebugChannel(
1087 "NJointTaskspaceSafetyImpedanceController_" + arm->kinematicChainName, datafields);
1095 for (
auto& pair :
limb)
1097 if (not pair.second->rtReady.load())
1107 for (
auto& pair :
limb)
1109 pair.second->rtReady.store(
false);
1116 VirtualRobot::RobotNodeSetPtr rns =
rtGetRobot()->getRobotNodeSet(arm->kinematicChainName);
1118 ARMARX_IMPORTANT <<
"rt preactivate controller with target pose\n\n" << currentPose;
1120 if (arm->reInitPreActivate.load())
1122 arm->rtConfig.desiredNullspaceJointAngles.value() = rns->getJointValuesEigen();
1123 arm->rtConfig.desiredPose = currentPose;
1125 arm->bufferConfigUserToNonRt.reinitAllBuffers(arm->rtConfig);
1126 arm->reInitPreActivate.store(
false);
1129 arm->nonRtConfig = arm->rtConfig;
1130 arm->bufferConfigNonRtToRt.reinitAllBuffers(arm->rtConfig);
1131 arm->bufferConfigRtToOnPublish.reinitAllBuffers(arm->rtConfig);
1132 arm->bufferConfigRtToUser.reinitAllBuffers(arm->rtConfig);
1135 const auto nDoF = rns->getSize();
1137 arm->rtStatus.numJoints = nDoF;
1138 arm->rtStatus.desiredJointTorques.setZero(nDoF);
1139 arm->rtStatus.forceImpedance.setZero();
1140 arm->rtStatus.kdForceImpedance.setZero();
1141 arm->rtStatus.nullspaceTorque.setZero(nDoF);
1142 arm->rtStatus.jointDampingTorque.setZero(nDoF);
1144 arm->rtStatus.jointPosition.resize(nDoF, 0.);
1145 arm->rtStatus.jointVelocity.resize(nDoF, 0.);
1146 arm->rtStatus.jointTorque.resize(nDoF, 0.);
1147 for (
size_t i = 0; i < nDoF; ++i)
1149 arm->rtStatus.jointPosition[i] = arm->sensorDevices.positionSensors[i]->position;
1150 arm->rtStatus.jointVelocity[i] = arm->sensorDevices.velocitySensors[i]->velocity;
1151 arm->rtStatus.jointTorque[i] = arm->sensorDevices.torqueSensors[i]->torque;
1154 arm->rtStatus.qpos = rns->getJointValuesEigen();
1155 arm->rtStatus.qvel.setZero(nDoF);
1156 arm->rtStatus.qvelFiltered.setZero(nDoF);
1158 arm->rtStatus.currentPose = currentPose;
1159 arm->rtStatus.desiredPose = currentPose;
1160 arm->rtStatus.currentTwist.setZero();
1161 arm->rtStatus.poseDiffMatImp.setZero();
1162 arm->rtStatus.poseErrorImp.setZero();
1163 arm->rtStatus.trackingError = 0.0;
1164 arm->rtStatus.jacobi.setZero(6, nDoF);
1165 arm->rtStatus.jtpinv.setZero(6, nDoF);
1167 arm->rtStatus.dirErrorImp.setZero();
1168 arm->rtStatus.totalForceImpedance = 0.0;
1169 arm->rtStatus.projForceImpedance.setZero();
1170 arm->rtStatus.projTotalForceImpedance = 0.0;
1172 arm->rtStatus.impedanceJointTorque.setZero(nDoF);
1173 arm->rtStatus.kdImpedanceTorque.setZero(nDoF);
1174 arm->rtStatus.selfCollisionJointTorque.setZero(nDoF);
1175 arm->rtStatus.jointLimitJointTorque.setZero(nDoF);
1177 arm->rtStatus.selfCollisionTorqueFiltered.setZero(nDoF);
1178 arm->rtStatus.jointLimitTorqueFiltered.setZero(nDoF);
1180 arm->rtStatus.projImpedanceJointTorque.setZero(nDoF);
1181 arm->rtStatus.projSelfCollJointTorque.setZero(nDoF);
1182 arm->rtStatus.projJointLimJointTorque.setZero(nDoF);
1184 arm->rtStatus.impForceRatio = 0.0f;
1185 arm->rtStatus.impTorqueRatio = 0.0f;
1187 arm->rtStatus.selfCollNullSpace.resize(nDoF, nDoF);
1188 arm->rtStatus.selfCollNullSpace.setZero();
1189 arm->rtStatus.tempNullSpaceMatrix.resize(nDoF, nDoF);
1190 arm->rtStatus.tempNullSpaceMatrix.setZero();
1191 arm->rtStatus.jointLimNullSpace.resize(nDoF, nDoF);
1192 arm->rtStatus.jointLimNullSpace.setZero();
1194 arm->rtStatus.selfCollNullSpaceFiltered.resize(nDoF, nDoF);
1195 arm->rtStatus.selfCollNullSpaceFiltered.setZero();
1196 arm->rtStatus.jointLimNullSpaceFiltered.resize(nDoF, nDoF);
1197 arm->rtStatus.jointLimNullSpaceFiltered.setZero();
1199 arm->rtStatus.desiredNullSpace = 0.0;
1200 arm->rtStatus.selfCollisionNullSpaceWeights.setZero();
1201 arm->rtStatus.k1 = 0.0;
1202 arm->rtStatus.k2 = 0.0;
1203 arm->rtStatus.k3 = 0.0;
1204 arm->rtStatus.k4 = 0.0;
1205 arm->rtStatus.k1Lo = 0.0;
1206 arm->rtStatus.k2Lo = 0.0;
1207 arm->rtStatus.k3Lo = 0.0;
1208 arm->rtStatus.k4Lo = 0.0;
1209 arm->rtStatus.k1Hi = 0.0;
1210 arm->rtStatus.k2Hi = 0.0;
1211 arm->rtStatus.k3Hi = 0.0;
1212 arm->rtStatus.k4Hi = 0.0;
1214 arm->rtStatus.normalizedJacT.setZero(nDoF);
1216 arm->rtStatus.jointLimitData.resize(nDoF);
1217 arm->rtStatus.jointVel = 0.0;
1218 arm->rtStatus.jointInertia = 0.0;
1219 arm->rtStatus.localStiffnessJointLim = 0.0;
1220 arm->rtStatus.dampingJointLim = 0.0;
1222 arm->rtStatus.selfCollDataVec.resize(
1224 law::SafetyTaskspaceImpedanceController::RtStatus::selfCollisionData(nDoF));
1225 arm->rtStatus.evalData.resize(
1226 10, law::SafetyTaskspaceImpedanceController::RtStatus::selfCollisionData(nDoF));
1227 arm->rtStatus.evalDataIndex = 0;
1229 Eigen::Vector3d point1(0.0, 0.0, 0.0);
1230 Eigen::Vector3d point2(0.0, 0.0, 0.0);
1231 Eigen::Vector3d
norm(0.0, 0.0, 0.0);
1232 arm->rtStatus.activeDistPair.node1 =
"";
1233 arm->rtStatus.activeDistPair.node2 =
"";
1234 arm->rtStatus.activeDistPair.point1 = point1;
1235 arm->rtStatus.activeDistPair.point2 = point2;
1236 arm->rtStatus.activeDistPair.normalVec =
norm;
1237 arm->rtStatus.activeDistPair.minDistance = -1.0;
1239 arm->rtStatus.inertia.resize(nDoF, nDoF);
1240 arm->rtStatus.inertia.setZero();
1242 arm->rtStatus.inertiaInverse.resize(nDoF, nDoF);
1243 arm->rtStatus.inertiaInverse.setZero();
1245 arm->rtStatus.deltaT = 0.0;
1246 arm->rtStatus.rtSafe =
false;
1248 arm->rtStatus.currentForceTorque.setZero();
1250 arm->rtStatusInNonRT = arm->rtStatus;
1251 arm->bufferRtStatusToOnPublish.reinitAllBuffers(arm->rtStatus);
1252 arm->bufferRtStatusToNonRt.reinitAllBuffers(arm->rtStatus);
1253 arm->bufferRtStatusToUser.reinitAllBuffers(arm->rtStatus);
1255 for (
size_t i = 0; i < arm->pointsOnArm->size(); i++)
1257 arm->pointsOnArm->at(i) = -1;
1261 arm->rtStatus.collisionPairTime = 0.0;
1262 arm->rtStatus.preFilterTime = 0.0;
1263 arm->rtStatus.collisionTorqueTime = 0.0;
1264 arm->rtStatus.jointLimitTorqueTime = 0.0;
1265 arm->rtStatus.selfCollNullspaceTime = 0.0;
1266 arm->rtStatus.jointLimitNullspaceTime = 0.0;
1268 arm->rtStatus.collisionPairsNum = 0;
1269 arm->rtStatus.activeCollPairsNum = 0;
1272 arm->rtStatus.node1OnArm =
false;
1273 arm->rtStatus.node2OnArm =
false;
1274 arm->rtStatus.node1Index = 0;
1275 arm->rtStatus.node2Index = 0;
1277 arm->rtStatus.torsoJointValuef = 0.0f;
1278 arm->rtStatus.neck1JointValuef = 0.0f;
1279 arm->rtStatus.neck2JointValuef = 0.0f;
1280 arm->rtStatus.torsoJointValued = 0.0;
1281 arm->rtStatus.neck1JointValued = 0.0;
1282 arm->rtStatus.neck2JointValued = 0.0;
1283 arm->rtStatus.setActuatedJointValues.resize(18);
1284 arm->rtStatus.setActuatedJointValues.setZero();
1285 arm->rtStatus.getActuatedJointValues.resize(18);
1286 arm->rtStatus.setActuatedJointValues.setZero();
1289 arm->controller.preactivateInit(rns, arm->rtConfig, arm->rtStatus);
1297 for (
auto& pair :
limb)
1299 ARMARX_INFO <<
"rtPreActivateController for " << pair.first;
1301 userConfig.limbs.at(pair.first) = pair.second->rtConfig;
1308 for (
auto& pair :
limb)
1310 pair.second->rtReady.store(
false);
1311 pair.second->rtFirstRun.store(
true);