Flexiv RDK APIs  2.1
work_coord.hpp
Go to the documentation of this file.
1 
6 #ifndef FLEXIV_RDK_WORK_COORD_HPP_
7 #define FLEXIV_RDK_WORK_COORD_HPP_
8 
9 #include "robot.hpp"
10 
11 namespace flexiv::rdk {
12 
18 class WorkCoord
19 {
20 public:
26  WorkCoord(const Robot& robot);
27  virtual ~WorkCoord();
28 
35  std::vector<std::string> list() const;
36 
44  bool exist(const std::string& name) const;
45 
55  std::array<double, kPoseSize> pose(const std::string& name) const;
56 
70  void Add(const std::string& name, const std::array<double, kPoseSize>& pose);
71 
85  void Update(const std::string& name, const std::array<double, kPoseSize>& pose);
86 
96  void Remove(const std::string& name);
97 
98 private:
99  class Impl;
100  std::unique_ptr<Impl> pimpl_;
101 };
102 
103 } /* namespace flexiv::rdk */
104 
105 #endif /* FLEXIV_RDK_WORK_COORD_HPP_ */
Main interface to control the robot, containing several function categories and background services.
Definition: robot.hpp:24
Interface to manage work coordinates of the robot. All updates take effect immediately without a powe...
Definition: work_coord.hpp:19
WorkCoord(const Robot &robot)
[Non-blocking] Instantiate the work coordinate interface.
void Add(const std::string &name, const std::array< double, kPoseSize > &pose)
[Blocking] Add a new work coordinate with user-specified parameters.
void Update(const std::string &name, const std::array< double, kPoseSize > &pose)
[Blocking] Update the pose of an existing work coordinate.
std::vector< std::string > list() const
[Blocking] A list of all configured work coordinates.
void Remove(const std::string &name)
[Blocking] Remove an existing work coordinate.
std::array< double, kPoseSize > pose(const std::string &name) const
[Blocking] Pose of an existing work coordinate.
bool exist(const std::string &name) const
[Blocking] Whether the specified work coordinate already exists.