Go to the documentation of this file.00001 #ifndef _ROS_manipulation_msgs_ManipulationPhase_h
00002 #define _ROS_manipulation_msgs_ManipulationPhase_h
00003
00004 #include <stdint.h>
00005 #include <string.h>
00006 #include <stdlib.h>
00007 #include "ros/msg.h"
00008
00009 namespace manipulation_msgs
00010 {
00011
00012 class ManipulationPhase : public ros::Msg
00013 {
00014 public:
00015 int32_t phase;
00016 enum { CHECKING_FEASIBILITY = 0 };
00017 enum { MOVING_TO_PREGRASP = 1 };
00018 enum { MOVING_TO_GRASP = 2 };
00019 enum { CLOSING = 3 };
00020 enum { ADJUSTING_GRASP = 4 };
00021 enum { LIFTING = 5 };
00022 enum { MOVING_WITH_OBJECT = 6 };
00023 enum { MOVING_TO_PLACE = 7 };
00024 enum { PLACING = 8 };
00025 enum { OPENING = 9 };
00026 enum { RETREATING = 10 };
00027 enum { MOVING_WITHOUT_OBJECT = 11 };
00028 enum { SHAKING = 12 };
00029 enum { SUCCEEDED = 13 };
00030 enum { FAILED = 14 };
00031 enum { ABORTED = 15 };
00032 enum { HOLDING_OBJECT = 16 };
00033
00034 virtual int serialize(unsigned char *outbuffer) const
00035 {
00036 int offset = 0;
00037 union {
00038 int32_t real;
00039 uint32_t base;
00040 } u_phase;
00041 u_phase.real = this->phase;
00042 *(outbuffer + offset + 0) = (u_phase.base >> (8 * 0)) & 0xFF;
00043 *(outbuffer + offset + 1) = (u_phase.base >> (8 * 1)) & 0xFF;
00044 *(outbuffer + offset + 2) = (u_phase.base >> (8 * 2)) & 0xFF;
00045 *(outbuffer + offset + 3) = (u_phase.base >> (8 * 3)) & 0xFF;
00046 offset += sizeof(this->phase);
00047 return offset;
00048 }
00049
00050 virtual int deserialize(unsigned char *inbuffer)
00051 {
00052 int offset = 0;
00053 union {
00054 int32_t real;
00055 uint32_t base;
00056 } u_phase;
00057 u_phase.base = 0;
00058 u_phase.base |= ((uint32_t) (*(inbuffer + offset + 0))) << (8 * 0);
00059 u_phase.base |= ((uint32_t) (*(inbuffer + offset + 1))) << (8 * 1);
00060 u_phase.base |= ((uint32_t) (*(inbuffer + offset + 2))) << (8 * 2);
00061 u_phase.base |= ((uint32_t) (*(inbuffer + offset + 3))) << (8 * 3);
00062 this->phase = u_phase.real;
00063 offset += sizeof(this->phase);
00064 return offset;
00065 }
00066
00067 const char * getType(){ return "manipulation_msgs/ManipulationPhase"; };
00068 const char * getMD5(){ return "2c824c847a35d8fd9277d324a3723378"; };
00069
00070 };
00071
00072 }
00073 #endif