$search
00001 """autogenerated by genmsg_py from SetMixedPositionVelocityPidGainsRequest.msg. Do not edit.""" 00002 import roslib.message 00003 import struct 00004 00005 00006 class SetMixedPositionVelocityPidGainsRequest(roslib.message.Message): 00007 _md5sum = "ff95ce4d442c9454d3d943f0c999da89" 00008 _type = "sr_robot_msgs/SetMixedPositionVelocityPidGainsRequest" 00009 _has_header = False #flag to mark the presence of a Header object 00010 _full_text = """float64 position_p 00011 float64 position_i 00012 float64 position_d 00013 float64 position_i_clamp 00014 float64 min_velocity 00015 float64 max_velocity 00016 float64 position_deadband 00017 00018 float64 velocity_p 00019 float64 velocity_i 00020 float64 velocity_d 00021 float64 velocity_i_clamp 00022 float64 max_force 00023 00024 int32 friction_deadband 00025 00026 """ 00027 __slots__ = ['position_p','position_i','position_d','position_i_clamp','min_velocity','max_velocity','position_deadband','velocity_p','velocity_i','velocity_d','velocity_i_clamp','max_force','friction_deadband'] 00028 _slot_types = ['float64','float64','float64','float64','float64','float64','float64','float64','float64','float64','float64','float64','int32'] 00029 00030 def __init__(self, *args, **kwds): 00031 """ 00032 Constructor. Any message fields that are implicitly/explicitly 00033 set to None will be assigned a default value. The recommend 00034 use is keyword arguments as this is more robust to future message 00035 changes. You cannot mix in-order arguments and keyword arguments. 00036 00037 The available fields are: 00038 position_p,position_i,position_d,position_i_clamp,min_velocity,max_velocity,position_deadband,velocity_p,velocity_i,velocity_d,velocity_i_clamp,max_force,friction_deadband 00039 00040 @param args: complete set of field values, in .msg order 00041 @param kwds: use keyword arguments corresponding to message field names 00042 to set specific fields. 00043 """ 00044 if args or kwds: 00045 super(SetMixedPositionVelocityPidGainsRequest, self).__init__(*args, **kwds) 00046 #message fields cannot be None, assign default values for those that are 00047 if self.position_p is None: 00048 self.position_p = 0. 00049 if self.position_i is None: 00050 self.position_i = 0. 00051 if self.position_d is None: 00052 self.position_d = 0. 00053 if self.position_i_clamp is None: 00054 self.position_i_clamp = 0. 00055 if self.min_velocity is None: 00056 self.min_velocity = 0. 00057 if self.max_velocity is None: 00058 self.max_velocity = 0. 00059 if self.position_deadband is None: 00060 self.position_deadband = 0. 00061 if self.velocity_p is None: 00062 self.velocity_p = 0. 00063 if self.velocity_i is None: 00064 self.velocity_i = 0. 00065 if self.velocity_d is None: 00066 self.velocity_d = 0. 00067 if self.velocity_i_clamp is None: 00068 self.velocity_i_clamp = 0. 00069 if self.max_force is None: 00070 self.max_force = 0. 00071 if self.friction_deadband is None: 00072 self.friction_deadband = 0 00073 else: 00074 self.position_p = 0. 00075 self.position_i = 0. 00076 self.position_d = 0. 00077 self.position_i_clamp = 0. 00078 self.min_velocity = 0. 00079 self.max_velocity = 0. 00080 self.position_deadband = 0. 00081 self.velocity_p = 0. 00082 self.velocity_i = 0. 00083 self.velocity_d = 0. 00084 self.velocity_i_clamp = 0. 00085 self.max_force = 0. 00086 self.friction_deadband = 0 00087 00088 def _get_types(self): 00089 """ 00090 internal API method 00091 """ 00092 return self._slot_types 00093 00094 def serialize(self, buff): 00095 """ 00096 serialize message into buffer 00097 @param buff: buffer 00098 @type buff: StringIO 00099 """ 00100 try: 00101 _x = self 00102 buff.write(_struct_12di.pack(_x.position_p, _x.position_i, _x.position_d, _x.position_i_clamp, _x.min_velocity, _x.max_velocity, _x.position_deadband, _x.velocity_p, _x.velocity_i, _x.velocity_d, _x.velocity_i_clamp, _x.max_force, _x.friction_deadband)) 00103 except struct.error as se: self._check_types(se) 00104 except TypeError as te: self._check_types(te) 00105 00106 def deserialize(self, str): 00107 """ 00108 unpack serialized message in str into this message instance 00109 @param str: byte array of serialized message 00110 @type str: str 00111 """ 00112 try: 00113 end = 0 00114 _x = self 00115 start = end 00116 end += 100 00117 (_x.position_p, _x.position_i, _x.position_d, _x.position_i_clamp, _x.min_velocity, _x.max_velocity, _x.position_deadband, _x.velocity_p, _x.velocity_i, _x.velocity_d, _x.velocity_i_clamp, _x.max_force, _x.friction_deadband,) = _struct_12di.unpack(str[start:end]) 00118 return self 00119 except struct.error as e: 00120 raise roslib.message.DeserializationError(e) #most likely buffer underfill 00121 00122 00123 def serialize_numpy(self, buff, numpy): 00124 """ 00125 serialize message with numpy array types into buffer 00126 @param buff: buffer 00127 @type buff: StringIO 00128 @param numpy: numpy python module 00129 @type numpy module 00130 """ 00131 try: 00132 _x = self 00133 buff.write(_struct_12di.pack(_x.position_p, _x.position_i, _x.position_d, _x.position_i_clamp, _x.min_velocity, _x.max_velocity, _x.position_deadband, _x.velocity_p, _x.velocity_i, _x.velocity_d, _x.velocity_i_clamp, _x.max_force, _x.friction_deadband)) 00134 except struct.error as se: self._check_types(se) 00135 except TypeError as te: self._check_types(te) 00136 00137 def deserialize_numpy(self, str, numpy): 00138 """ 00139 unpack serialized message in str into this message instance using numpy for array types 00140 @param str: byte array of serialized message 00141 @type str: str 00142 @param numpy: numpy python module 00143 @type numpy: module 00144 """ 00145 try: 00146 end = 0 00147 _x = self 00148 start = end 00149 end += 100 00150 (_x.position_p, _x.position_i, _x.position_d, _x.position_i_clamp, _x.min_velocity, _x.max_velocity, _x.position_deadband, _x.velocity_p, _x.velocity_i, _x.velocity_d, _x.velocity_i_clamp, _x.max_force, _x.friction_deadband,) = _struct_12di.unpack(str[start:end]) 00151 return self 00152 except struct.error as e: 00153 raise roslib.message.DeserializationError(e) #most likely buffer underfill 00154 00155 _struct_I = roslib.message.struct_I 00156 _struct_12di = struct.Struct("<12di") 00157 """autogenerated by genmsg_py from SetMixedPositionVelocityPidGainsResponse.msg. Do not edit.""" 00158 import roslib.message 00159 import struct 00160 00161 00162 class SetMixedPositionVelocityPidGainsResponse(roslib.message.Message): 00163 _md5sum = "d41d8cd98f00b204e9800998ecf8427e" 00164 _type = "sr_robot_msgs/SetMixedPositionVelocityPidGainsResponse" 00165 _has_header = False #flag to mark the presence of a Header object 00166 _full_text = """ 00167 00168 """ 00169 __slots__ = [] 00170 _slot_types = [] 00171 00172 def __init__(self, *args, **kwds): 00173 """ 00174 Constructor. Any message fields that are implicitly/explicitly 00175 set to None will be assigned a default value. The recommend 00176 use is keyword arguments as this is more robust to future message 00177 changes. You cannot mix in-order arguments and keyword arguments. 00178 00179 The available fields are: 00180 00181 00182 @param args: complete set of field values, in .msg order 00183 @param kwds: use keyword arguments corresponding to message field names 00184 to set specific fields. 00185 """ 00186 if args or kwds: 00187 super(SetMixedPositionVelocityPidGainsResponse, self).__init__(*args, **kwds) 00188 00189 def _get_types(self): 00190 """ 00191 internal API method 00192 """ 00193 return self._slot_types 00194 00195 def serialize(self, buff): 00196 """ 00197 serialize message into buffer 00198 @param buff: buffer 00199 @type buff: StringIO 00200 """ 00201 try: 00202 pass 00203 except struct.error as se: self._check_types(se) 00204 except TypeError as te: self._check_types(te) 00205 00206 def deserialize(self, str): 00207 """ 00208 unpack serialized message in str into this message instance 00209 @param str: byte array of serialized message 00210 @type str: str 00211 """ 00212 try: 00213 end = 0 00214 return self 00215 except struct.error as e: 00216 raise roslib.message.DeserializationError(e) #most likely buffer underfill 00217 00218 00219 def serialize_numpy(self, buff, numpy): 00220 """ 00221 serialize message with numpy array types into buffer 00222 @param buff: buffer 00223 @type buff: StringIO 00224 @param numpy: numpy python module 00225 @type numpy module 00226 """ 00227 try: 00228 pass 00229 except struct.error as se: self._check_types(se) 00230 except TypeError as te: self._check_types(te) 00231 00232 def deserialize_numpy(self, str, numpy): 00233 """ 00234 unpack serialized message in str into this message instance using numpy for array types 00235 @param str: byte array of serialized message 00236 @type str: str 00237 @param numpy: numpy python module 00238 @type numpy: module 00239 """ 00240 try: 00241 end = 0 00242 return self 00243 except struct.error as e: 00244 raise roslib.message.DeserializationError(e) #most likely buffer underfill 00245 00246 _struct_I = roslib.message.struct_I 00247 class SetMixedPositionVelocityPidGains(roslib.message.ServiceDefinition): 00248 _type = 'sr_robot_msgs/SetMixedPositionVelocityPidGains' 00249 _md5sum = 'ff95ce4d442c9454d3d943f0c999da89' 00250 _request_class = SetMixedPositionVelocityPidGainsRequest 00251 _response_class = SetMixedPositionVelocityPidGainsResponse