00001 """autogenerated by genmsg_py from DoorsDetectorCloudRequest.msg. Do not edit."""
00002 import roslib.message
00003 import struct
00004
00005 import geometry_msgs.msg
00006 import sensor_msgs.msg
00007 import std_msgs.msg
00008 import door_msgs.msg
00009
00010 class DoorsDetectorCloudRequest(roslib.message.Message):
00011 _md5sum = "46b5580ee042093a9a5254367bb8a4ee"
00012 _type = "door_handle_detector/DoorsDetectorCloudRequest"
00013 _has_header = False
00014 _full_text = """door_msgs/Door door
00015 sensor_msgs/PointCloud cloud
00016
00017 ================================================================================
00018 MSG: door_msgs/Door
00019 Header header
00020 geometry_msgs/Point32 frame_p1 ## position of the door frame
00021 geometry_msgs/Point32 frame_p2 ## position of the door frame
00022 geometry_msgs/Point32 door_p1 ## Ground plane projection of a point on the plane of the door
00023 geometry_msgs/Point32 door_p2 ## Ground plane projection of a point on the plane of the door
00024 geometry_msgs/Point32 handle ## Position of the door handle
00025 float32 height ## Height of the door
00026
00027 int32 UNKNOWN=0
00028
00029 int32 HINGE_P1=1
00030 int32 HINGE_P2=2
00031 int32 hinge
00032
00033 int32 ROT_DIR_CLOCKWISE=1
00034 int32 ROT_DIR_COUNTERCLOCKWISE=2
00035 int32 rot_dir
00036
00037 int32 LOCKED=1
00038 int32 LATCHED=2
00039 int32 UNLATCHED=3
00040 int32 latch_state
00041
00042 geometry_msgs/Vector3 travel_dir ## vector pointing in the direction the robot is going to travel through the door
00043 float32 weight ## @Sachin: what do we use this for?
00044
00045
00046
00047 ================================================================================
00048 MSG: std_msgs/Header
00049 # Standard metadata for higher-level stamped data types.
00050 # This is generally used to communicate timestamped data
00051 # in a particular coordinate frame.
00052 #
00053 # sequence ID: consecutively increasing ID
00054 uint32 seq
00055 #Two-integer timestamp that is expressed as:
00056 # * stamp.secs: seconds (stamp_secs) since epoch
00057 # * stamp.nsecs: nanoseconds since stamp_secs
00058 # time-handling sugar is provided by the client library
00059 time stamp
00060 #Frame this data is associated with
00061 # 0: no frame
00062 # 1: global frame
00063 string frame_id
00064
00065 ================================================================================
00066 MSG: geometry_msgs/Point32
00067 # This contains the position of a point in free space(with 32 bits of precision).
00068 # It is recommeded to use Point wherever possible instead of Point32.
00069 #
00070 # This recommendation is to promote interoperability.
00071 #
00072 # This message is designed to take up less space when sending
00073 # lots of points at once, as in the case of a PointCloud.
00074
00075 float32 x
00076 float32 y
00077 float32 z
00078 ================================================================================
00079 MSG: geometry_msgs/Vector3
00080 # This represents a vector in free space.
00081
00082 float64 x
00083 float64 y
00084 float64 z
00085 ================================================================================
00086 MSG: sensor_msgs/PointCloud
00087 # This message holds a collection of 3d points, plus optional additional
00088 # information about each point.
00089
00090 # Time of sensor data acquisition, coordinate frame ID.
00091 Header header
00092
00093 # Array of 3d points. Each Point32 should be interpreted as a 3d point
00094 # in the frame given in the header.
00095 geometry_msgs/Point32[] points
00096
00097 # Each channel should have the same number of elements as points array,
00098 # and the data in each channel should correspond 1:1 with each point.
00099 # Channel names in common practice are listed in ChannelFloat32.msg.
00100 ChannelFloat32[] channels
00101
00102 ================================================================================
00103 MSG: sensor_msgs/ChannelFloat32
00104 # This message is used by the PointCloud message to hold optional data
00105 # associated with each point in the cloud. The length of the values
00106 # array should be the same as the length of the points array in the
00107 # PointCloud, and each value should be associated with the corresponding
00108 # point.
00109
00110 # Channel names in existing practice include:
00111 # "u", "v" - row and column (respectively) in the left stereo image.
00112 # This is opposite to usual conventions but remains for
00113 # historical reasons. The newer PointCloud2 message has no
00114 # such problem.
00115 # "rgb" - For point clouds produced by color stereo cameras. uint8
00116 # (R,G,B) values packed into the least significant 24 bits,
00117 # in order.
00118 # "intensity" - laser or pixel intensity.
00119 # "distance"
00120
00121 # The channel name should give semantics of the channel (e.g.
00122 # "intensity" instead of "value").
00123 string name
00124
00125 # The values array should be 1-1 with the elements of the associated
00126 # PointCloud.
00127 float32[] values
00128
00129 """
00130 __slots__ = ['door','cloud']
00131 _slot_types = ['door_msgs/Door','sensor_msgs/PointCloud']
00132
00133 def __init__(self, *args, **kwds):
00134 """
00135 Constructor. Any message fields that are implicitly/explicitly
00136 set to None will be assigned a default value. The recommend
00137 use is keyword arguments as this is more robust to future message
00138 changes. You cannot mix in-order arguments and keyword arguments.
00139
00140 The available fields are:
00141 door,cloud
00142
00143 @param args: complete set of field values, in .msg order
00144 @param kwds: use keyword arguments corresponding to message field names
00145 to set specific fields.
00146 """
00147 if args or kwds:
00148 super(DoorsDetectorCloudRequest, self).__init__(*args, **kwds)
00149 #message fields cannot be None, assign default values for those that are
00150 if self.door is None:
00151 self.door = door_msgs.msg.Door()
00152 if self.cloud is None:
00153 self.cloud = sensor_msgs.msg.PointCloud()
00154 else:
00155 self.door = door_msgs.msg.Door()
00156 self.cloud = sensor_msgs.msg.PointCloud()
00157
00158 def _get_types(self):
00159 """
00160 internal API method
00161 """
00162 return self._slot_types
00163
00164 def serialize(self, buff):
00165 """
00166 serialize message into buffer
00167 @param buff: buffer
00168 @type buff: StringIO
00169 """
00170 try:
00171 _x = self
00172 buff.write(_struct_3I.pack(_x.door.header.seq, _x.door.header.stamp.secs, _x.door.header.stamp.nsecs))
00173 _x = self.door.header.frame_id
00174 length = len(_x)
00175 buff.write(struct.pack('<I%ss'%length, length, _x))
00176 _x = self
00177 buff.write(_struct_16f3i3df3I.pack(_x.door.frame_p1.x, _x.door.frame_p1.y, _x.door.frame_p1.z, _x.door.frame_p2.x, _x.door.frame_p2.y, _x.door.frame_p2.z, _x.door.door_p1.x, _x.door.door_p1.y, _x.door.door_p1.z, _x.door.door_p2.x, _x.door.door_p2.y, _x.door.door_p2.z, _x.door.handle.x, _x.door.handle.y, _x.door.handle.z, _x.door.height, _x.door.hinge, _x.door.rot_dir, _x.door.latch_state, _x.door.travel_dir.x, _x.door.travel_dir.y, _x.door.travel_dir.z, _x.door.weight, _x.cloud.header.seq, _x.cloud.header.stamp.secs, _x.cloud.header.stamp.nsecs))
00178 _x = self.cloud.header.frame_id
00179 length = len(_x)
00180 buff.write(struct.pack('<I%ss'%length, length, _x))
00181 length = len(self.cloud.points)
00182 buff.write(_struct_I.pack(length))
00183 for val1 in self.cloud.points:
00184 _x = val1
00185 buff.write(_struct_3f.pack(_x.x, _x.y, _x.z))
00186 length = len(self.cloud.channels)
00187 buff.write(_struct_I.pack(length))
00188 for val1 in self.cloud.channels:
00189 _x = val1.name
00190 length = len(_x)
00191 buff.write(struct.pack('<I%ss'%length, length, _x))
00192 length = len(val1.values)
00193 buff.write(_struct_I.pack(length))
00194 pattern = '<%sf'%length
00195 buff.write(struct.pack(pattern, *val1.values))
00196 except struct.error, se: self._check_types(se)
00197 except TypeError, te: self._check_types(te)
00198
00199 def deserialize(self, str):
00200 """
00201 unpack serialized message in str into this message instance
00202 @param str: byte array of serialized message
00203 @type str: str
00204 """
00205 try:
00206 if self.door is None:
00207 self.door = door_msgs.msg.Door()
00208 if self.cloud is None:
00209 self.cloud = sensor_msgs.msg.PointCloud()
00210 end = 0
00211 _x = self
00212 start = end
00213 end += 12
00214 (_x.door.header.seq, _x.door.header.stamp.secs, _x.door.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00215 start = end
00216 end += 4
00217 (length,) = _struct_I.unpack(str[start:end])
00218 start = end
00219 end += length
00220 self.door.header.frame_id = str[start:end]
00221 _x = self
00222 start = end
00223 end += 116
00224 (_x.door.frame_p1.x, _x.door.frame_p1.y, _x.door.frame_p1.z, _x.door.frame_p2.x, _x.door.frame_p2.y, _x.door.frame_p2.z, _x.door.door_p1.x, _x.door.door_p1.y, _x.door.door_p1.z, _x.door.door_p2.x, _x.door.door_p2.y, _x.door.door_p2.z, _x.door.handle.x, _x.door.handle.y, _x.door.handle.z, _x.door.height, _x.door.hinge, _x.door.rot_dir, _x.door.latch_state, _x.door.travel_dir.x, _x.door.travel_dir.y, _x.door.travel_dir.z, _x.door.weight, _x.cloud.header.seq, _x.cloud.header.stamp.secs, _x.cloud.header.stamp.nsecs,) = _struct_16f3i3df3I.unpack(str[start:end])
00225 start = end
00226 end += 4
00227 (length,) = _struct_I.unpack(str[start:end])
00228 start = end
00229 end += length
00230 self.cloud.header.frame_id = str[start:end]
00231 start = end
00232 end += 4
00233 (length,) = _struct_I.unpack(str[start:end])
00234 self.cloud.points = []
00235 for i in xrange(0, length):
00236 val1 = geometry_msgs.msg.Point32()
00237 _x = val1
00238 start = end
00239 end += 12
00240 (_x.x, _x.y, _x.z,) = _struct_3f.unpack(str[start:end])
00241 self.cloud.points.append(val1)
00242 start = end
00243 end += 4
00244 (length,) = _struct_I.unpack(str[start:end])
00245 self.cloud.channels = []
00246 for i in xrange(0, length):
00247 val1 = sensor_msgs.msg.ChannelFloat32()
00248 start = end
00249 end += 4
00250 (length,) = _struct_I.unpack(str[start:end])
00251 start = end
00252 end += length
00253 val1.name = str[start:end]
00254 start = end
00255 end += 4
00256 (length,) = _struct_I.unpack(str[start:end])
00257 pattern = '<%sf'%length
00258 start = end
00259 end += struct.calcsize(pattern)
00260 val1.values = struct.unpack(pattern, str[start:end])
00261 self.cloud.channels.append(val1)
00262 return self
00263 except struct.error, e:
00264 raise roslib.message.DeserializationError(e) #most likely buffer underfill
00265
00266
00267 def serialize_numpy(self, buff, numpy):
00268 """
00269 serialize message with numpy array types into buffer
00270 @param buff: buffer
00271 @type buff: StringIO
00272 @param numpy: numpy python module
00273 @type numpy module
00274 """
00275 try:
00276 _x = self
00277 buff.write(_struct_3I.pack(_x.door.header.seq, _x.door.header.stamp.secs, _x.door.header.stamp.nsecs))
00278 _x = self.door.header.frame_id
00279 length = len(_x)
00280 buff.write(struct.pack('<I%ss'%length, length, _x))
00281 _x = self
00282 buff.write(_struct_16f3i3df3I.pack(_x.door.frame_p1.x, _x.door.frame_p1.y, _x.door.frame_p1.z, _x.door.frame_p2.x, _x.door.frame_p2.y, _x.door.frame_p2.z, _x.door.door_p1.x, _x.door.door_p1.y, _x.door.door_p1.z, _x.door.door_p2.x, _x.door.door_p2.y, _x.door.door_p2.z, _x.door.handle.x, _x.door.handle.y, _x.door.handle.z, _x.door.height, _x.door.hinge, _x.door.rot_dir, _x.door.latch_state, _x.door.travel_dir.x, _x.door.travel_dir.y, _x.door.travel_dir.z, _x.door.weight, _x.cloud.header.seq, _x.cloud.header.stamp.secs, _x.cloud.header.stamp.nsecs))
00283 _x = self.cloud.header.frame_id
00284 length = len(_x)
00285 buff.write(struct.pack('<I%ss'%length, length, _x))
00286 length = len(self.cloud.points)
00287 buff.write(_struct_I.pack(length))
00288 for val1 in self.cloud.points:
00289 _x = val1
00290 buff.write(_struct_3f.pack(_x.x, _x.y, _x.z))
00291 length = len(self.cloud.channels)
00292 buff.write(_struct_I.pack(length))
00293 for val1 in self.cloud.channels:
00294 _x = val1.name
00295 length = len(_x)
00296 buff.write(struct.pack('<I%ss'%length, length, _x))
00297 length = len(val1.values)
00298 buff.write(_struct_I.pack(length))
00299 pattern = '<%sf'%length
00300 buff.write(val1.values.tostring())
00301 except struct.error, se: self._check_types(se)
00302 except TypeError, te: self._check_types(te)
00303
00304 def deserialize_numpy(self, str, numpy):
00305 """
00306 unpack serialized message in str into this message instance using numpy for array types
00307 @param str: byte array of serialized message
00308 @type str: str
00309 @param numpy: numpy python module
00310 @type numpy: module
00311 """
00312 try:
00313 if self.door is None:
00314 self.door = door_msgs.msg.Door()
00315 if self.cloud is None:
00316 self.cloud = sensor_msgs.msg.PointCloud()
00317 end = 0
00318 _x = self
00319 start = end
00320 end += 12
00321 (_x.door.header.seq, _x.door.header.stamp.secs, _x.door.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00322 start = end
00323 end += 4
00324 (length,) = _struct_I.unpack(str[start:end])
00325 start = end
00326 end += length
00327 self.door.header.frame_id = str[start:end]
00328 _x = self
00329 start = end
00330 end += 116
00331 (_x.door.frame_p1.x, _x.door.frame_p1.y, _x.door.frame_p1.z, _x.door.frame_p2.x, _x.door.frame_p2.y, _x.door.frame_p2.z, _x.door.door_p1.x, _x.door.door_p1.y, _x.door.door_p1.z, _x.door.door_p2.x, _x.door.door_p2.y, _x.door.door_p2.z, _x.door.handle.x, _x.door.handle.y, _x.door.handle.z, _x.door.height, _x.door.hinge, _x.door.rot_dir, _x.door.latch_state, _x.door.travel_dir.x, _x.door.travel_dir.y, _x.door.travel_dir.z, _x.door.weight, _x.cloud.header.seq, _x.cloud.header.stamp.secs, _x.cloud.header.stamp.nsecs,) = _struct_16f3i3df3I.unpack(str[start:end])
00332 start = end
00333 end += 4
00334 (length,) = _struct_I.unpack(str[start:end])
00335 start = end
00336 end += length
00337 self.cloud.header.frame_id = str[start:end]
00338 start = end
00339 end += 4
00340 (length,) = _struct_I.unpack(str[start:end])
00341 self.cloud.points = []
00342 for i in xrange(0, length):
00343 val1 = geometry_msgs.msg.Point32()
00344 _x = val1
00345 start = end
00346 end += 12
00347 (_x.x, _x.y, _x.z,) = _struct_3f.unpack(str[start:end])
00348 self.cloud.points.append(val1)
00349 start = end
00350 end += 4
00351 (length,) = _struct_I.unpack(str[start:end])
00352 self.cloud.channels = []
00353 for i in xrange(0, length):
00354 val1 = sensor_msgs.msg.ChannelFloat32()
00355 start = end
00356 end += 4
00357 (length,) = _struct_I.unpack(str[start:end])
00358 start = end
00359 end += length
00360 val1.name = str[start:end]
00361 start = end
00362 end += 4
00363 (length,) = _struct_I.unpack(str[start:end])
00364 pattern = '<%sf'%length
00365 start = end
00366 end += struct.calcsize(pattern)
00367 val1.values = numpy.frombuffer(str[start:end], dtype=numpy.float32, count=length)
00368 self.cloud.channels.append(val1)
00369 return self
00370 except struct.error, e:
00371 raise roslib.message.DeserializationError(e) #most likely buffer underfill
00372
00373 _struct_I = roslib.message.struct_I
00374 _struct_3I = struct.Struct("<3I")
00375 _struct_16f3i3df3I = struct.Struct("<16f3i3df3I")
00376 _struct_3f = struct.Struct("<3f")
00377 """autogenerated by genmsg_py from DoorsDetectorCloudResponse.msg. Do not edit."""
00378 import roslib.message
00379 import struct
00380
00381 import geometry_msgs.msg
00382 import std_msgs.msg
00383 import door_msgs.msg
00384
00385 class DoorsDetectorCloudResponse(roslib.message.Message):
00386 _md5sum = "814c1a77e8c0b7c5b3832dabceff607d"
00387 _type = "door_handle_detector/DoorsDetectorCloudResponse"
00388 _has_header = False #flag to mark the presence of a Header object
00389 _full_text = """door_msgs/Door[] doors
00390
00391
00392 ================================================================================
00393 MSG: door_msgs/Door
00394 Header header
00395 geometry_msgs/Point32 frame_p1 ## position of the door frame
00396 geometry_msgs/Point32 frame_p2 ## position of the door frame
00397 geometry_msgs/Point32 door_p1 ## Ground plane projection of a point on the plane of the door
00398 geometry_msgs/Point32 door_p2 ## Ground plane projection of a point on the plane of the door
00399 geometry_msgs/Point32 handle ## Position of the door handle
00400 float32 height ## Height of the door
00401
00402 int32 UNKNOWN=0
00403
00404 int32 HINGE_P1=1
00405 int32 HINGE_P2=2
00406 int32 hinge
00407
00408 int32 ROT_DIR_CLOCKWISE=1
00409 int32 ROT_DIR_COUNTERCLOCKWISE=2
00410 int32 rot_dir
00411
00412 int32 LOCKED=1
00413 int32 LATCHED=2
00414 int32 UNLATCHED=3
00415 int32 latch_state
00416
00417 geometry_msgs/Vector3 travel_dir ## vector pointing in the direction the robot is going to travel through the door
00418 float32 weight ## @Sachin: what do we use this for?
00419
00420
00421
00422 ================================================================================
00423 MSG: std_msgs/Header
00424 # Standard metadata for higher-level stamped data types.
00425 # This is generally used to communicate timestamped data
00426 # in a particular coordinate frame.
00427 #
00428 # sequence ID: consecutively increasing ID
00429 uint32 seq
00430 #Two-integer timestamp that is expressed as:
00431 # * stamp.secs: seconds (stamp_secs) since epoch
00432 # * stamp.nsecs: nanoseconds since stamp_secs
00433 # time-handling sugar is provided by the client library
00434 time stamp
00435 #Frame this data is associated with
00436 # 0: no frame
00437 # 1: global frame
00438 string frame_id
00439
00440 ================================================================================
00441 MSG: geometry_msgs/Point32
00442 # This contains the position of a point in free space(with 32 bits of precision).
00443 # It is recommeded to use Point wherever possible instead of Point32.
00444 #
00445 # This recommendation is to promote interoperability.
00446 #
00447 # This message is designed to take up less space when sending
00448 # lots of points at once, as in the case of a PointCloud.
00449
00450 float32 x
00451 float32 y
00452 float32 z
00453 ================================================================================
00454 MSG: geometry_msgs/Vector3
00455 # This represents a vector in free space.
00456
00457 float64 x
00458 float64 y
00459 float64 z
00460 """
00461 __slots__ = ['doors']
00462 _slot_types = ['door_msgs/Door[]']
00463
00464 def __init__(self, *args, **kwds):
00465 """
00466 Constructor. Any message fields that are implicitly/explicitly
00467 set to None will be assigned a default value. The recommend
00468 use is keyword arguments as this is more robust to future message
00469 changes. You cannot mix in-order arguments and keyword arguments.
00470
00471 The available fields are:
00472 doors
00473
00474 @param args: complete set of field values, in .msg order
00475 @param kwds: use keyword arguments corresponding to message field names
00476 to set specific fields.
00477 """
00478 if args or kwds:
00479 super(DoorsDetectorCloudResponse, self).__init__(*args, **kwds)
00480 #message fields cannot be None, assign default values for those that are
00481 if self.doors is None:
00482 self.doors = []
00483 else:
00484 self.doors = []
00485
00486 def _get_types(self):
00487 """
00488 internal API method
00489 """
00490 return self._slot_types
00491
00492 def serialize(self, buff):
00493 """
00494 serialize message into buffer
00495 @param buff: buffer
00496 @type buff: StringIO
00497 """
00498 try:
00499 length = len(self.doors)
00500 buff.write(_struct_I.pack(length))
00501 for val1 in self.doors:
00502 _v1 = val1.header
00503 buff.write(_struct_I.pack(_v1.seq))
00504 _v2 = _v1.stamp
00505 _x = _v2
00506 buff.write(_struct_2I.pack(_x.secs, _x.nsecs))
00507 _x = _v1.frame_id
00508 length = len(_x)
00509 buff.write(struct.pack('<I%ss'%length, length, _x))
00510 _v3 = val1.frame_p1
00511 _x = _v3
00512 buff.write(_struct_3f.pack(_x.x, _x.y, _x.z))
00513 _v4 = val1.frame_p2
00514 _x = _v4
00515 buff.write(_struct_3f.pack(_x.x, _x.y, _x.z))
00516 _v5 = val1.door_p1
00517 _x = _v5
00518 buff.write(_struct_3f.pack(_x.x, _x.y, _x.z))
00519 _v6 = val1.door_p2
00520 _x = _v6
00521 buff.write(_struct_3f.pack(_x.x, _x.y, _x.z))
00522 _v7 = val1.handle
00523 _x = _v7
00524 buff.write(_struct_3f.pack(_x.x, _x.y, _x.z))
00525 _x = val1
00526 buff.write(_struct_f3i.pack(_x.height, _x.hinge, _x.rot_dir, _x.latch_state))
00527 _v8 = val1.travel_dir
00528 _x = _v8
00529 buff.write(_struct_3d.pack(_x.x, _x.y, _x.z))
00530 buff.write(_struct_f.pack(val1.weight))
00531 except struct.error, se: self._check_types(se)
00532 except TypeError, te: self._check_types(te)
00533
00534 def deserialize(self, str):
00535 """
00536 unpack serialized message in str into this message instance
00537 @param str: byte array of serialized message
00538 @type str: str
00539 """
00540 try:
00541 end = 0
00542 start = end
00543 end += 4
00544 (length,) = _struct_I.unpack(str[start:end])
00545 self.doors = []
00546 for i in xrange(0, length):
00547 val1 = door_msgs.msg.Door()
00548 _v9 = val1.header
00549 start = end
00550 end += 4
00551 (_v9.seq,) = _struct_I.unpack(str[start:end])
00552 _v10 = _v9.stamp
00553 _x = _v10
00554 start = end
00555 end += 8
00556 (_x.secs, _x.nsecs,) = _struct_2I.unpack(str[start:end])
00557 start = end
00558 end += 4
00559 (length,) = _struct_I.unpack(str[start:end])
00560 start = end
00561 end += length
00562 _v9.frame_id = str[start:end]
00563 _v11 = val1.frame_p1
00564 _x = _v11
00565 start = end
00566 end += 12
00567 (_x.x, _x.y, _x.z,) = _struct_3f.unpack(str[start:end])
00568 _v12 = val1.frame_p2
00569 _x = _v12
00570 start = end
00571 end += 12
00572 (_x.x, _x.y, _x.z,) = _struct_3f.unpack(str[start:end])
00573 _v13 = val1.door_p1
00574 _x = _v13
00575 start = end
00576 end += 12
00577 (_x.x, _x.y, _x.z,) = _struct_3f.unpack(str[start:end])
00578 _v14 = val1.door_p2
00579 _x = _v14
00580 start = end
00581 end += 12
00582 (_x.x, _x.y, _x.z,) = _struct_3f.unpack(str[start:end])
00583 _v15 = val1.handle
00584 _x = _v15
00585 start = end
00586 end += 12
00587 (_x.x, _x.y, _x.z,) = _struct_3f.unpack(str[start:end])
00588 _x = val1
00589 start = end
00590 end += 16
00591 (_x.height, _x.hinge, _x.rot_dir, _x.latch_state,) = _struct_f3i.unpack(str[start:end])
00592 _v16 = val1.travel_dir
00593 _x = _v16
00594 start = end
00595 end += 24
00596 (_x.x, _x.y, _x.z,) = _struct_3d.unpack(str[start:end])
00597 start = end
00598 end += 4
00599 (val1.weight,) = _struct_f.unpack(str[start:end])
00600 self.doors.append(val1)
00601 return self
00602 except struct.error, e:
00603 raise roslib.message.DeserializationError(e) #most likely buffer underfill
00604
00605
00606 def serialize_numpy(self, buff, numpy):
00607 """
00608 serialize message with numpy array types into buffer
00609 @param buff: buffer
00610 @type buff: StringIO
00611 @param numpy: numpy python module
00612 @type numpy module
00613 """
00614 try:
00615 length = len(self.doors)
00616 buff.write(_struct_I.pack(length))
00617 for val1 in self.doors:
00618 _v17 = val1.header
00619 buff.write(_struct_I.pack(_v17.seq))
00620 _v18 = _v17.stamp
00621 _x = _v18
00622 buff.write(_struct_2I.pack(_x.secs, _x.nsecs))
00623 _x = _v17.frame_id
00624 length = len(_x)
00625 buff.write(struct.pack('<I%ss'%length, length, _x))
00626 _v19 = val1.frame_p1
00627 _x = _v19
00628 buff.write(_struct_3f.pack(_x.x, _x.y, _x.z))
00629 _v20 = val1.frame_p2
00630 _x = _v20
00631 buff.write(_struct_3f.pack(_x.x, _x.y, _x.z))
00632 _v21 = val1.door_p1
00633 _x = _v21
00634 buff.write(_struct_3f.pack(_x.x, _x.y, _x.z))
00635 _v22 = val1.door_p2
00636 _x = _v22
00637 buff.write(_struct_3f.pack(_x.x, _x.y, _x.z))
00638 _v23 = val1.handle
00639 _x = _v23
00640 buff.write(_struct_3f.pack(_x.x, _x.y, _x.z))
00641 _x = val1
00642 buff.write(_struct_f3i.pack(_x.height, _x.hinge, _x.rot_dir, _x.latch_state))
00643 _v24 = val1.travel_dir
00644 _x = _v24
00645 buff.write(_struct_3d.pack(_x.x, _x.y, _x.z))
00646 buff.write(_struct_f.pack(val1.weight))
00647 except struct.error, se: self._check_types(se)
00648 except TypeError, te: self._check_types(te)
00649
00650 def deserialize_numpy(self, str, numpy):
00651 """
00652 unpack serialized message in str into this message instance using numpy for array types
00653 @param str: byte array of serialized message
00654 @type str: str
00655 @param numpy: numpy python module
00656 @type numpy: module
00657 """
00658 try:
00659 end = 0
00660 start = end
00661 end += 4
00662 (length,) = _struct_I.unpack(str[start:end])
00663 self.doors = []
00664 for i in xrange(0, length):
00665 val1 = door_msgs.msg.Door()
00666 _v25 = val1.header
00667 start = end
00668 end += 4
00669 (_v25.seq,) = _struct_I.unpack(str[start:end])
00670 _v26 = _v25.stamp
00671 _x = _v26
00672 start = end
00673 end += 8
00674 (_x.secs, _x.nsecs,) = _struct_2I.unpack(str[start:end])
00675 start = end
00676 end += 4
00677 (length,) = _struct_I.unpack(str[start:end])
00678 start = end
00679 end += length
00680 _v25.frame_id = str[start:end]
00681 _v27 = val1.frame_p1
00682 _x = _v27
00683 start = end
00684 end += 12
00685 (_x.x, _x.y, _x.z,) = _struct_3f.unpack(str[start:end])
00686 _v28 = val1.frame_p2
00687 _x = _v28
00688 start = end
00689 end += 12
00690 (_x.x, _x.y, _x.z,) = _struct_3f.unpack(str[start:end])
00691 _v29 = val1.door_p1
00692 _x = _v29
00693 start = end
00694 end += 12
00695 (_x.x, _x.y, _x.z,) = _struct_3f.unpack(str[start:end])
00696 _v30 = val1.door_p2
00697 _x = _v30
00698 start = end
00699 end += 12
00700 (_x.x, _x.y, _x.z,) = _struct_3f.unpack(str[start:end])
00701 _v31 = val1.handle
00702 _x = _v31
00703 start = end
00704 end += 12
00705 (_x.x, _x.y, _x.z,) = _struct_3f.unpack(str[start:end])
00706 _x = val1
00707 start = end
00708 end += 16
00709 (_x.height, _x.hinge, _x.rot_dir, _x.latch_state,) = _struct_f3i.unpack(str[start:end])
00710 _v32 = val1.travel_dir
00711 _x = _v32
00712 start = end
00713 end += 24
00714 (_x.x, _x.y, _x.z,) = _struct_3d.unpack(str[start:end])
00715 start = end
00716 end += 4
00717 (val1.weight,) = _struct_f.unpack(str[start:end])
00718 self.doors.append(val1)
00719 return self
00720 except struct.error, e:
00721 raise roslib.message.DeserializationError(e) #most likely buffer underfill
00722
00723 _struct_I = roslib.message.struct_I
00724 _struct_f = struct.Struct("<f")
00725 _struct_f3i = struct.Struct("<f3i")
00726 _struct_3f = struct.Struct("<3f")
00727 _struct_2I = struct.Struct("<2I")
00728 _struct_3d = struct.Struct("<3d")
00729 class DoorsDetectorCloud(roslib.message.ServiceDefinition):
00730 _type = 'door_handle_detector/DoorsDetectorCloud'
00731 _md5sum = '0dadc6e3af89de943ea049368f297d58'
00732 _request_class = DoorsDetectorCloudRequest
00733 _response_class = DoorsDetectorCloudResponse