SMACC2
Loading...
Searching...
No Matches
cb_circular_pivot_motion.hpp
Go to the documentation of this file.
1// Copyright 2021 RobosoftAI Inc.
2//
3// Licensed under the Apache License, Version 2.0 (the "License");
4// you may not use this file except in compliance with the License.
5// You may obtain a copy of the License at
6//
7// http://www.apache.org/licenses/LICENSE-2.0
8//
9// Unless required by applicable law or agreed to in writing, software
10// distributed under the License is distributed on an "AS IS" BASIS,
11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12// See the License for the specific language governing permissions and
13// limitations under the License.
14
15/*****************************************************************************************************************
16 *
17 * Authors: Pablo Inigo Blasco, Brett Aldrich
18 *
19 *****************************************************************************************************************/
20#pragma once
21
22#include <tf2/transform_datatypes.h>
24
26{
27// executes a circular trajectory of the tipLink around one axis defined
28// by the z-axis of the plaenePivotPose
30{
31public:
32 std::optional<double> angularSpeed_rad_s_;
33 std::optional<double> linearSpeed_m_s_;
34
35 // if not specified it would be used the current robot pose
36 std::optional<geometry_msgs::msg::Pose> relativeInitialPose_;
37
38 CbCircularPivotMotion(std::optional<std::string> tipLink = std::nullopt);
39
41 const geometry_msgs::msg::PoseStamped & planePivotPose, double deltaRadians,
42 std::optional<std::string> tipLink = std::nullopt);
43
45 const geometry_msgs::msg::PoseStamped & planePivotPose,
46 const geometry_msgs::msg::Pose & relativeInitialPose, double deltaRadians,
47 std::optional<std::string> tipLink = std::nullopt);
48
49 virtual void generateTrajectory() override;
50
51 virtual void createMarkers() override;
52
53protected:
54 // the rotation axis (z-axis) and the center of rotation in the space
55 geometry_msgs::msg::PoseStamped planePivotPose_;
56
58
59private:
61};
62
63} // namespace cl_move_group_interface
std::optional< geometry_msgs::msg::Pose > relativeInitialPose_