rapid
A ROS robotics library.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Pages
pr2.h
Go to the documentation of this file.
1 #ifndef _RAPID_PR2_PR2_H_
2 #define _RAPID_PR2_PR2_H_
3 
9 #include "rapid_sound/sound.h"
10 #include "rapid_viz/markers.h"
11 
12 namespace rapid {
13 namespace pr2 {
14 // Class for controlling a PR2.
15 //
16 // To use a real PR2:
17 // Pr2* pr2 = BuildReal(node_handle);
18 // pr2->left_arm()->MoveToPoseGoal(...);
19 // delete pr2;
20 class Pr2 {
21  public:
22  // The PR2 claims ownership of pointers passed in.
30  ~Pr2();
31 
32  // Accessors
40 
41  private:
42  rapid::manipulation::ArmInterface* const left_arm_;
43  rapid::manipulation::ArmInterface* const right_arm_;
44  rapid::manipulation::GripperInterface* const left_gripper_;
45  rapid::manipulation::GripperInterface* const right_gripper_;
47  rapid::sound::SoundInterface* const sound_;
49 };
50 
51 // Factory function for building a PR2 object for a real PR2.
52 // Ownership of the Pr2 pointer is transferred to the caller.
53 Pr2* BuildReal(ros::NodeHandle& nh);
54 } // namespace pr2
55 } // namespace rapid
56 #endif // _RAPID_PR2_PR2_H_
rapid::manipulation::ArmInterface * right_arm()
Pr2 * BuildReal(ros::NodeHandle &nh)
rapid::manipulation::GripperInterface * left_gripper()
Pr2(rapid::manipulation::ArmInterface *left_arm, rapid::manipulation::ArmInterface *right_arm, rapid::manipulation::GripperInterface *left_gripper, rapid::manipulation::GripperInterface *right_gripper, rapid::manipulation::HeadInterface *head, rapid::sound::SoundInterface *sound, rapid::manipulation::TuckArmsInterface *tuck_arms)
rapid::sound::SoundInterface * sound()
rapid::manipulation::ArmInterface * left_arm()
rapid::manipulation::GripperInterface * right_gripper()
rapid::manipulation::TuckArmsInterface * tuck_arms()
rapid::manipulation::HeadInterface * head()