$search
00001 """autogenerated by genmsg_py from EECartImpedResult.msg. Do not edit.""" 00002 import roslib.message 00003 import struct 00004 00005 import geometry_msgs.msg 00006 import roslib.rostime 00007 import ee_cart_imped_msgs.msg 00008 import std_msgs.msg 00009 00010 class EECartImpedResult(roslib.message.Message): 00011 _md5sum = "947387aff8267ef3d7c884c07783eb7d" 00012 _type = "ee_cart_imped_msgs/EECartImpedResult" 00013 _has_header = True #flag to mark the presence of a Header object 00014 _full_text = """# ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ====== 00015 #result definition 00016 #whether it was successful 00017 #the pose and force we ended with 00018 Header header 00019 bool success 00020 ee_cart_imped_msgs/StiffPoint desired 00021 geometry_msgs/Pose actual_pose 00022 float64 effort_sq_error 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 MSG: ee_cart_imped_msgs/StiffPoint 00044 Header header 00045 #The pose to achieve in the stiffness directions 00046 geometry_msgs/Pose pose 00047 #Wrench or stiffness for each dimension 00048 geometry_msgs/Wrench wrench_or_stiffness 00049 #The following are True if a force/torque should 00050 #be exerted and False if a stiffness should be used. 00051 bool isForceX 00052 bool isForceY 00053 bool isForceZ 00054 bool isTorqueX 00055 bool isTorqueY 00056 bool isTorqueZ 00057 #The time from the start of the trajectory that this 00058 #point should be achieved. 00059 duration time_from_start 00060 ================================================================================ 00061 MSG: geometry_msgs/Pose 00062 # A representation of pose in free space, composed of postion and orientation. 00063 Point position 00064 Quaternion orientation 00065 00066 ================================================================================ 00067 MSG: geometry_msgs/Point 00068 # This contains the position of a point in free space 00069 float64 x 00070 float64 y 00071 float64 z 00072 00073 ================================================================================ 00074 MSG: geometry_msgs/Quaternion 00075 # This represents an orientation in free space in quaternion form. 00076 00077 float64 x 00078 float64 y 00079 float64 z 00080 float64 w 00081 00082 ================================================================================ 00083 MSG: geometry_msgs/Wrench 00084 # This represents force in free space, seperated into 00085 # it's linear and angular parts. 00086 Vector3 force 00087 Vector3 torque 00088 00089 ================================================================================ 00090 MSG: geometry_msgs/Vector3 00091 # This represents a vector in free space. 00092 00093 float64 x 00094 float64 y 00095 float64 z 00096 """ 00097 __slots__ = ['header','success','desired','actual_pose','effort_sq_error'] 00098 _slot_types = ['Header','bool','ee_cart_imped_msgs/StiffPoint','geometry_msgs/Pose','float64'] 00099 00100 def __init__(self, *args, **kwds): 00101 """ 00102 Constructor. Any message fields that are implicitly/explicitly 00103 set to None will be assigned a default value. The recommend 00104 use is keyword arguments as this is more robust to future message 00105 changes. You cannot mix in-order arguments and keyword arguments. 00106 00107 The available fields are: 00108 header,success,desired,actual_pose,effort_sq_error 00109 00110 @param args: complete set of field values, in .msg order 00111 @param kwds: use keyword arguments corresponding to message field names 00112 to set specific fields. 00113 """ 00114 if args or kwds: 00115 super(EECartImpedResult, self).__init__(*args, **kwds) 00116 #message fields cannot be None, assign default values for those that are 00117 if self.header is None: 00118 self.header = std_msgs.msg._Header.Header() 00119 if self.success is None: 00120 self.success = False 00121 if self.desired is None: 00122 self.desired = ee_cart_imped_msgs.msg.StiffPoint() 00123 if self.actual_pose is None: 00124 self.actual_pose = geometry_msgs.msg.Pose() 00125 if self.effort_sq_error is None: 00126 self.effort_sq_error = 0. 00127 else: 00128 self.header = std_msgs.msg._Header.Header() 00129 self.success = False 00130 self.desired = ee_cart_imped_msgs.msg.StiffPoint() 00131 self.actual_pose = geometry_msgs.msg.Pose() 00132 self.effort_sq_error = 0. 00133 00134 def _get_types(self): 00135 """ 00136 internal API method 00137 """ 00138 return self._slot_types 00139 00140 def serialize(self, buff): 00141 """ 00142 serialize message into buffer 00143 @param buff: buffer 00144 @type buff: StringIO 00145 """ 00146 try: 00147 _x = self 00148 buff.write(_struct_3I.pack(_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs)) 00149 _x = self.header.frame_id 00150 length = len(_x) 00151 buff.write(struct.pack('<I%ss'%length, length, _x)) 00152 _x = self 00153 buff.write(_struct_B3I.pack(_x.success, _x.desired.header.seq, _x.desired.header.stamp.secs, _x.desired.header.stamp.nsecs)) 00154 _x = self.desired.header.frame_id 00155 length = len(_x) 00156 buff.write(struct.pack('<I%ss'%length, length, _x)) 00157 _x = self 00158 buff.write(_struct_13d6B2i8d.pack(_x.desired.pose.position.x, _x.desired.pose.position.y, _x.desired.pose.position.z, _x.desired.pose.orientation.x, _x.desired.pose.orientation.y, _x.desired.pose.orientation.z, _x.desired.pose.orientation.w, _x.desired.wrench_or_stiffness.force.x, _x.desired.wrench_or_stiffness.force.y, _x.desired.wrench_or_stiffness.force.z, _x.desired.wrench_or_stiffness.torque.x, _x.desired.wrench_or_stiffness.torque.y, _x.desired.wrench_or_stiffness.torque.z, _x.desired.isForceX, _x.desired.isForceY, _x.desired.isForceZ, _x.desired.isTorqueX, _x.desired.isTorqueY, _x.desired.isTorqueZ, _x.desired.time_from_start.secs, _x.desired.time_from_start.nsecs, _x.actual_pose.position.x, _x.actual_pose.position.y, _x.actual_pose.position.z, _x.actual_pose.orientation.x, _x.actual_pose.orientation.y, _x.actual_pose.orientation.z, _x.actual_pose.orientation.w, _x.effort_sq_error)) 00159 except struct.error as se: self._check_types(se) 00160 except TypeError as te: self._check_types(te) 00161 00162 def deserialize(self, str): 00163 """ 00164 unpack serialized message in str into this message instance 00165 @param str: byte array of serialized message 00166 @type str: str 00167 """ 00168 try: 00169 if self.header is None: 00170 self.header = std_msgs.msg._Header.Header() 00171 if self.desired is None: 00172 self.desired = ee_cart_imped_msgs.msg.StiffPoint() 00173 if self.actual_pose is None: 00174 self.actual_pose = geometry_msgs.msg.Pose() 00175 end = 0 00176 _x = self 00177 start = end 00178 end += 12 00179 (_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end]) 00180 start = end 00181 end += 4 00182 (length,) = _struct_I.unpack(str[start:end]) 00183 start = end 00184 end += length 00185 self.header.frame_id = str[start:end] 00186 _x = self 00187 start = end 00188 end += 13 00189 (_x.success, _x.desired.header.seq, _x.desired.header.stamp.secs, _x.desired.header.stamp.nsecs,) = _struct_B3I.unpack(str[start:end]) 00190 self.success = bool(self.success) 00191 start = end 00192 end += 4 00193 (length,) = _struct_I.unpack(str[start:end]) 00194 start = end 00195 end += length 00196 self.desired.header.frame_id = str[start:end] 00197 _x = self 00198 start = end 00199 end += 182 00200 (_x.desired.pose.position.x, _x.desired.pose.position.y, _x.desired.pose.position.z, _x.desired.pose.orientation.x, _x.desired.pose.orientation.y, _x.desired.pose.orientation.z, _x.desired.pose.orientation.w, _x.desired.wrench_or_stiffness.force.x, _x.desired.wrench_or_stiffness.force.y, _x.desired.wrench_or_stiffness.force.z, _x.desired.wrench_or_stiffness.torque.x, _x.desired.wrench_or_stiffness.torque.y, _x.desired.wrench_or_stiffness.torque.z, _x.desired.isForceX, _x.desired.isForceY, _x.desired.isForceZ, _x.desired.isTorqueX, _x.desired.isTorqueY, _x.desired.isTorqueZ, _x.desired.time_from_start.secs, _x.desired.time_from_start.nsecs, _x.actual_pose.position.x, _x.actual_pose.position.y, _x.actual_pose.position.z, _x.actual_pose.orientation.x, _x.actual_pose.orientation.y, _x.actual_pose.orientation.z, _x.actual_pose.orientation.w, _x.effort_sq_error,) = _struct_13d6B2i8d.unpack(str[start:end]) 00201 self.desired.isForceX = bool(self.desired.isForceX) 00202 self.desired.isForceY = bool(self.desired.isForceY) 00203 self.desired.isForceZ = bool(self.desired.isForceZ) 00204 self.desired.isTorqueX = bool(self.desired.isTorqueX) 00205 self.desired.isTorqueY = bool(self.desired.isTorqueY) 00206 self.desired.isTorqueZ = bool(self.desired.isTorqueZ) 00207 return self 00208 except struct.error as e: 00209 raise roslib.message.DeserializationError(e) #most likely buffer underfill 00210 00211 00212 def serialize_numpy(self, buff, numpy): 00213 """ 00214 serialize message with numpy array types into buffer 00215 @param buff: buffer 00216 @type buff: StringIO 00217 @param numpy: numpy python module 00218 @type numpy module 00219 """ 00220 try: 00221 _x = self 00222 buff.write(_struct_3I.pack(_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs)) 00223 _x = self.header.frame_id 00224 length = len(_x) 00225 buff.write(struct.pack('<I%ss'%length, length, _x)) 00226 _x = self 00227 buff.write(_struct_B3I.pack(_x.success, _x.desired.header.seq, _x.desired.header.stamp.secs, _x.desired.header.stamp.nsecs)) 00228 _x = self.desired.header.frame_id 00229 length = len(_x) 00230 buff.write(struct.pack('<I%ss'%length, length, _x)) 00231 _x = self 00232 buff.write(_struct_13d6B2i8d.pack(_x.desired.pose.position.x, _x.desired.pose.position.y, _x.desired.pose.position.z, _x.desired.pose.orientation.x, _x.desired.pose.orientation.y, _x.desired.pose.orientation.z, _x.desired.pose.orientation.w, _x.desired.wrench_or_stiffness.force.x, _x.desired.wrench_or_stiffness.force.y, _x.desired.wrench_or_stiffness.force.z, _x.desired.wrench_or_stiffness.torque.x, _x.desired.wrench_or_stiffness.torque.y, _x.desired.wrench_or_stiffness.torque.z, _x.desired.isForceX, _x.desired.isForceY, _x.desired.isForceZ, _x.desired.isTorqueX, _x.desired.isTorqueY, _x.desired.isTorqueZ, _x.desired.time_from_start.secs, _x.desired.time_from_start.nsecs, _x.actual_pose.position.x, _x.actual_pose.position.y, _x.actual_pose.position.z, _x.actual_pose.orientation.x, _x.actual_pose.orientation.y, _x.actual_pose.orientation.z, _x.actual_pose.orientation.w, _x.effort_sq_error)) 00233 except struct.error as se: self._check_types(se) 00234 except TypeError as te: self._check_types(te) 00235 00236 def deserialize_numpy(self, str, numpy): 00237 """ 00238 unpack serialized message in str into this message instance using numpy for array types 00239 @param str: byte array of serialized message 00240 @type str: str 00241 @param numpy: numpy python module 00242 @type numpy: module 00243 """ 00244 try: 00245 if self.header is None: 00246 self.header = std_msgs.msg._Header.Header() 00247 if self.desired is None: 00248 self.desired = ee_cart_imped_msgs.msg.StiffPoint() 00249 if self.actual_pose is None: 00250 self.actual_pose = geometry_msgs.msg.Pose() 00251 end = 0 00252 _x = self 00253 start = end 00254 end += 12 00255 (_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end]) 00256 start = end 00257 end += 4 00258 (length,) = _struct_I.unpack(str[start:end]) 00259 start = end 00260 end += length 00261 self.header.frame_id = str[start:end] 00262 _x = self 00263 start = end 00264 end += 13 00265 (_x.success, _x.desired.header.seq, _x.desired.header.stamp.secs, _x.desired.header.stamp.nsecs,) = _struct_B3I.unpack(str[start:end]) 00266 self.success = bool(self.success) 00267 start = end 00268 end += 4 00269 (length,) = _struct_I.unpack(str[start:end]) 00270 start = end 00271 end += length 00272 self.desired.header.frame_id = str[start:end] 00273 _x = self 00274 start = end 00275 end += 182 00276 (_x.desired.pose.position.x, _x.desired.pose.position.y, _x.desired.pose.position.z, _x.desired.pose.orientation.x, _x.desired.pose.orientation.y, _x.desired.pose.orientation.z, _x.desired.pose.orientation.w, _x.desired.wrench_or_stiffness.force.x, _x.desired.wrench_or_stiffness.force.y, _x.desired.wrench_or_stiffness.force.z, _x.desired.wrench_or_stiffness.torque.x, _x.desired.wrench_or_stiffness.torque.y, _x.desired.wrench_or_stiffness.torque.z, _x.desired.isForceX, _x.desired.isForceY, _x.desired.isForceZ, _x.desired.isTorqueX, _x.desired.isTorqueY, _x.desired.isTorqueZ, _x.desired.time_from_start.secs, _x.desired.time_from_start.nsecs, _x.actual_pose.position.x, _x.actual_pose.position.y, _x.actual_pose.position.z, _x.actual_pose.orientation.x, _x.actual_pose.orientation.y, _x.actual_pose.orientation.z, _x.actual_pose.orientation.w, _x.effort_sq_error,) = _struct_13d6B2i8d.unpack(str[start:end]) 00277 self.desired.isForceX = bool(self.desired.isForceX) 00278 self.desired.isForceY = bool(self.desired.isForceY) 00279 self.desired.isForceZ = bool(self.desired.isForceZ) 00280 self.desired.isTorqueX = bool(self.desired.isTorqueX) 00281 self.desired.isTorqueY = bool(self.desired.isTorqueY) 00282 self.desired.isTorqueZ = bool(self.desired.isTorqueZ) 00283 return self 00284 except struct.error as e: 00285 raise roslib.message.DeserializationError(e) #most likely buffer underfill 00286 00287 _struct_I = roslib.message.struct_I 00288 _struct_3I = struct.Struct("<3I") 00289 _struct_B3I = struct.Struct("<B3I") 00290 _struct_13d6B2i8d = struct.Struct("<13d6B2i8d")