_Pr2GripperCommandAction.py
Go to the documentation of this file.
00001 """autogenerated by genpy from pr2_controllers_msgs/Pr2GripperCommandAction.msg. Do not edit."""
00002 import sys
00003 python3 = True if sys.hexversion > 0x03000000 else False
00004 import genpy
00005 import struct
00006 
00007 import genpy
00008 import pr2_controllers_msgs.msg
00009 import actionlib_msgs.msg
00010 import std_msgs.msg
00011 
00012 class Pr2GripperCommandAction(genpy.Message):
00013   _md5sum = "950b2a6ebe831f5d4f4ceaba3d8be01e"
00014   _type = "pr2_controllers_msgs/Pr2GripperCommandAction"
00015   _has_header = False #flag to mark the presence of a Header object
00016   _full_text = """# ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00017 
00018 Pr2GripperCommandActionGoal action_goal
00019 Pr2GripperCommandActionResult action_result
00020 Pr2GripperCommandActionFeedback action_feedback
00021 
00022 ================================================================================
00023 MSG: pr2_controllers_msgs/Pr2GripperCommandActionGoal
00024 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00025 
00026 Header header
00027 actionlib_msgs/GoalID goal_id
00028 Pr2GripperCommandGoal goal
00029 
00030 ================================================================================
00031 MSG: std_msgs/Header
00032 # Standard metadata for higher-level stamped data types.
00033 # This is generally used to communicate timestamped data 
00034 # in a particular coordinate frame.
00035 # 
00036 # sequence ID: consecutively increasing ID 
00037 uint32 seq
00038 #Two-integer timestamp that is expressed as:
00039 # * stamp.secs: seconds (stamp_secs) since epoch
00040 # * stamp.nsecs: nanoseconds since stamp_secs
00041 # time-handling sugar is provided by the client library
00042 time stamp
00043 #Frame this data is associated with
00044 # 0: no frame
00045 # 1: global frame
00046 string frame_id
00047 
00048 ================================================================================
00049 MSG: actionlib_msgs/GoalID
00050 # The stamp should store the time at which this goal was requested.
00051 # It is used by an action server when it tries to preempt all
00052 # goals that were requested before a certain time
00053 time stamp
00054 
00055 # The id provides a way to associate feedback and
00056 # result message with specific goal requests. The id
00057 # specified must be unique.
00058 string id
00059 
00060 
00061 ================================================================================
00062 MSG: pr2_controllers_msgs/Pr2GripperCommandGoal
00063 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00064 pr2_controllers_msgs/Pr2GripperCommand command
00065 
00066 ================================================================================
00067 MSG: pr2_controllers_msgs/Pr2GripperCommand
00068 float64 position
00069 float64 max_effort
00070 
00071 ================================================================================
00072 MSG: pr2_controllers_msgs/Pr2GripperCommandActionResult
00073 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00074 
00075 Header header
00076 actionlib_msgs/GoalStatus status
00077 Pr2GripperCommandResult result
00078 
00079 ================================================================================
00080 MSG: actionlib_msgs/GoalStatus
00081 GoalID goal_id
00082 uint8 status
00083 uint8 PENDING         = 0   # The goal has yet to be processed by the action server
00084 uint8 ACTIVE          = 1   # The goal is currently being processed by the action server
00085 uint8 PREEMPTED       = 2   # The goal received a cancel request after it started executing
00086                             #   and has since completed its execution (Terminal State)
00087 uint8 SUCCEEDED       = 3   # The goal was achieved successfully by the action server (Terminal State)
00088 uint8 ABORTED         = 4   # The goal was aborted during execution by the action server due
00089                             #    to some failure (Terminal State)
00090 uint8 REJECTED        = 5   # The goal was rejected by the action server without being processed,
00091                             #    because the goal was unattainable or invalid (Terminal State)
00092 uint8 PREEMPTING      = 6   # The goal received a cancel request after it started executing
00093                             #    and has not yet completed execution
00094 uint8 RECALLING       = 7   # The goal received a cancel request before it started executing,
00095                             #    but the action server has not yet confirmed that the goal is canceled
00096 uint8 RECALLED        = 8   # The goal received a cancel request before it started executing
00097                             #    and was successfully cancelled (Terminal State)
00098 uint8 LOST            = 9   # An action client can determine that a goal is LOST. This should not be
00099                             #    sent over the wire by an action server
00100 
00101 #Allow for the user to associate a string with GoalStatus for debugging
00102 string text
00103 
00104 
00105 ================================================================================
00106 MSG: pr2_controllers_msgs/Pr2GripperCommandResult
00107 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00108 float64 position  # The current gripper gap size (in meters)
00109 float64 effort    # The current effort exerted (in Newtons)
00110 bool stalled      # True iff the gripper is exerting max effort and not moving
00111 bool reached_goal # True iff the gripper position has reached the commanded setpoint
00112 
00113 ================================================================================
00114 MSG: pr2_controllers_msgs/Pr2GripperCommandActionFeedback
00115 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00116 
00117 Header header
00118 actionlib_msgs/GoalStatus status
00119 Pr2GripperCommandFeedback feedback
00120 
00121 ================================================================================
00122 MSG: pr2_controllers_msgs/Pr2GripperCommandFeedback
00123 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00124 float64 position  # The current gripper gap size (in meters)
00125 float64 effort    # The current effort exerted (in Newtons)
00126 bool stalled      # True iff the gripper is exerting max effort and not moving
00127 bool reached_goal # True iff the gripper position has reached the commanded setpoint
00128 
00129 
00130 """
00131   __slots__ = ['action_goal','action_result','action_feedback']
00132   _slot_types = ['pr2_controllers_msgs/Pr2GripperCommandActionGoal','pr2_controllers_msgs/Pr2GripperCommandActionResult','pr2_controllers_msgs/Pr2GripperCommandActionFeedback']
00133 
00134   def __init__(self, *args, **kwds):
00135     """
00136     Constructor. Any message fields that are implicitly/explicitly
00137     set to None will be assigned a default value. The recommend
00138     use is keyword arguments as this is more robust to future message
00139     changes.  You cannot mix in-order arguments and keyword arguments.
00140 
00141     The available fields are:
00142        action_goal,action_result,action_feedback
00143 
00144     :param args: complete set of field values, in .msg order
00145     :param kwds: use keyword arguments corresponding to message field names
00146     to set specific fields.
00147     """
00148     if args or kwds:
00149       super(Pr2GripperCommandAction, self).__init__(*args, **kwds)
00150       #message fields cannot be None, assign default values for those that are
00151       if self.action_goal is None:
00152         self.action_goal = pr2_controllers_msgs.msg.Pr2GripperCommandActionGoal()
00153       if self.action_result is None:
00154         self.action_result = pr2_controllers_msgs.msg.Pr2GripperCommandActionResult()
00155       if self.action_feedback is None:
00156         self.action_feedback = pr2_controllers_msgs.msg.Pr2GripperCommandActionFeedback()
00157     else:
00158       self.action_goal = pr2_controllers_msgs.msg.Pr2GripperCommandActionGoal()
00159       self.action_result = pr2_controllers_msgs.msg.Pr2GripperCommandActionResult()
00160       self.action_feedback = pr2_controllers_msgs.msg.Pr2GripperCommandActionFeedback()
00161 
00162   def _get_types(self):
00163     """
00164     internal API method
00165     """
00166     return self._slot_types
00167 
00168   def serialize(self, buff):
00169     """
00170     serialize message into buffer
00171     :param buff: buffer, ``StringIO``
00172     """
00173     try:
00174       _x = self
00175       buff.write(_struct_3I.pack(_x.action_goal.header.seq, _x.action_goal.header.stamp.secs, _x.action_goal.header.stamp.nsecs))
00176       _x = self.action_goal.header.frame_id
00177       length = len(_x)
00178       if python3 or type(_x) == unicode:
00179         _x = _x.encode('utf-8')
00180         length = len(_x)
00181       buff.write(struct.pack('<I%ss'%length, length, _x))
00182       _x = self
00183       buff.write(_struct_2I.pack(_x.action_goal.goal_id.stamp.secs, _x.action_goal.goal_id.stamp.nsecs))
00184       _x = self.action_goal.goal_id.id
00185       length = len(_x)
00186       if python3 or type(_x) == unicode:
00187         _x = _x.encode('utf-8')
00188         length = len(_x)
00189       buff.write(struct.pack('<I%ss'%length, length, _x))
00190       _x = self
00191       buff.write(_struct_2d3I.pack(_x.action_goal.goal.command.position, _x.action_goal.goal.command.max_effort, _x.action_result.header.seq, _x.action_result.header.stamp.secs, _x.action_result.header.stamp.nsecs))
00192       _x = self.action_result.header.frame_id
00193       length = len(_x)
00194       if python3 or type(_x) == unicode:
00195         _x = _x.encode('utf-8')
00196         length = len(_x)
00197       buff.write(struct.pack('<I%ss'%length, length, _x))
00198       _x = self
00199       buff.write(_struct_2I.pack(_x.action_result.status.goal_id.stamp.secs, _x.action_result.status.goal_id.stamp.nsecs))
00200       _x = self.action_result.status.goal_id.id
00201       length = len(_x)
00202       if python3 or type(_x) == unicode:
00203         _x = _x.encode('utf-8')
00204         length = len(_x)
00205       buff.write(struct.pack('<I%ss'%length, length, _x))
00206       buff.write(_struct_B.pack(self.action_result.status.status))
00207       _x = self.action_result.status.text
00208       length = len(_x)
00209       if python3 or type(_x) == unicode:
00210         _x = _x.encode('utf-8')
00211         length = len(_x)
00212       buff.write(struct.pack('<I%ss'%length, length, _x))
00213       _x = self
00214       buff.write(_struct_2d2B3I.pack(_x.action_result.result.position, _x.action_result.result.effort, _x.action_result.result.stalled, _x.action_result.result.reached_goal, _x.action_feedback.header.seq, _x.action_feedback.header.stamp.secs, _x.action_feedback.header.stamp.nsecs))
00215       _x = self.action_feedback.header.frame_id
00216       length = len(_x)
00217       if python3 or type(_x) == unicode:
00218         _x = _x.encode('utf-8')
00219         length = len(_x)
00220       buff.write(struct.pack('<I%ss'%length, length, _x))
00221       _x = self
00222       buff.write(_struct_2I.pack(_x.action_feedback.status.goal_id.stamp.secs, _x.action_feedback.status.goal_id.stamp.nsecs))
00223       _x = self.action_feedback.status.goal_id.id
00224       length = len(_x)
00225       if python3 or type(_x) == unicode:
00226         _x = _x.encode('utf-8')
00227         length = len(_x)
00228       buff.write(struct.pack('<I%ss'%length, length, _x))
00229       buff.write(_struct_B.pack(self.action_feedback.status.status))
00230       _x = self.action_feedback.status.text
00231       length = len(_x)
00232       if python3 or type(_x) == unicode:
00233         _x = _x.encode('utf-8')
00234         length = len(_x)
00235       buff.write(struct.pack('<I%ss'%length, length, _x))
00236       _x = self
00237       buff.write(_struct_2d2B.pack(_x.action_feedback.feedback.position, _x.action_feedback.feedback.effort, _x.action_feedback.feedback.stalled, _x.action_feedback.feedback.reached_goal))
00238     except struct.error as se: self._check_types(struct.error("%s: '%s' when writing '%s'" % (type(se), str(se), str(_x))))
00239     except TypeError as te: self._check_types(ValueError("%s: '%s' when writing '%s'" % (type(te), str(te), str(_x))))
00240 
00241   def deserialize(self, str):
00242     """
00243     unpack serialized message in str into this message instance
00244     :param str: byte array of serialized message, ``str``
00245     """
00246     try:
00247       if self.action_goal is None:
00248         self.action_goal = pr2_controllers_msgs.msg.Pr2GripperCommandActionGoal()
00249       if self.action_result is None:
00250         self.action_result = pr2_controllers_msgs.msg.Pr2GripperCommandActionResult()
00251       if self.action_feedback is None:
00252         self.action_feedback = pr2_controllers_msgs.msg.Pr2GripperCommandActionFeedback()
00253       end = 0
00254       _x = self
00255       start = end
00256       end += 12
00257       (_x.action_goal.header.seq, _x.action_goal.header.stamp.secs, _x.action_goal.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00258       start = end
00259       end += 4
00260       (length,) = _struct_I.unpack(str[start:end])
00261       start = end
00262       end += length
00263       if python3:
00264         self.action_goal.header.frame_id = str[start:end].decode('utf-8')
00265       else:
00266         self.action_goal.header.frame_id = str[start:end]
00267       _x = self
00268       start = end
00269       end += 8
00270       (_x.action_goal.goal_id.stamp.secs, _x.action_goal.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00271       start = end
00272       end += 4
00273       (length,) = _struct_I.unpack(str[start:end])
00274       start = end
00275       end += length
00276       if python3:
00277         self.action_goal.goal_id.id = str[start:end].decode('utf-8')
00278       else:
00279         self.action_goal.goal_id.id = str[start:end]
00280       _x = self
00281       start = end
00282       end += 28
00283       (_x.action_goal.goal.command.position, _x.action_goal.goal.command.max_effort, _x.action_result.header.seq, _x.action_result.header.stamp.secs, _x.action_result.header.stamp.nsecs,) = _struct_2d3I.unpack(str[start:end])
00284       start = end
00285       end += 4
00286       (length,) = _struct_I.unpack(str[start:end])
00287       start = end
00288       end += length
00289       if python3:
00290         self.action_result.header.frame_id = str[start:end].decode('utf-8')
00291       else:
00292         self.action_result.header.frame_id = str[start:end]
00293       _x = self
00294       start = end
00295       end += 8
00296       (_x.action_result.status.goal_id.stamp.secs, _x.action_result.status.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00297       start = end
00298       end += 4
00299       (length,) = _struct_I.unpack(str[start:end])
00300       start = end
00301       end += length
00302       if python3:
00303         self.action_result.status.goal_id.id = str[start:end].decode('utf-8')
00304       else:
00305         self.action_result.status.goal_id.id = str[start:end]
00306       start = end
00307       end += 1
00308       (self.action_result.status.status,) = _struct_B.unpack(str[start:end])
00309       start = end
00310       end += 4
00311       (length,) = _struct_I.unpack(str[start:end])
00312       start = end
00313       end += length
00314       if python3:
00315         self.action_result.status.text = str[start:end].decode('utf-8')
00316       else:
00317         self.action_result.status.text = str[start:end]
00318       _x = self
00319       start = end
00320       end += 30
00321       (_x.action_result.result.position, _x.action_result.result.effort, _x.action_result.result.stalled, _x.action_result.result.reached_goal, _x.action_feedback.header.seq, _x.action_feedback.header.stamp.secs, _x.action_feedback.header.stamp.nsecs,) = _struct_2d2B3I.unpack(str[start:end])
00322       self.action_result.result.stalled = bool(self.action_result.result.stalled)
00323       self.action_result.result.reached_goal = bool(self.action_result.result.reached_goal)
00324       start = end
00325       end += 4
00326       (length,) = _struct_I.unpack(str[start:end])
00327       start = end
00328       end += length
00329       if python3:
00330         self.action_feedback.header.frame_id = str[start:end].decode('utf-8')
00331       else:
00332         self.action_feedback.header.frame_id = str[start:end]
00333       _x = self
00334       start = end
00335       end += 8
00336       (_x.action_feedback.status.goal_id.stamp.secs, _x.action_feedback.status.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00337       start = end
00338       end += 4
00339       (length,) = _struct_I.unpack(str[start:end])
00340       start = end
00341       end += length
00342       if python3:
00343         self.action_feedback.status.goal_id.id = str[start:end].decode('utf-8')
00344       else:
00345         self.action_feedback.status.goal_id.id = str[start:end]
00346       start = end
00347       end += 1
00348       (self.action_feedback.status.status,) = _struct_B.unpack(str[start:end])
00349       start = end
00350       end += 4
00351       (length,) = _struct_I.unpack(str[start:end])
00352       start = end
00353       end += length
00354       if python3:
00355         self.action_feedback.status.text = str[start:end].decode('utf-8')
00356       else:
00357         self.action_feedback.status.text = str[start:end]
00358       _x = self
00359       start = end
00360       end += 18
00361       (_x.action_feedback.feedback.position, _x.action_feedback.feedback.effort, _x.action_feedback.feedback.stalled, _x.action_feedback.feedback.reached_goal,) = _struct_2d2B.unpack(str[start:end])
00362       self.action_feedback.feedback.stalled = bool(self.action_feedback.feedback.stalled)
00363       self.action_feedback.feedback.reached_goal = bool(self.action_feedback.feedback.reached_goal)
00364       return self
00365     except struct.error as e:
00366       raise genpy.DeserializationError(e) #most likely buffer underfill
00367 
00368 
00369   def serialize_numpy(self, buff, numpy):
00370     """
00371     serialize message with numpy array types into buffer
00372     :param buff: buffer, ``StringIO``
00373     :param numpy: numpy python module
00374     """
00375     try:
00376       _x = self
00377       buff.write(_struct_3I.pack(_x.action_goal.header.seq, _x.action_goal.header.stamp.secs, _x.action_goal.header.stamp.nsecs))
00378       _x = self.action_goal.header.frame_id
00379       length = len(_x)
00380       if python3 or type(_x) == unicode:
00381         _x = _x.encode('utf-8')
00382         length = len(_x)
00383       buff.write(struct.pack('<I%ss'%length, length, _x))
00384       _x = self
00385       buff.write(_struct_2I.pack(_x.action_goal.goal_id.stamp.secs, _x.action_goal.goal_id.stamp.nsecs))
00386       _x = self.action_goal.goal_id.id
00387       length = len(_x)
00388       if python3 or type(_x) == unicode:
00389         _x = _x.encode('utf-8')
00390         length = len(_x)
00391       buff.write(struct.pack('<I%ss'%length, length, _x))
00392       _x = self
00393       buff.write(_struct_2d3I.pack(_x.action_goal.goal.command.position, _x.action_goal.goal.command.max_effort, _x.action_result.header.seq, _x.action_result.header.stamp.secs, _x.action_result.header.stamp.nsecs))
00394       _x = self.action_result.header.frame_id
00395       length = len(_x)
00396       if python3 or type(_x) == unicode:
00397         _x = _x.encode('utf-8')
00398         length = len(_x)
00399       buff.write(struct.pack('<I%ss'%length, length, _x))
00400       _x = self
00401       buff.write(_struct_2I.pack(_x.action_result.status.goal_id.stamp.secs, _x.action_result.status.goal_id.stamp.nsecs))
00402       _x = self.action_result.status.goal_id.id
00403       length = len(_x)
00404       if python3 or type(_x) == unicode:
00405         _x = _x.encode('utf-8')
00406         length = len(_x)
00407       buff.write(struct.pack('<I%ss'%length, length, _x))
00408       buff.write(_struct_B.pack(self.action_result.status.status))
00409       _x = self.action_result.status.text
00410       length = len(_x)
00411       if python3 or type(_x) == unicode:
00412         _x = _x.encode('utf-8')
00413         length = len(_x)
00414       buff.write(struct.pack('<I%ss'%length, length, _x))
00415       _x = self
00416       buff.write(_struct_2d2B3I.pack(_x.action_result.result.position, _x.action_result.result.effort, _x.action_result.result.stalled, _x.action_result.result.reached_goal, _x.action_feedback.header.seq, _x.action_feedback.header.stamp.secs, _x.action_feedback.header.stamp.nsecs))
00417       _x = self.action_feedback.header.frame_id
00418       length = len(_x)
00419       if python3 or type(_x) == unicode:
00420         _x = _x.encode('utf-8')
00421         length = len(_x)
00422       buff.write(struct.pack('<I%ss'%length, length, _x))
00423       _x = self
00424       buff.write(_struct_2I.pack(_x.action_feedback.status.goal_id.stamp.secs, _x.action_feedback.status.goal_id.stamp.nsecs))
00425       _x = self.action_feedback.status.goal_id.id
00426       length = len(_x)
00427       if python3 or type(_x) == unicode:
00428         _x = _x.encode('utf-8')
00429         length = len(_x)
00430       buff.write(struct.pack('<I%ss'%length, length, _x))
00431       buff.write(_struct_B.pack(self.action_feedback.status.status))
00432       _x = self.action_feedback.status.text
00433       length = len(_x)
00434       if python3 or type(_x) == unicode:
00435         _x = _x.encode('utf-8')
00436         length = len(_x)
00437       buff.write(struct.pack('<I%ss'%length, length, _x))
00438       _x = self
00439       buff.write(_struct_2d2B.pack(_x.action_feedback.feedback.position, _x.action_feedback.feedback.effort, _x.action_feedback.feedback.stalled, _x.action_feedback.feedback.reached_goal))
00440     except struct.error as se: self._check_types(struct.error("%s: '%s' when writing '%s'" % (type(se), str(se), str(_x))))
00441     except TypeError as te: self._check_types(ValueError("%s: '%s' when writing '%s'" % (type(te), str(te), str(_x))))
00442 
00443   def deserialize_numpy(self, str, numpy):
00444     """
00445     unpack serialized message in str into this message instance using numpy for array types
00446     :param str: byte array of serialized message, ``str``
00447     :param numpy: numpy python module
00448     """
00449     try:
00450       if self.action_goal is None:
00451         self.action_goal = pr2_controllers_msgs.msg.Pr2GripperCommandActionGoal()
00452       if self.action_result is None:
00453         self.action_result = pr2_controllers_msgs.msg.Pr2GripperCommandActionResult()
00454       if self.action_feedback is None:
00455         self.action_feedback = pr2_controllers_msgs.msg.Pr2GripperCommandActionFeedback()
00456       end = 0
00457       _x = self
00458       start = end
00459       end += 12
00460       (_x.action_goal.header.seq, _x.action_goal.header.stamp.secs, _x.action_goal.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00461       start = end
00462       end += 4
00463       (length,) = _struct_I.unpack(str[start:end])
00464       start = end
00465       end += length
00466       if python3:
00467         self.action_goal.header.frame_id = str[start:end].decode('utf-8')
00468       else:
00469         self.action_goal.header.frame_id = str[start:end]
00470       _x = self
00471       start = end
00472       end += 8
00473       (_x.action_goal.goal_id.stamp.secs, _x.action_goal.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00474       start = end
00475       end += 4
00476       (length,) = _struct_I.unpack(str[start:end])
00477       start = end
00478       end += length
00479       if python3:
00480         self.action_goal.goal_id.id = str[start:end].decode('utf-8')
00481       else:
00482         self.action_goal.goal_id.id = str[start:end]
00483       _x = self
00484       start = end
00485       end += 28
00486       (_x.action_goal.goal.command.position, _x.action_goal.goal.command.max_effort, _x.action_result.header.seq, _x.action_result.header.stamp.secs, _x.action_result.header.stamp.nsecs,) = _struct_2d3I.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       if python3:
00493         self.action_result.header.frame_id = str[start:end].decode('utf-8')
00494       else:
00495         self.action_result.header.frame_id = str[start:end]
00496       _x = self
00497       start = end
00498       end += 8
00499       (_x.action_result.status.goal_id.stamp.secs, _x.action_result.status.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00500       start = end
00501       end += 4
00502       (length,) = _struct_I.unpack(str[start:end])
00503       start = end
00504       end += length
00505       if python3:
00506         self.action_result.status.goal_id.id = str[start:end].decode('utf-8')
00507       else:
00508         self.action_result.status.goal_id.id = str[start:end]
00509       start = end
00510       end += 1
00511       (self.action_result.status.status,) = _struct_B.unpack(str[start:end])
00512       start = end
00513       end += 4
00514       (length,) = _struct_I.unpack(str[start:end])
00515       start = end
00516       end += length
00517       if python3:
00518         self.action_result.status.text = str[start:end].decode('utf-8')
00519       else:
00520         self.action_result.status.text = str[start:end]
00521       _x = self
00522       start = end
00523       end += 30
00524       (_x.action_result.result.position, _x.action_result.result.effort, _x.action_result.result.stalled, _x.action_result.result.reached_goal, _x.action_feedback.header.seq, _x.action_feedback.header.stamp.secs, _x.action_feedback.header.stamp.nsecs,) = _struct_2d2B3I.unpack(str[start:end])
00525       self.action_result.result.stalled = bool(self.action_result.result.stalled)
00526       self.action_result.result.reached_goal = bool(self.action_result.result.reached_goal)
00527       start = end
00528       end += 4
00529       (length,) = _struct_I.unpack(str[start:end])
00530       start = end
00531       end += length
00532       if python3:
00533         self.action_feedback.header.frame_id = str[start:end].decode('utf-8')
00534       else:
00535         self.action_feedback.header.frame_id = str[start:end]
00536       _x = self
00537       start = end
00538       end += 8
00539       (_x.action_feedback.status.goal_id.stamp.secs, _x.action_feedback.status.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00540       start = end
00541       end += 4
00542       (length,) = _struct_I.unpack(str[start:end])
00543       start = end
00544       end += length
00545       if python3:
00546         self.action_feedback.status.goal_id.id = str[start:end].decode('utf-8')
00547       else:
00548         self.action_feedback.status.goal_id.id = str[start:end]
00549       start = end
00550       end += 1
00551       (self.action_feedback.status.status,) = _struct_B.unpack(str[start:end])
00552       start = end
00553       end += 4
00554       (length,) = _struct_I.unpack(str[start:end])
00555       start = end
00556       end += length
00557       if python3:
00558         self.action_feedback.status.text = str[start:end].decode('utf-8')
00559       else:
00560         self.action_feedback.status.text = str[start:end]
00561       _x = self
00562       start = end
00563       end += 18
00564       (_x.action_feedback.feedback.position, _x.action_feedback.feedback.effort, _x.action_feedback.feedback.stalled, _x.action_feedback.feedback.reached_goal,) = _struct_2d2B.unpack(str[start:end])
00565       self.action_feedback.feedback.stalled = bool(self.action_feedback.feedback.stalled)
00566       self.action_feedback.feedback.reached_goal = bool(self.action_feedback.feedback.reached_goal)
00567       return self
00568     except struct.error as e:
00569       raise genpy.DeserializationError(e) #most likely buffer underfill
00570 
00571 _struct_I = genpy.struct_I
00572 _struct_2d3I = struct.Struct("<2d3I")
00573 _struct_B = struct.Struct("<B")
00574 _struct_2d2B3I = struct.Struct("<2d2B3I")
00575 _struct_2d2B = struct.Struct("<2d2B")
00576 _struct_3I = struct.Struct("<3I")
00577 _struct_2I = struct.Struct("<2I")


pr2_controllers_msgs
Author(s): Stuart Glaser
autogenerated on Thu Apr 24 2014 15:44:12