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