added ParsePacket