3#include <Eigen/Geometry>
5#include <SimoxUtility/math/convert/deg_to_rad.h>
29 RotateTowards::relativeTarget(
const Base::SpecializedMainInput& in)
31 const auto robotPoseOpt =
34 <<
"Could not get global pose for robot " <<
QUOTED(properties_.
robotName);
36 const auto& robotPose = robotPoseOpt.value();
37 const auto robotPoseIsometry = Eigen::Isometry3f{robotPose};
38 auto newPose = robotPoseIsometry.inverse() *
40 robotPose.translation(), in.parameters.targetPositionGlobal)};
50 defaultParams.targetPositionGlobal = Eigen::Vector3f{0.F, 0.F, 0.F};
51 defaultParams.navigatingSkillParams.globalPlanningAlgorithm =
52 arondto::GlobalPlanningAlgorithm::Point2Point;
56 .description =
"Rotate so that the robot is facing the specified global position",
57 .rootProfileDefaults = defaultParams.toAron(),
59 .parametersType = ParamType::ToAronType()};
static DateTime Now()
Current time on the virtual clock.
std::optional< RobotState::Pose > queryGlobalPose(const std::string &robotName, const armem::Time ×tamp) const
static Duration Minutes(std::int64_t minutes)
Constructs a duration in minutes.
static arondto::NavigatingSkillParams DefaultSkillDescription()
RotateTowards(const NavigatingSkillHelper::Properties &helperProperties, const NavigatingSkillHelper::Services &helperSrv, const Properties &props, const Services &srv)
static armarx::skills::SkillDescription DefaultSkillDescription()
NavigateRelativeSkill< arondto::RotateTowardsParams > Base
#define ARMARX_CHECK(expression)
Shortcut for ARMARX_CHECK_EXPRESSION.
const std::string RotateTowards
Eigen::Matrix4f getRobotPoseAtXOrientedTowardsY(const Eigen::Vector3f &x, const Eigen::Vector3f &y)
armem::robot_state::VirtualRobotReader & robotReader