_GetRobotState.py
Go to the documentation of this file.
00001 """autogenerated by genpy from arm_navigation_msgs/GetRobotStateRequest.msg. Do not edit."""
00002 import sys
00003 python3 = True if sys.hexversion > 0x03000000 else False
00004 import genpy
00005 import struct
00006 
00007 
00008 class GetRobotStateRequest(genpy.Message):
00009   _md5sum = "d41d8cd98f00b204e9800998ecf8427e"
00010   _type = "arm_navigation_msgs/GetRobotStateRequest"
00011   _has_header = False #flag to mark the presence of a Header object
00012   _full_text = """
00013 
00014 
00015 
00016 """
00017   __slots__ = []
00018   _slot_types = []
00019 
00020   def __init__(self, *args, **kwds):
00021     """
00022     Constructor. Any message fields that are implicitly/explicitly
00023     set to None will be assigned a default value. The recommend
00024     use is keyword arguments as this is more robust to future message
00025     changes.  You cannot mix in-order arguments and keyword arguments.
00026 
00027     The available fields are:
00028        
00029 
00030     :param args: complete set of field values, in .msg order
00031     :param kwds: use keyword arguments corresponding to message field names
00032     to set specific fields.
00033     """
00034     if args or kwds:
00035       super(GetRobotStateRequest, self).__init__(*args, **kwds)
00036 
00037   def _get_types(self):
00038     """
00039     internal API method
00040     """
00041     return self._slot_types
00042 
00043   def serialize(self, buff):
00044     """
00045     serialize message into buffer
00046     :param buff: buffer, ``StringIO``
00047     """
00048     try:
00049       pass
00050     except struct.error as se: self._check_types(se)
00051     except TypeError as te: self._check_types(te)
00052 
00053   def deserialize(self, str):
00054     """
00055     unpack serialized message in str into this message instance
00056     :param str: byte array of serialized message, ``str``
00057     """
00058     try:
00059       end = 0
00060       return self
00061     except struct.error as e:
00062       raise genpy.DeserializationError(e) #most likely buffer underfill
00063 
00064 
00065   def serialize_numpy(self, buff, numpy):
00066     """
00067     serialize message with numpy array types into buffer
00068     :param buff: buffer, ``StringIO``
00069     :param numpy: numpy python 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, ``str``
00080     :param numpy: numpy python module
00081     """
00082     try:
00083       end = 0
00084       return self
00085     except struct.error as e:
00086       raise genpy.DeserializationError(e) #most likely buffer underfill
00087 
00088 _struct_I = genpy.struct_I
00089 """autogenerated by genpy from arm_navigation_msgs/GetRobotStateResponse.msg. Do not edit."""
00090 import sys
00091 python3 = True if sys.hexversion > 0x03000000 else False
00092 import genpy
00093 import struct
00094 
00095 import arm_navigation_msgs.msg
00096 import geometry_msgs.msg
00097 import std_msgs.msg
00098 import genpy
00099 import sensor_msgs.msg
00100 
00101 class GetRobotStateResponse(genpy.Message):
00102   _md5sum = "9799d82a26586bf3963962b7c3038f40"
00103   _type = "arm_navigation_msgs/GetRobotStateResponse"
00104   _has_header = False #flag to mark the presence of a Header object
00105   _full_text = """
00106 
00107 arm_navigation_msgs/RobotState robot_state
00108 
00109 
00110 
00111 
00112 arm_navigation_msgs/ArmNavigationErrorCodes error_code
00113 
00114 
00115 ================================================================================
00116 MSG: arm_navigation_msgs/RobotState
00117 # This message contains information about the robot state, i.e. the positions of its joints and links
00118 sensor_msgs/JointState joint_state
00119 arm_navigation_msgs/MultiDOFJointState multi_dof_joint_state
00120 
00121 ================================================================================
00122 MSG: sensor_msgs/JointState
00123 # This is a message that holds data to describe the state of a set of torque controlled joints. 
00124 #
00125 # The state of each joint (revolute or prismatic) is defined by:
00126 #  * the position of the joint (rad or m),
00127 #  * the velocity of the joint (rad/s or m/s) and 
00128 #  * the effort that is applied in the joint (Nm or N).
00129 #
00130 # Each joint is uniquely identified by its name
00131 # The header specifies the time at which the joint states were recorded. All the joint states
00132 # in one message have to be recorded at the same time.
00133 #
00134 # This message consists of a multiple arrays, one for each part of the joint state. 
00135 # The goal is to make each of the fields optional. When e.g. your joints have no
00136 # effort associated with them, you can leave the effort array empty. 
00137 #
00138 # All arrays in this message should have the same size, or be empty.
00139 # This is the only way to uniquely associate the joint name with the correct
00140 # states.
00141 
00142 
00143 Header header
00144 
00145 string[] name
00146 float64[] position
00147 float64[] velocity
00148 float64[] effort
00149 
00150 ================================================================================
00151 MSG: std_msgs/Header
00152 # Standard metadata for higher-level stamped data types.
00153 # This is generally used to communicate timestamped data 
00154 # in a particular coordinate frame.
00155 # 
00156 # sequence ID: consecutively increasing ID 
00157 uint32 seq
00158 #Two-integer timestamp that is expressed as:
00159 # * stamp.secs: seconds (stamp_secs) since epoch
00160 # * stamp.nsecs: nanoseconds since stamp_secs
00161 # time-handling sugar is provided by the client library
00162 time stamp
00163 #Frame this data is associated with
00164 # 0: no frame
00165 # 1: global frame
00166 string frame_id
00167 
00168 ================================================================================
00169 MSG: arm_navigation_msgs/MultiDOFJointState
00170 #A representation of a multi-dof joint state
00171 time stamp
00172 string[] joint_names
00173 string[] frame_ids
00174 string[] child_frame_ids
00175 geometry_msgs/Pose[] poses
00176 
00177 ================================================================================
00178 MSG: geometry_msgs/Pose
00179 # A representation of pose in free space, composed of postion and orientation. 
00180 Point position
00181 Quaternion orientation
00182 
00183 ================================================================================
00184 MSG: geometry_msgs/Point
00185 # This contains the position of a point in free space
00186 float64 x
00187 float64 y
00188 float64 z
00189 
00190 ================================================================================
00191 MSG: geometry_msgs/Quaternion
00192 # This represents an orientation in free space in quaternion form.
00193 
00194 float64 x
00195 float64 y
00196 float64 z
00197 float64 w
00198 
00199 ================================================================================
00200 MSG: arm_navigation_msgs/ArmNavigationErrorCodes
00201 int32 val
00202 
00203 # overall behavior
00204 int32 PLANNING_FAILED=-1
00205 int32 SUCCESS=1
00206 int32 TIMED_OUT=-2
00207 
00208 # start state errors
00209 int32 START_STATE_IN_COLLISION=-3
00210 int32 START_STATE_VIOLATES_PATH_CONSTRAINTS=-4
00211 
00212 # goal errors
00213 int32 GOAL_IN_COLLISION=-5
00214 int32 GOAL_VIOLATES_PATH_CONSTRAINTS=-6
00215 
00216 # robot state
00217 int32 INVALID_ROBOT_STATE=-7
00218 int32 INCOMPLETE_ROBOT_STATE=-8
00219 
00220 # planning request errors
00221 int32 INVALID_PLANNER_ID=-9
00222 int32 INVALID_NUM_PLANNING_ATTEMPTS=-10
00223 int32 INVALID_ALLOWED_PLANNING_TIME=-11
00224 int32 INVALID_GROUP_NAME=-12
00225 int32 INVALID_GOAL_JOINT_CONSTRAINTS=-13
00226 int32 INVALID_GOAL_POSITION_CONSTRAINTS=-14
00227 int32 INVALID_GOAL_ORIENTATION_CONSTRAINTS=-15
00228 int32 INVALID_PATH_JOINT_CONSTRAINTS=-16
00229 int32 INVALID_PATH_POSITION_CONSTRAINTS=-17
00230 int32 INVALID_PATH_ORIENTATION_CONSTRAINTS=-18
00231 
00232 # state/trajectory monitor errors
00233 int32 INVALID_TRAJECTORY=-19
00234 int32 INVALID_INDEX=-20
00235 int32 JOINT_LIMITS_VIOLATED=-21
00236 int32 PATH_CONSTRAINTS_VIOLATED=-22
00237 int32 COLLISION_CONSTRAINTS_VIOLATED=-23
00238 int32 GOAL_CONSTRAINTS_VIOLATED=-24
00239 int32 JOINTS_NOT_MOVING=-25
00240 int32 TRAJECTORY_CONTROLLER_FAILED=-26
00241 
00242 # system errors
00243 int32 FRAME_TRANSFORM_FAILURE=-27
00244 int32 COLLISION_CHECKING_UNAVAILABLE=-28
00245 int32 ROBOT_STATE_STALE=-29
00246 int32 SENSOR_INFO_STALE=-30
00247 
00248 # kinematics errors
00249 int32 NO_IK_SOLUTION=-31
00250 int32 INVALID_LINK_NAME=-32
00251 int32 IK_LINK_IN_COLLISION=-33
00252 int32 NO_FK_SOLUTION=-34
00253 int32 KINEMATICS_STATE_IN_COLLISION=-35
00254 
00255 # general errors
00256 int32 INVALID_TIMEOUT=-36
00257 
00258 
00259 """
00260   __slots__ = ['robot_state','error_code']
00261   _slot_types = ['arm_navigation_msgs/RobotState','arm_navigation_msgs/ArmNavigationErrorCodes']
00262 
00263   def __init__(self, *args, **kwds):
00264     """
00265     Constructor. Any message fields that are implicitly/explicitly
00266     set to None will be assigned a default value. The recommend
00267     use is keyword arguments as this is more robust to future message
00268     changes.  You cannot mix in-order arguments and keyword arguments.
00269 
00270     The available fields are:
00271        robot_state,error_code
00272 
00273     :param args: complete set of field values, in .msg order
00274     :param kwds: use keyword arguments corresponding to message field names
00275     to set specific fields.
00276     """
00277     if args or kwds:
00278       super(GetRobotStateResponse, self).__init__(*args, **kwds)
00279       #message fields cannot be None, assign default values for those that are
00280       if self.robot_state is None:
00281         self.robot_state = arm_navigation_msgs.msg.RobotState()
00282       if self.error_code is None:
00283         self.error_code = arm_navigation_msgs.msg.ArmNavigationErrorCodes()
00284     else:
00285       self.robot_state = arm_navigation_msgs.msg.RobotState()
00286       self.error_code = arm_navigation_msgs.msg.ArmNavigationErrorCodes()
00287 
00288   def _get_types(self):
00289     """
00290     internal API method
00291     """
00292     return self._slot_types
00293 
00294   def serialize(self, buff):
00295     """
00296     serialize message into buffer
00297     :param buff: buffer, ``StringIO``
00298     """
00299     try:
00300       _x = self
00301       buff.write(_struct_3I.pack(_x.robot_state.joint_state.header.seq, _x.robot_state.joint_state.header.stamp.secs, _x.robot_state.joint_state.header.stamp.nsecs))
00302       _x = self.robot_state.joint_state.header.frame_id
00303       length = len(_x)
00304       if python3 or type(_x) == unicode:
00305         _x = _x.encode('utf-8')
00306         length = len(_x)
00307       buff.write(struct.pack('<I%ss'%length, length, _x))
00308       length = len(self.robot_state.joint_state.name)
00309       buff.write(_struct_I.pack(length))
00310       for val1 in self.robot_state.joint_state.name:
00311         length = len(val1)
00312         if python3 or type(val1) == unicode:
00313           val1 = val1.encode('utf-8')
00314           length = len(val1)
00315         buff.write(struct.pack('<I%ss'%length, length, val1))
00316       length = len(self.robot_state.joint_state.position)
00317       buff.write(_struct_I.pack(length))
00318       pattern = '<%sd'%length
00319       buff.write(struct.pack(pattern, *self.robot_state.joint_state.position))
00320       length = len(self.robot_state.joint_state.velocity)
00321       buff.write(_struct_I.pack(length))
00322       pattern = '<%sd'%length
00323       buff.write(struct.pack(pattern, *self.robot_state.joint_state.velocity))
00324       length = len(self.robot_state.joint_state.effort)
00325       buff.write(_struct_I.pack(length))
00326       pattern = '<%sd'%length
00327       buff.write(struct.pack(pattern, *self.robot_state.joint_state.effort))
00328       _x = self
00329       buff.write(_struct_2I.pack(_x.robot_state.multi_dof_joint_state.stamp.secs, _x.robot_state.multi_dof_joint_state.stamp.nsecs))
00330       length = len(self.robot_state.multi_dof_joint_state.joint_names)
00331       buff.write(_struct_I.pack(length))
00332       for val1 in self.robot_state.multi_dof_joint_state.joint_names:
00333         length = len(val1)
00334         if python3 or type(val1) == unicode:
00335           val1 = val1.encode('utf-8')
00336           length = len(val1)
00337         buff.write(struct.pack('<I%ss'%length, length, val1))
00338       length = len(self.robot_state.multi_dof_joint_state.frame_ids)
00339       buff.write(_struct_I.pack(length))
00340       for val1 in self.robot_state.multi_dof_joint_state.frame_ids:
00341         length = len(val1)
00342         if python3 or type(val1) == unicode:
00343           val1 = val1.encode('utf-8')
00344           length = len(val1)
00345         buff.write(struct.pack('<I%ss'%length, length, val1))
00346       length = len(self.robot_state.multi_dof_joint_state.child_frame_ids)
00347       buff.write(_struct_I.pack(length))
00348       for val1 in self.robot_state.multi_dof_joint_state.child_frame_ids:
00349         length = len(val1)
00350         if python3 or type(val1) == unicode:
00351           val1 = val1.encode('utf-8')
00352           length = len(val1)
00353         buff.write(struct.pack('<I%ss'%length, length, val1))
00354       length = len(self.robot_state.multi_dof_joint_state.poses)
00355       buff.write(_struct_I.pack(length))
00356       for val1 in self.robot_state.multi_dof_joint_state.poses:
00357         _v1 = val1.position
00358         _x = _v1
00359         buff.write(_struct_3d.pack(_x.x, _x.y, _x.z))
00360         _v2 = val1.orientation
00361         _x = _v2
00362         buff.write(_struct_4d.pack(_x.x, _x.y, _x.z, _x.w))
00363       buff.write(_struct_i.pack(self.error_code.val))
00364     except struct.error as se: self._check_types(se)
00365     except TypeError as te: self._check_types(te)
00366 
00367   def deserialize(self, str):
00368     """
00369     unpack serialized message in str into this message instance
00370     :param str: byte array of serialized message, ``str``
00371     """
00372     try:
00373       if self.robot_state is None:
00374         self.robot_state = arm_navigation_msgs.msg.RobotState()
00375       if self.error_code is None:
00376         self.error_code = arm_navigation_msgs.msg.ArmNavigationErrorCodes()
00377       end = 0
00378       _x = self
00379       start = end
00380       end += 12
00381       (_x.robot_state.joint_state.header.seq, _x.robot_state.joint_state.header.stamp.secs, _x.robot_state.joint_state.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00382       start = end
00383       end += 4
00384       (length,) = _struct_I.unpack(str[start:end])
00385       start = end
00386       end += length
00387       if python3:
00388         self.robot_state.joint_state.header.frame_id = str[start:end].decode('utf-8')
00389       else:
00390         self.robot_state.joint_state.header.frame_id = str[start:end]
00391       start = end
00392       end += 4
00393       (length,) = _struct_I.unpack(str[start:end])
00394       self.robot_state.joint_state.name = []
00395       for i in range(0, length):
00396         start = end
00397         end += 4
00398         (length,) = _struct_I.unpack(str[start:end])
00399         start = end
00400         end += length
00401         if python3:
00402           val1 = str[start:end].decode('utf-8')
00403         else:
00404           val1 = str[start:end]
00405         self.robot_state.joint_state.name.append(val1)
00406       start = end
00407       end += 4
00408       (length,) = _struct_I.unpack(str[start:end])
00409       pattern = '<%sd'%length
00410       start = end
00411       end += struct.calcsize(pattern)
00412       self.robot_state.joint_state.position = struct.unpack(pattern, str[start:end])
00413       start = end
00414       end += 4
00415       (length,) = _struct_I.unpack(str[start:end])
00416       pattern = '<%sd'%length
00417       start = end
00418       end += struct.calcsize(pattern)
00419       self.robot_state.joint_state.velocity = struct.unpack(pattern, str[start:end])
00420       start = end
00421       end += 4
00422       (length,) = _struct_I.unpack(str[start:end])
00423       pattern = '<%sd'%length
00424       start = end
00425       end += struct.calcsize(pattern)
00426       self.robot_state.joint_state.effort = struct.unpack(pattern, str[start:end])
00427       _x = self
00428       start = end
00429       end += 8
00430       (_x.robot_state.multi_dof_joint_state.stamp.secs, _x.robot_state.multi_dof_joint_state.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00431       start = end
00432       end += 4
00433       (length,) = _struct_I.unpack(str[start:end])
00434       self.robot_state.multi_dof_joint_state.joint_names = []
00435       for i in range(0, length):
00436         start = end
00437         end += 4
00438         (length,) = _struct_I.unpack(str[start:end])
00439         start = end
00440         end += length
00441         if python3:
00442           val1 = str[start:end].decode('utf-8')
00443         else:
00444           val1 = str[start:end]
00445         self.robot_state.multi_dof_joint_state.joint_names.append(val1)
00446       start = end
00447       end += 4
00448       (length,) = _struct_I.unpack(str[start:end])
00449       self.robot_state.multi_dof_joint_state.frame_ids = []
00450       for i in range(0, length):
00451         start = end
00452         end += 4
00453         (length,) = _struct_I.unpack(str[start:end])
00454         start = end
00455         end += length
00456         if python3:
00457           val1 = str[start:end].decode('utf-8')
00458         else:
00459           val1 = str[start:end]
00460         self.robot_state.multi_dof_joint_state.frame_ids.append(val1)
00461       start = end
00462       end += 4
00463       (length,) = _struct_I.unpack(str[start:end])
00464       self.robot_state.multi_dof_joint_state.child_frame_ids = []
00465       for i in range(0, length):
00466         start = end
00467         end += 4
00468         (length,) = _struct_I.unpack(str[start:end])
00469         start = end
00470         end += length
00471         if python3:
00472           val1 = str[start:end].decode('utf-8')
00473         else:
00474           val1 = str[start:end]
00475         self.robot_state.multi_dof_joint_state.child_frame_ids.append(val1)
00476       start = end
00477       end += 4
00478       (length,) = _struct_I.unpack(str[start:end])
00479       self.robot_state.multi_dof_joint_state.poses = []
00480       for i in range(0, length):
00481         val1 = geometry_msgs.msg.Pose()
00482         _v3 = val1.position
00483         _x = _v3
00484         start = end
00485         end += 24
00486         (_x.x, _x.y, _x.z,) = _struct_3d.unpack(str[start:end])
00487         _v4 = val1.orientation
00488         _x = _v4
00489         start = end
00490         end += 32
00491         (_x.x, _x.y, _x.z, _x.w,) = _struct_4d.unpack(str[start:end])
00492         self.robot_state.multi_dof_joint_state.poses.append(val1)
00493       start = end
00494       end += 4
00495       (self.error_code.val,) = _struct_i.unpack(str[start:end])
00496       return self
00497     except struct.error as e:
00498       raise genpy.DeserializationError(e) #most likely buffer underfill
00499 
00500 
00501   def serialize_numpy(self, buff, numpy):
00502     """
00503     serialize message with numpy array types into buffer
00504     :param buff: buffer, ``StringIO``
00505     :param numpy: numpy python module
00506     """
00507     try:
00508       _x = self
00509       buff.write(_struct_3I.pack(_x.robot_state.joint_state.header.seq, _x.robot_state.joint_state.header.stamp.secs, _x.robot_state.joint_state.header.stamp.nsecs))
00510       _x = self.robot_state.joint_state.header.frame_id
00511       length = len(_x)
00512       if python3 or type(_x) == unicode:
00513         _x = _x.encode('utf-8')
00514         length = len(_x)
00515       buff.write(struct.pack('<I%ss'%length, length, _x))
00516       length = len(self.robot_state.joint_state.name)
00517       buff.write(_struct_I.pack(length))
00518       for val1 in self.robot_state.joint_state.name:
00519         length = len(val1)
00520         if python3 or type(val1) == unicode:
00521           val1 = val1.encode('utf-8')
00522           length = len(val1)
00523         buff.write(struct.pack('<I%ss'%length, length, val1))
00524       length = len(self.robot_state.joint_state.position)
00525       buff.write(_struct_I.pack(length))
00526       pattern = '<%sd'%length
00527       buff.write(self.robot_state.joint_state.position.tostring())
00528       length = len(self.robot_state.joint_state.velocity)
00529       buff.write(_struct_I.pack(length))
00530       pattern = '<%sd'%length
00531       buff.write(self.robot_state.joint_state.velocity.tostring())
00532       length = len(self.robot_state.joint_state.effort)
00533       buff.write(_struct_I.pack(length))
00534       pattern = '<%sd'%length
00535       buff.write(self.robot_state.joint_state.effort.tostring())
00536       _x = self
00537       buff.write(_struct_2I.pack(_x.robot_state.multi_dof_joint_state.stamp.secs, _x.robot_state.multi_dof_joint_state.stamp.nsecs))
00538       length = len(self.robot_state.multi_dof_joint_state.joint_names)
00539       buff.write(_struct_I.pack(length))
00540       for val1 in self.robot_state.multi_dof_joint_state.joint_names:
00541         length = len(val1)
00542         if python3 or type(val1) == unicode:
00543           val1 = val1.encode('utf-8')
00544           length = len(val1)
00545         buff.write(struct.pack('<I%ss'%length, length, val1))
00546       length = len(self.robot_state.multi_dof_joint_state.frame_ids)
00547       buff.write(_struct_I.pack(length))
00548       for val1 in self.robot_state.multi_dof_joint_state.frame_ids:
00549         length = len(val1)
00550         if python3 or type(val1) == unicode:
00551           val1 = val1.encode('utf-8')
00552           length = len(val1)
00553         buff.write(struct.pack('<I%ss'%length, length, val1))
00554       length = len(self.robot_state.multi_dof_joint_state.child_frame_ids)
00555       buff.write(_struct_I.pack(length))
00556       for val1 in self.robot_state.multi_dof_joint_state.child_frame_ids:
00557         length = len(val1)
00558         if python3 or type(val1) == unicode:
00559           val1 = val1.encode('utf-8')
00560           length = len(val1)
00561         buff.write(struct.pack('<I%ss'%length, length, val1))
00562       length = len(self.robot_state.multi_dof_joint_state.poses)
00563       buff.write(_struct_I.pack(length))
00564       for val1 in self.robot_state.multi_dof_joint_state.poses:
00565         _v5 = val1.position
00566         _x = _v5
00567         buff.write(_struct_3d.pack(_x.x, _x.y, _x.z))
00568         _v6 = val1.orientation
00569         _x = _v6
00570         buff.write(_struct_4d.pack(_x.x, _x.y, _x.z, _x.w))
00571       buff.write(_struct_i.pack(self.error_code.val))
00572     except struct.error as se: self._check_types(se)
00573     except TypeError as te: self._check_types(te)
00574 
00575   def deserialize_numpy(self, str, numpy):
00576     """
00577     unpack serialized message in str into this message instance using numpy for array types
00578     :param str: byte array of serialized message, ``str``
00579     :param numpy: numpy python module
00580     """
00581     try:
00582       if self.robot_state is None:
00583         self.robot_state = arm_navigation_msgs.msg.RobotState()
00584       if self.error_code is None:
00585         self.error_code = arm_navigation_msgs.msg.ArmNavigationErrorCodes()
00586       end = 0
00587       _x = self
00588       start = end
00589       end += 12
00590       (_x.robot_state.joint_state.header.seq, _x.robot_state.joint_state.header.stamp.secs, _x.robot_state.joint_state.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00591       start = end
00592       end += 4
00593       (length,) = _struct_I.unpack(str[start:end])
00594       start = end
00595       end += length
00596       if python3:
00597         self.robot_state.joint_state.header.frame_id = str[start:end].decode('utf-8')
00598       else:
00599         self.robot_state.joint_state.header.frame_id = str[start:end]
00600       start = end
00601       end += 4
00602       (length,) = _struct_I.unpack(str[start:end])
00603       self.robot_state.joint_state.name = []
00604       for i in range(0, length):
00605         start = end
00606         end += 4
00607         (length,) = _struct_I.unpack(str[start:end])
00608         start = end
00609         end += length
00610         if python3:
00611           val1 = str[start:end].decode('utf-8')
00612         else:
00613           val1 = str[start:end]
00614         self.robot_state.joint_state.name.append(val1)
00615       start = end
00616       end += 4
00617       (length,) = _struct_I.unpack(str[start:end])
00618       pattern = '<%sd'%length
00619       start = end
00620       end += struct.calcsize(pattern)
00621       self.robot_state.joint_state.position = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
00622       start = end
00623       end += 4
00624       (length,) = _struct_I.unpack(str[start:end])
00625       pattern = '<%sd'%length
00626       start = end
00627       end += struct.calcsize(pattern)
00628       self.robot_state.joint_state.velocity = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
00629       start = end
00630       end += 4
00631       (length,) = _struct_I.unpack(str[start:end])
00632       pattern = '<%sd'%length
00633       start = end
00634       end += struct.calcsize(pattern)
00635       self.robot_state.joint_state.effort = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
00636       _x = self
00637       start = end
00638       end += 8
00639       (_x.robot_state.multi_dof_joint_state.stamp.secs, _x.robot_state.multi_dof_joint_state.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
00640       start = end
00641       end += 4
00642       (length,) = _struct_I.unpack(str[start:end])
00643       self.robot_state.multi_dof_joint_state.joint_names = []
00644       for i in range(0, length):
00645         start = end
00646         end += 4
00647         (length,) = _struct_I.unpack(str[start:end])
00648         start = end
00649         end += length
00650         if python3:
00651           val1 = str[start:end].decode('utf-8')
00652         else:
00653           val1 = str[start:end]
00654         self.robot_state.multi_dof_joint_state.joint_names.append(val1)
00655       start = end
00656       end += 4
00657       (length,) = _struct_I.unpack(str[start:end])
00658       self.robot_state.multi_dof_joint_state.frame_ids = []
00659       for i in range(0, length):
00660         start = end
00661         end += 4
00662         (length,) = _struct_I.unpack(str[start:end])
00663         start = end
00664         end += length
00665         if python3:
00666           val1 = str[start:end].decode('utf-8')
00667         else:
00668           val1 = str[start:end]
00669         self.robot_state.multi_dof_joint_state.frame_ids.append(val1)
00670       start = end
00671       end += 4
00672       (length,) = _struct_I.unpack(str[start:end])
00673       self.robot_state.multi_dof_joint_state.child_frame_ids = []
00674       for i in range(0, length):
00675         start = end
00676         end += 4
00677         (length,) = _struct_I.unpack(str[start:end])
00678         start = end
00679         end += length
00680         if python3:
00681           val1 = str[start:end].decode('utf-8')
00682         else:
00683           val1 = str[start:end]
00684         self.robot_state.multi_dof_joint_state.child_frame_ids.append(val1)
00685       start = end
00686       end += 4
00687       (length,) = _struct_I.unpack(str[start:end])
00688       self.robot_state.multi_dof_joint_state.poses = []
00689       for i in range(0, length):
00690         val1 = geometry_msgs.msg.Pose()
00691         _v7 = val1.position
00692         _x = _v7
00693         start = end
00694         end += 24
00695         (_x.x, _x.y, _x.z,) = _struct_3d.unpack(str[start:end])
00696         _v8 = val1.orientation
00697         _x = _v8
00698         start = end
00699         end += 32
00700         (_x.x, _x.y, _x.z, _x.w,) = _struct_4d.unpack(str[start:end])
00701         self.robot_state.multi_dof_joint_state.poses.append(val1)
00702       start = end
00703       end += 4
00704       (self.error_code.val,) = _struct_i.unpack(str[start:end])
00705       return self
00706     except struct.error as e:
00707       raise genpy.DeserializationError(e) #most likely buffer underfill
00708 
00709 _struct_I = genpy.struct_I
00710 _struct_i = struct.Struct("<i")
00711 _struct_4d = struct.Struct("<4d")
00712 _struct_3I = struct.Struct("<3I")
00713 _struct_2I = struct.Struct("<2I")
00714 _struct_3d = struct.Struct("<3d")
00715 class GetRobotState(object):
00716   _type          = 'arm_navigation_msgs/GetRobotState'
00717   _md5sum = '9799d82a26586bf3963962b7c3038f40'
00718   _request_class  = GetRobotStateRequest
00719   _response_class = GetRobotStateResponse


arm_navigation_msgs
Author(s): Gil Jones
autogenerated on Thu Dec 12 2013 11:08:10