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