00001 """autogenerated by genmsg_py from ConfigAction.msg. Do not edit."""
00002 import roslib.message
00003 import struct
00004
00005 import roslib.rostime
00006 import actionlib_msgs.msg
00007 import joint_states_settler.msg
00008 import std_msgs.msg
00009
00010 class ConfigAction(roslib.message.Message):
00011 _md5sum = "baa9ae56369a6c832695f8fd10a504f5"
00012 _type = "joint_states_settler/ConfigAction"
00013 _has_header = False
00014 _full_text = """
00015 ConfigActionGoal action_goal
00016 ConfigActionResult action_result
00017 ConfigActionFeedback action_feedback
00018
00019 ================================================================================
00020 MSG: joint_states_settler/ConfigActionGoal
00021
00022 Header header
00023 actionlib_msgs/GoalID goal_id
00024 ConfigGoal goal
00025
00026 ================================================================================
00027 MSG: std_msgs/Header
00028 # Standard metadata for higher-level stamped data types.
00029 # This is generally used to communicate timestamped data
00030 # in a particular coordinate frame.
00031 #
00032 # sequence ID: consecutively increasing ID
00033 uint32 seq
00034 #Two-integer timestamp that is expressed as:
00035 # * stamp.secs: seconds (stamp_secs) since epoch
00036 # * stamp.nsecs: nanoseconds since stamp_secs
00037 # time-handling sugar is provided by the client library
00038 time stamp
00039 #Frame this data is associated with
00040 # 0: no frame
00041 # 1: global frame
00042 string frame_id
00043
00044 ================================================================================
00045 MSG: actionlib_msgs/GoalID
00046 # The stamp should store the time at which this goal was requested.
00047 # It is used by an action server when it tries to preempt all
00048 # goals that were requested before a certain time
00049 time stamp
00050
00051 # The id provides a way to associate feedback and
00052 # result message with specific goal requests. The id
00053 # specified must be unique.
00054 string id
00055
00056
00057 ================================================================================
00058 MSG: joint_states_settler/ConfigGoal
00059 string[] joint_names # Names of the joints we're waiting to settle
00060 float64[] tolerances # Tolerance on each of the specified joints
00061 duration max_step # The maximum timestep between two elements in an interval
00062 uint32 cache_size # The size of our cache when searching for an interval
00063
00064 ================================================================================
00065 MSG: joint_states_settler/ConfigActionResult
00066
00067 Header header
00068 actionlib_msgs/GoalStatus status
00069 ConfigResult result
00070
00071 ================================================================================
00072 MSG: actionlib_msgs/GoalStatus
00073 GoalID goal_id
00074 uint8 status
00075 uint8 PENDING = 0 # The goal has yet to be processed by the action server
00076 uint8 ACTIVE = 1 # The goal is currently being processed by the action server
00077 uint8 PREEMPTED = 2 # The goal received a cancel request after it started executing
00078 # and has since completed its execution (Terminal State)
00079 uint8 SUCCEEDED = 3 # The goal was achieved successfully by the action server (Terminal State)
00080 uint8 ABORTED = 4 # The goal was aborted during execution by the action server due
00081 # to some failure (Terminal State)
00082 uint8 REJECTED = 5 # The goal was rejected by the action server without being processed,
00083 # because the goal was unattainable or invalid (Terminal State)
00084 uint8 PREEMPTING = 6 # The goal received a cancel request after it started executing
00085 # and has not yet completed execution
00086 uint8 RECALLING = 7 # The goal received a cancel request before it started executing,
00087 # but the action server has not yet confirmed that the goal is canceled
00088 uint8 RECALLED = 8 # The goal received a cancel request before it started executing
00089 # and was successfully cancelled (Terminal State)
00090 uint8 LOST = 9 # An action client can determine that a goal is LOST. This should not be
00091 # sent over the wire by an action server
00092
00093 #Allow for the user to associate a string with GoalStatus for debugging
00094 string text
00095
00096
00097 ================================================================================
00098 MSG: joint_states_settler/ConfigResult
00099
00100 ================================================================================
00101 MSG: joint_states_settler/ConfigActionFeedback
00102
00103 Header header
00104 actionlib_msgs/GoalStatus status
00105 ConfigFeedback feedback
00106
00107 ================================================================================
00108 MSG: joint_states_settler/ConfigFeedback
00109
00110 """
00111 __slots__ = ['action_goal','action_result','action_feedback']
00112 _slot_types = ['joint_states_settler/ConfigActionGoal','joint_states_settler/ConfigActionResult','joint_states_settler/ConfigActionFeedback']
00113
00114 def __init__(self, *args, **kwds):
00115 """
00116 Constructor. Any message fields that are implicitly/explicitly
00117 set to None will be assigned a default value. The recommend
00118 use is keyword arguments as this is more robust to future message
00119 changes. You cannot mix in-order arguments and keyword arguments.
00120
00121 The available fields are:
00122 action_goal,action_result,action_feedback
00123
00124 @param args: complete set of field values, in .msg order
00125 @param kwds: use keyword arguments corresponding to message field names
00126 to set specific fields.
00127 """
00128 if args or kwds:
00129 super(ConfigAction, self).__init__(*args, **kwds)
00130
00131 if self.action_goal is None:
00132 self.action_goal = joint_states_settler.msg.ConfigActionGoal()
00133 if self.action_result is None:
00134 self.action_result = joint_states_settler.msg.ConfigActionResult()
00135 if self.action_feedback is None:
00136 self.action_feedback = joint_states_settler.msg.ConfigActionFeedback()
00137 else:
00138 self.action_goal = joint_states_settler.msg.ConfigActionGoal()
00139 self.action_result = joint_states_settler.msg.ConfigActionResult()
00140 self.action_feedback = joint_states_settler.msg.ConfigActionFeedback()
00141
00142 def _get_types(self):
00143 """
00144 internal API method
00145 """
00146 return self._slot_types
00147
00148 def serialize(self, buff):
00149 """
00150 serialize message into buffer
00151 @param buff: buffer
00152 @type buff: StringIO
00153 """
00154 try:
00155 _x = self
00156 buff.write(_struct_3I.pack(_x.action_goal.header.seq, _x.action_goal.header.stamp.secs, _x.action_goal.header.stamp.nsecs))
00157 _x = self.action_goal.header.frame_id
00158 length = len(_x)
00159 buff.write(struct.pack('<I%ss'%length, length, _x))
00160 _x = self
00161 buff.write(_struct_2I.pack(_x.action_goal.goal_id.stamp.secs, _x.action_goal.goal_id.stamp.nsecs))
00162 _x = self.action_goal.goal_id.id
00163 length = len(_x)
00164 buff.write(struct.pack('<I%ss'%length, length, _x))
00165 length = len(self.action_goal.goal.joint_names)
00166 buff.write(_struct_I.pack(length))
00167 for val1 in self.action_goal.goal.joint_names:
00168 length = len(val1)
00169 buff.write(struct.pack('<I%ss'%length, length, val1))
00170 length = len(self.action_goal.goal.tolerances)
00171 buff.write(_struct_I.pack(length))
00172 pattern = '<%sd'%length
00173 buff.write(struct.pack(pattern, *self.action_goal.goal.tolerances))
00174 _x = self
00175 buff.write(_struct_2i4I.pack(_x.action_goal.goal.max_step.secs, _x.action_goal.goal.max_step.nsecs, _x.action_goal.goal.cache_size, _x.action_result.header.seq, _x.action_result.header.stamp.secs, _x.action_result.header.stamp.nsecs))
00176 _x = self.action_result.header.frame_id
00177 length = len(_x)
00178 buff.write(struct.pack('<I%ss'%length, length, _x))
00179 _x = self
00180 buff.write(_struct_2I.pack(_x.action_result.status.goal_id.stamp.secs, _x.action_result.status.goal_id.stamp.nsecs))
00181 _x = self.action_result.status.goal_id.id
00182 length = len(_x)
00183 buff.write(struct.pack('<I%ss'%length, length, _x))
00184 buff.write(_struct_B.pack(self.action_result.status.status))
00185 _x = self.action_result.status.text
00186 length = len(_x)
00187 buff.write(struct.pack('<I%ss'%length, length, _x))
00188 _x = self
00189 buff.write(_struct_3I.pack(_x.action_feedback.header.seq, _x.action_feedback.header.stamp.secs, _x.action_feedback.header.stamp.nsecs))
00190 _x = self.action_feedback.header.frame_id
00191 length = len(_x)
00192 buff.write(struct.pack('<I%ss'%length, length, _x))
00193 _x = self
00194 buff.write(_struct_2I.pack(_x.action_feedback.status.goal_id.stamp.secs, _x.action_feedback.status.goal_id.stamp.nsecs))
00195 _x = self.action_feedback.status.goal_id.id
00196 length = len(_x)
00197 buff.write(struct.pack('<I%ss'%length, length, _x))
00198 buff.write(_struct_B.pack(self.action_feedback.status.status))
00199 _x = self.action_feedback.status.text
00200 length = len(_x)
00201 buff.write(struct.pack('<I%ss'%length, length, _x))
00202 except struct.error, se: self._check_types(se)
00203 except TypeError, te: self._check_types(te)
00204
00205 def deserialize(self, str):
00206 """
00207 unpack serialized message in str into this message instance
00208 @param str: byte array of serialized message
00209 @type str: str
00210 """
00211 try:
00212 if self.action_goal is None:
00213 self.action_goal = joint_states_settler.msg.ConfigActionGoal()
00214 if self.action_result is None:
00215 self.action_result = joint_states_settler.msg.ConfigActionResult()
00216 if self.action_feedback is None:
00217 self.action_feedback = joint_states_settler.msg.ConfigActionFeedback()
00218 end = 0
00219 _x = self
00220 start = end
00221 end += 12
00222 (_x.action_goal.header.seq, _x.action_goal.header.stamp.secs, _x.action_goal.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00223 start = end
00224 end += 4
00225 (length,) = _struct_I.unpack(str[start:end])
00226 start = end
00227 end += length
00228 self.action_goal.header.frame_id = str[start:end]
00229 _x = self
00230 start = end
00231 end += 8
00232 (_x.action_goal.goal_id.stamp.secs, _x.action_goal.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00233 start = end
00234 end += 4
00235 (length,) = _struct_I.unpack(str[start:end])
00236 start = end
00237 end += length
00238 self.action_goal.goal_id.id = str[start:end]
00239 start = end
00240 end += 4
00241 (length,) = _struct_I.unpack(str[start:end])
00242 self.action_goal.goal.joint_names = []
00243 for i in xrange(0, length):
00244 start = end
00245 end += 4
00246 (length,) = _struct_I.unpack(str[start:end])
00247 start = end
00248 end += length
00249 val1 = str[start:end]
00250 self.action_goal.goal.joint_names.append(val1)
00251 start = end
00252 end += 4
00253 (length,) = _struct_I.unpack(str[start:end])
00254 pattern = '<%sd'%length
00255 start = end
00256 end += struct.calcsize(pattern)
00257 self.action_goal.goal.tolerances = struct.unpack(pattern, str[start:end])
00258 _x = self
00259 start = end
00260 end += 24
00261 (_x.action_goal.goal.max_step.secs, _x.action_goal.goal.max_step.nsecs, _x.action_goal.goal.cache_size, _x.action_result.header.seq, _x.action_result.header.stamp.secs, _x.action_result.header.stamp.nsecs,) = _struct_2i4I.unpack(str[start:end])
00262 start = end
00263 end += 4
00264 (length,) = _struct_I.unpack(str[start:end])
00265 start = end
00266 end += length
00267 self.action_result.header.frame_id = str[start:end]
00268 _x = self
00269 start = end
00270 end += 8
00271 (_x.action_result.status.goal_id.stamp.secs, _x.action_result.status.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00272 start = end
00273 end += 4
00274 (length,) = _struct_I.unpack(str[start:end])
00275 start = end
00276 end += length
00277 self.action_result.status.goal_id.id = str[start:end]
00278 start = end
00279 end += 1
00280 (self.action_result.status.status,) = _struct_B.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.action_result.status.text = str[start:end]
00287 _x = self
00288 start = end
00289 end += 12
00290 (_x.action_feedback.header.seq, _x.action_feedback.header.stamp.secs, _x.action_feedback.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00291 start = end
00292 end += 4
00293 (length,) = _struct_I.unpack(str[start:end])
00294 start = end
00295 end += length
00296 self.action_feedback.header.frame_id = str[start:end]
00297 _x = self
00298 start = end
00299 end += 8
00300 (_x.action_feedback.status.goal_id.stamp.secs, _x.action_feedback.status.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00301 start = end
00302 end += 4
00303 (length,) = _struct_I.unpack(str[start:end])
00304 start = end
00305 end += length
00306 self.action_feedback.status.goal_id.id = str[start:end]
00307 start = end
00308 end += 1
00309 (self.action_feedback.status.status,) = _struct_B.unpack(str[start:end])
00310 start = end
00311 end += 4
00312 (length,) = _struct_I.unpack(str[start:end])
00313 start = end
00314 end += length
00315 self.action_feedback.status.text = str[start:end]
00316 return self
00317 except struct.error, e:
00318 raise roslib.message.DeserializationError(e)
00319
00320
00321 def serialize_numpy(self, buff, numpy):
00322 """
00323 serialize message with numpy array types into buffer
00324 @param buff: buffer
00325 @type buff: StringIO
00326 @param numpy: numpy python module
00327 @type numpy module
00328 """
00329 try:
00330 _x = self
00331 buff.write(_struct_3I.pack(_x.action_goal.header.seq, _x.action_goal.header.stamp.secs, _x.action_goal.header.stamp.nsecs))
00332 _x = self.action_goal.header.frame_id
00333 length = len(_x)
00334 buff.write(struct.pack('<I%ss'%length, length, _x))
00335 _x = self
00336 buff.write(_struct_2I.pack(_x.action_goal.goal_id.stamp.secs, _x.action_goal.goal_id.stamp.nsecs))
00337 _x = self.action_goal.goal_id.id
00338 length = len(_x)
00339 buff.write(struct.pack('<I%ss'%length, length, _x))
00340 length = len(self.action_goal.goal.joint_names)
00341 buff.write(_struct_I.pack(length))
00342 for val1 in self.action_goal.goal.joint_names:
00343 length = len(val1)
00344 buff.write(struct.pack('<I%ss'%length, length, val1))
00345 length = len(self.action_goal.goal.tolerances)
00346 buff.write(_struct_I.pack(length))
00347 pattern = '<%sd'%length
00348 buff.write(self.action_goal.goal.tolerances.tostring())
00349 _x = self
00350 buff.write(_struct_2i4I.pack(_x.action_goal.goal.max_step.secs, _x.action_goal.goal.max_step.nsecs, _x.action_goal.goal.cache_size, _x.action_result.header.seq, _x.action_result.header.stamp.secs, _x.action_result.header.stamp.nsecs))
00351 _x = self.action_result.header.frame_id
00352 length = len(_x)
00353 buff.write(struct.pack('<I%ss'%length, length, _x))
00354 _x = self
00355 buff.write(_struct_2I.pack(_x.action_result.status.goal_id.stamp.secs, _x.action_result.status.goal_id.stamp.nsecs))
00356 _x = self.action_result.status.goal_id.id
00357 length = len(_x)
00358 buff.write(struct.pack('<I%ss'%length, length, _x))
00359 buff.write(_struct_B.pack(self.action_result.status.status))
00360 _x = self.action_result.status.text
00361 length = len(_x)
00362 buff.write(struct.pack('<I%ss'%length, length, _x))
00363 _x = self
00364 buff.write(_struct_3I.pack(_x.action_feedback.header.seq, _x.action_feedback.header.stamp.secs, _x.action_feedback.header.stamp.nsecs))
00365 _x = self.action_feedback.header.frame_id
00366 length = len(_x)
00367 buff.write(struct.pack('<I%ss'%length, length, _x))
00368 _x = self
00369 buff.write(_struct_2I.pack(_x.action_feedback.status.goal_id.stamp.secs, _x.action_feedback.status.goal_id.stamp.nsecs))
00370 _x = self.action_feedback.status.goal_id.id
00371 length = len(_x)
00372 buff.write(struct.pack('<I%ss'%length, length, _x))
00373 buff.write(_struct_B.pack(self.action_feedback.status.status))
00374 _x = self.action_feedback.status.text
00375 length = len(_x)
00376 buff.write(struct.pack('<I%ss'%length, length, _x))
00377 except struct.error, se: self._check_types(se)
00378 except TypeError, te: self._check_types(te)
00379
00380 def deserialize_numpy(self, str, numpy):
00381 """
00382 unpack serialized message in str into this message instance using numpy for array types
00383 @param str: byte array of serialized message
00384 @type str: str
00385 @param numpy: numpy python module
00386 @type numpy: module
00387 """
00388 try:
00389 if self.action_goal is None:
00390 self.action_goal = joint_states_settler.msg.ConfigActionGoal()
00391 if self.action_result is None:
00392 self.action_result = joint_states_settler.msg.ConfigActionResult()
00393 if self.action_feedback is None:
00394 self.action_feedback = joint_states_settler.msg.ConfigActionFeedback()
00395 end = 0
00396 _x = self
00397 start = end
00398 end += 12
00399 (_x.action_goal.header.seq, _x.action_goal.header.stamp.secs, _x.action_goal.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00400 start = end
00401 end += 4
00402 (length,) = _struct_I.unpack(str[start:end])
00403 start = end
00404 end += length
00405 self.action_goal.header.frame_id = str[start:end]
00406 _x = self
00407 start = end
00408 end += 8
00409 (_x.action_goal.goal_id.stamp.secs, _x.action_goal.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00410 start = end
00411 end += 4
00412 (length,) = _struct_I.unpack(str[start:end])
00413 start = end
00414 end += length
00415 self.action_goal.goal_id.id = str[start:end]
00416 start = end
00417 end += 4
00418 (length,) = _struct_I.unpack(str[start:end])
00419 self.action_goal.goal.joint_names = []
00420 for i in xrange(0, length):
00421 start = end
00422 end += 4
00423 (length,) = _struct_I.unpack(str[start:end])
00424 start = end
00425 end += length
00426 val1 = str[start:end]
00427 self.action_goal.goal.joint_names.append(val1)
00428 start = end
00429 end += 4
00430 (length,) = _struct_I.unpack(str[start:end])
00431 pattern = '<%sd'%length
00432 start = end
00433 end += struct.calcsize(pattern)
00434 self.action_goal.goal.tolerances = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
00435 _x = self
00436 start = end
00437 end += 24
00438 (_x.action_goal.goal.max_step.secs, _x.action_goal.goal.max_step.nsecs, _x.action_goal.goal.cache_size, _x.action_result.header.seq, _x.action_result.header.stamp.secs, _x.action_result.header.stamp.nsecs,) = _struct_2i4I.unpack(str[start:end])
00439 start = end
00440 end += 4
00441 (length,) = _struct_I.unpack(str[start:end])
00442 start = end
00443 end += length
00444 self.action_result.header.frame_id = str[start:end]
00445 _x = self
00446 start = end
00447 end += 8
00448 (_x.action_result.status.goal_id.stamp.secs, _x.action_result.status.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00449 start = end
00450 end += 4
00451 (length,) = _struct_I.unpack(str[start:end])
00452 start = end
00453 end += length
00454 self.action_result.status.goal_id.id = str[start:end]
00455 start = end
00456 end += 1
00457 (self.action_result.status.status,) = _struct_B.unpack(str[start:end])
00458 start = end
00459 end += 4
00460 (length,) = _struct_I.unpack(str[start:end])
00461 start = end
00462 end += length
00463 self.action_result.status.text = str[start:end]
00464 _x = self
00465 start = end
00466 end += 12
00467 (_x.action_feedback.header.seq, _x.action_feedback.header.stamp.secs, _x.action_feedback.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00468 start = end
00469 end += 4
00470 (length,) = _struct_I.unpack(str[start:end])
00471 start = end
00472 end += length
00473 self.action_feedback.header.frame_id = str[start:end]
00474 _x = self
00475 start = end
00476 end += 8
00477 (_x.action_feedback.status.goal_id.stamp.secs, _x.action_feedback.status.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00478 start = end
00479 end += 4
00480 (length,) = _struct_I.unpack(str[start:end])
00481 start = end
00482 end += length
00483 self.action_feedback.status.goal_id.id = str[start:end]
00484 start = end
00485 end += 1
00486 (self.action_feedback.status.status,) = _struct_B.unpack(str[start:end])
00487 start = end
00488 end += 4
00489 (length,) = _struct_I.unpack(str[start:end])
00490 start = end
00491 end += length
00492 self.action_feedback.status.text = str[start:end]
00493 return self
00494 except struct.error, e:
00495 raise roslib.message.DeserializationError(e)
00496
00497 _struct_I = roslib.message.struct_I
00498 _struct_3I = struct.Struct("<3I")
00499 _struct_B = struct.Struct("<B")
00500 _struct_2I = struct.Struct("<2I")
00501 _struct_2i4I = struct.Struct("<2i4I")