57 getContext<CoupledInteractionGroupStatechartContext>();
58 float approachDistance = in.getApproachDistance();
59 float finalDistance = in.getFinalDistance();
61 ARMARX_LOG <<
"Incoming Table Pose " << *tablePose;
62 Eigen::Matrix4f approachoffset = Eigen::Matrix4f::Identity();
63 approachoffset(0, 3) = approachDistance;
64 Eigen::Matrix4f approachPoseGlobal =
65 tablePose->toGlobal(context->
getRobot())->toEigen() * approachoffset;
67 Eigen::Matrix4f finaloffset = Eigen::Matrix4f::Identity();
68 finaloffset(0, 3) = finalDistance;
69 Eigen::Matrix4f finalPoseGlobal =
70 tablePose->toGlobal(context->
getRobot())->toEigen() * finaloffset;
72 Eigen::Vector3f finalplatformPosVec(
73 finalPoseGlobal(0, 3), finalPoseGlobal(1, 3), getYawAngle(finalPoseGlobal) + M_PI_2);
75 Eigen::Vector3f approachplatformPosVec(approachPoseGlobal(0, 3),
76 approachPoseGlobal(1, 3),
77 getYawAngle(approachPoseGlobal) + M_PI_2);
79 std::vector<Vector3Ptr> approachPoses;
80 approachPoses.push_back(
new Vector3(approachplatformPosVec));
81 approachPoses.push_back(
new Vector3(finalplatformPosVec));
82 out.setApproachTablePose(approachPoses);
83 emitEvApproachPoseCalculated();
custom implementation of the StatechartContext for a statechart