30 SimpleSpecializedSkill(
GetSkillDescription()), homePoseConfiguration_(homePoseConfiguration)
39 defaultParams.disabledJoints = {
"LeftHandFingers",
43 "LeftHandThumbCircumduction",
44 "RightHandThumbCircumduction",
45 "LeftHandThumbFlexion",
46 "RightHandThumbFlexion"};
48 std::stringstream desc;
49 desc <<
"Move all joints to a natural idle position that also allows "
50 "safe movement and safe bus crashes."
52 <<
"The `enable*` parameters can be used to enable/disable movement for different "
53 "body parts of the robot.";
57 .description = desc.str(),
58 .rootProfileDefaults = defaultParams.toAron(),
60 .parametersType = ParamType::ToAronType(),
67 const ::armarx::skills::SkillID moveToConfigurationSkillId{
72 const ::armarx::skills::SkillID openHandSkillId{
76 std::unique_ptr<armarx::skills::SkillExecutionHandle> handleLeftHand;
77 if (in.parameters.enableLeftHand)
81 using Parameters = arondto::ShapeHandParams;
85 [](Parameters& params)
87 params.shapeName =
"Open";
88 params.hand = armarx::control::skills::arondto::Hand::Left;
93 std::unique_ptr<armarx::skills::SkillExecutionHandle> handleRightHand;
94 if (in.parameters.enableRightHand)
98 using Parameters = arondto::ShapeHandParams;
102 [](Parameters& params)
104 params.shapeName =
"Open";
105 params.hand = armarx::control::skills::arondto::Hand::Right;
110 const auto handleHomePose = [&]
113 armarx::control::skills::arondto::MoveJointsToNamedConfigurationParams;
116 moveToConfigurationSkillId,
117 [&](Parameters& subParams)
119 subParams.configuration = homePoseConfiguration_;
121 subParams.enableHead =
123 subParams.enableLeftHand =
false;
124 subParams.enableRightHand =
false;
132 armarx::skills::util::JoinAllResult result;
133 if (in.parameters.enableLeftHand and in.parameters.enableRightHand)
138 if (in.parameters.enableLeftHand)
142 else if (in.parameters.enableRightHand)
154 ARMARX_WARNING <<
"The skills " << result.failedSkillIDs() <<
" failed";
A result struct for th main method of a skill.