Lines Matching refs:bytes
146 bytes = self._ReadPacket()
147 if not bytes: return None
148 if len(bytes) != struct.calcsize(STATUS_FORMAT) or bytes[0] != "\x10":
150 ord(bytes[0]), len(bytes))
153 status = dict(zip(STATUS_FIELDS, struct.unpack(STATUS_FORMAT, bytes)))
215 bytes = self._ReadPacket()
216 if not bytes: return None
217 if len(bytes) < 4 + 8 + 1 or bytes[0] < "\x20" or bytes[0] > "\x2F":
219 ord(bytes[0]), len(bytes))
222 seq, type, x, y = struct.unpack("BBBB", bytes[:4])
223 data = [struct.unpack(">hhhh", bytes[x:x+8])
224 for x in range(4, len(bytes) - 8, 8)]