$search
00001 """autogenerated by genmsg_py from GetCheckerboardPoseRequest.msg. Do not edit.""" 00002 import roslib.message 00003 import struct 00004 00005 00006 class GetCheckerboardPoseRequest(roslib.message.Message): 00007 _md5sum = "f9dc7d7f2c73b6a404e26f1d03ad4ec2" 00008 _type = "approach_table_tools/GetCheckerboardPoseRequest" 00009 _has_header = False #flag to mark the presence of a Header object 00010 _full_text = """int32 corners_x 00011 int32 corners_y 00012 float32 spacing_x 00013 float32 spacing_y 00014 00015 """ 00016 __slots__ = ['corners_x','corners_y','spacing_x','spacing_y'] 00017 _slot_types = ['int32','int32','float32','float32'] 00018 00019 def __init__(self, *args, **kwds): 00020 """ 00021 Constructor. Any message fields that are implicitly/explicitly 00022 set to None will be assigned a default value. The recommend 00023 use is keyword arguments as this is more robust to future message 00024 changes. You cannot mix in-order arguments and keyword arguments. 00025 00026 The available fields are: 00027 corners_x,corners_y,spacing_x,spacing_y 00028 00029 @param args: complete set of field values, in .msg order 00030 @param kwds: use keyword arguments corresponding to message field names 00031 to set specific fields. 00032 """ 00033 if args or kwds: 00034 super(GetCheckerboardPoseRequest, self).__init__(*args, **kwds) 00035 #message fields cannot be None, assign default values for those that are 00036 if self.corners_x is None: 00037 self.corners_x = 0 00038 if self.corners_y is None: 00039 self.corners_y = 0 00040 if self.spacing_x is None: 00041 self.spacing_x = 0. 00042 if self.spacing_y is None: 00043 self.spacing_y = 0. 00044 else: 00045 self.corners_x = 0 00046 self.corners_y = 0 00047 self.spacing_x = 0. 00048 self.spacing_y = 0. 00049 00050 def _get_types(self): 00051 """ 00052 internal API method 00053 """ 00054 return self._slot_types 00055 00056 def serialize(self, buff): 00057 """ 00058 serialize message into buffer 00059 @param buff: buffer 00060 @type buff: StringIO 00061 """ 00062 try: 00063 _x = self 00064 buff.write(_struct_2i2f.pack(_x.corners_x, _x.corners_y, _x.spacing_x, _x.spacing_y)) 00065 except struct.error as se: self._check_types(se) 00066 except TypeError as te: self._check_types(te) 00067 00068 def deserialize(self, str): 00069 """ 00070 unpack serialized message in str into this message instance 00071 @param str: byte array of serialized message 00072 @type str: str 00073 """ 00074 try: 00075 end = 0 00076 _x = self 00077 start = end 00078 end += 16 00079 (_x.corners_x, _x.corners_y, _x.spacing_x, _x.spacing_y,) = _struct_2i2f.unpack(str[start:end]) 00080 return self 00081 except struct.error as e: 00082 raise roslib.message.DeserializationError(e) #most likely buffer underfill 00083 00084 00085 def serialize_numpy(self, buff, numpy): 00086 """ 00087 serialize message with numpy array types into buffer 00088 @param buff: buffer 00089 @type buff: StringIO 00090 @param numpy: numpy python module 00091 @type numpy module 00092 """ 00093 try: 00094 _x = self 00095 buff.write(_struct_2i2f.pack(_x.corners_x, _x.corners_y, _x.spacing_x, _x.spacing_y)) 00096 except struct.error as se: self._check_types(se) 00097 except TypeError as te: self._check_types(te) 00098 00099 def deserialize_numpy(self, str, numpy): 00100 """ 00101 unpack serialized message in str into this message instance using numpy for array types 00102 @param str: byte array of serialized message 00103 @type str: str 00104 @param numpy: numpy python module 00105 @type numpy: module 00106 """ 00107 try: 00108 end = 0 00109 _x = self 00110 start = end 00111 end += 16 00112 (_x.corners_x, _x.corners_y, _x.spacing_x, _x.spacing_y,) = _struct_2i2f.unpack(str[start:end]) 00113 return self 00114 except struct.error as e: 00115 raise roslib.message.DeserializationError(e) #most likely buffer underfill 00116 00117 _struct_I = roslib.message.struct_I 00118 _struct_2i2f = struct.Struct("<2i2f") 00119 """autogenerated by genmsg_py from GetCheckerboardPoseResponse.msg. Do not edit.""" 00120 import roslib.message 00121 import struct 00122 00123 import geometry_msgs.msg 00124 import std_msgs.msg 00125 00126 class GetCheckerboardPoseResponse(roslib.message.Message): 00127 _md5sum = "8c55f844039b710dbbf43d20e4fdbf71" 00128 _type = "approach_table_tools/GetCheckerboardPoseResponse" 00129 _has_header = False #flag to mark the presence of a Header object 00130 _full_text = """geometry_msgs/PoseStamped board_pose 00131 00132 00133 ================================================================================ 00134 MSG: geometry_msgs/PoseStamped 00135 # A Pose with reference coordinate frame and timestamp 00136 Header header 00137 Pose pose 00138 00139 ================================================================================ 00140 MSG: std_msgs/Header 00141 # Standard metadata for higher-level stamped data types. 00142 # This is generally used to communicate timestamped data 00143 # in a particular coordinate frame. 00144 # 00145 # sequence ID: consecutively increasing ID 00146 uint32 seq 00147 #Two-integer timestamp that is expressed as: 00148 # * stamp.secs: seconds (stamp_secs) since epoch 00149 # * stamp.nsecs: nanoseconds since stamp_secs 00150 # time-handling sugar is provided by the client library 00151 time stamp 00152 #Frame this data is associated with 00153 # 0: no frame 00154 # 1: global frame 00155 string frame_id 00156 00157 ================================================================================ 00158 MSG: geometry_msgs/Pose 00159 # A representation of pose in free space, composed of postion and orientation. 00160 Point position 00161 Quaternion orientation 00162 00163 ================================================================================ 00164 MSG: geometry_msgs/Point 00165 # This contains the position of a point in free space 00166 float64 x 00167 float64 y 00168 float64 z 00169 00170 ================================================================================ 00171 MSG: geometry_msgs/Quaternion 00172 # This represents an orientation in free space in quaternion form. 00173 00174 float64 x 00175 float64 y 00176 float64 z 00177 float64 w 00178 00179 """ 00180 __slots__ = ['board_pose'] 00181 _slot_types = ['geometry_msgs/PoseStamped'] 00182 00183 def __init__(self, *args, **kwds): 00184 """ 00185 Constructor. Any message fields that are implicitly/explicitly 00186 set to None will be assigned a default value. The recommend 00187 use is keyword arguments as this is more robust to future message 00188 changes. You cannot mix in-order arguments and keyword arguments. 00189 00190 The available fields are: 00191 board_pose 00192 00193 @param args: complete set of field values, in .msg order 00194 @param kwds: use keyword arguments corresponding to message field names 00195 to set specific fields. 00196 """ 00197 if args or kwds: 00198 super(GetCheckerboardPoseResponse, self).__init__(*args, **kwds) 00199 #message fields cannot be None, assign default values for those that are 00200 if self.board_pose is None: 00201 self.board_pose = geometry_msgs.msg.PoseStamped() 00202 else: 00203 self.board_pose = geometry_msgs.msg.PoseStamped() 00204 00205 def _get_types(self): 00206 """ 00207 internal API method 00208 """ 00209 return self._slot_types 00210 00211 def serialize(self, buff): 00212 """ 00213 serialize message into buffer 00214 @param buff: buffer 00215 @type buff: StringIO 00216 """ 00217 try: 00218 _x = self 00219 buff.write(_struct_3I.pack(_x.board_pose.header.seq, _x.board_pose.header.stamp.secs, _x.board_pose.header.stamp.nsecs)) 00220 _x = self.board_pose.header.frame_id 00221 length = len(_x) 00222 buff.write(struct.pack('<I%ss'%length, length, _x)) 00223 _x = self 00224 buff.write(_struct_7d.pack(_x.board_pose.pose.position.x, _x.board_pose.pose.position.y, _x.board_pose.pose.position.z, _x.board_pose.pose.orientation.x, _x.board_pose.pose.orientation.y, _x.board_pose.pose.orientation.z, _x.board_pose.pose.orientation.w)) 00225 except struct.error as se: self._check_types(se) 00226 except TypeError as te: self._check_types(te) 00227 00228 def deserialize(self, str): 00229 """ 00230 unpack serialized message in str into this message instance 00231 @param str: byte array of serialized message 00232 @type str: str 00233 """ 00234 try: 00235 if self.board_pose is None: 00236 self.board_pose = geometry_msgs.msg.PoseStamped() 00237 end = 0 00238 _x = self 00239 start = end 00240 end += 12 00241 (_x.board_pose.header.seq, _x.board_pose.header.stamp.secs, _x.board_pose.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end]) 00242 start = end 00243 end += 4 00244 (length,) = _struct_I.unpack(str[start:end]) 00245 start = end 00246 end += length 00247 self.board_pose.header.frame_id = str[start:end] 00248 _x = self 00249 start = end 00250 end += 56 00251 (_x.board_pose.pose.position.x, _x.board_pose.pose.position.y, _x.board_pose.pose.position.z, _x.board_pose.pose.orientation.x, _x.board_pose.pose.orientation.y, _x.board_pose.pose.orientation.z, _x.board_pose.pose.orientation.w,) = _struct_7d.unpack(str[start:end]) 00252 return self 00253 except struct.error as e: 00254 raise roslib.message.DeserializationError(e) #most likely buffer underfill 00255 00256 00257 def serialize_numpy(self, buff, numpy): 00258 """ 00259 serialize message with numpy array types into buffer 00260 @param buff: buffer 00261 @type buff: StringIO 00262 @param numpy: numpy python module 00263 @type numpy module 00264 """ 00265 try: 00266 _x = self 00267 buff.write(_struct_3I.pack(_x.board_pose.header.seq, _x.board_pose.header.stamp.secs, _x.board_pose.header.stamp.nsecs)) 00268 _x = self.board_pose.header.frame_id 00269 length = len(_x) 00270 buff.write(struct.pack('<I%ss'%length, length, _x)) 00271 _x = self 00272 buff.write(_struct_7d.pack(_x.board_pose.pose.position.x, _x.board_pose.pose.position.y, _x.board_pose.pose.position.z, _x.board_pose.pose.orientation.x, _x.board_pose.pose.orientation.y, _x.board_pose.pose.orientation.z, _x.board_pose.pose.orientation.w)) 00273 except struct.error as se: self._check_types(se) 00274 except TypeError as te: self._check_types(te) 00275 00276 def deserialize_numpy(self, str, numpy): 00277 """ 00278 unpack serialized message in str into this message instance using numpy for array types 00279 @param str: byte array of serialized message 00280 @type str: str 00281 @param numpy: numpy python module 00282 @type numpy: module 00283 """ 00284 try: 00285 if self.board_pose is None: 00286 self.board_pose = geometry_msgs.msg.PoseStamped() 00287 end = 0 00288 _x = self 00289 start = end 00290 end += 12 00291 (_x.board_pose.header.seq, _x.board_pose.header.stamp.secs, _x.board_pose.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end]) 00292 start = end 00293 end += 4 00294 (length,) = _struct_I.unpack(str[start:end]) 00295 start = end 00296 end += length 00297 self.board_pose.header.frame_id = str[start:end] 00298 _x = self 00299 start = end 00300 end += 56 00301 (_x.board_pose.pose.position.x, _x.board_pose.pose.position.y, _x.board_pose.pose.position.z, _x.board_pose.pose.orientation.x, _x.board_pose.pose.orientation.y, _x.board_pose.pose.orientation.z, _x.board_pose.pose.orientation.w,) = _struct_7d.unpack(str[start:end]) 00302 return self 00303 except struct.error as e: 00304 raise roslib.message.DeserializationError(e) #most likely buffer underfill 00305 00306 _struct_I = roslib.message.struct_I 00307 _struct_3I = struct.Struct("<3I") 00308 _struct_7d = struct.Struct("<7d") 00309 class GetCheckerboardPose(roslib.message.ServiceDefinition): 00310 _type = 'approach_table_tools/GetCheckerboardPose' 00311 _md5sum = 'ee43220cb6bda80cc0507ebe9e1c87c7' 00312 _request_class = GetCheckerboardPoseRequest 00313 _response_class = GetCheckerboardPoseResponse