void WirelessParser::processPacket(const WirelessPacket& packet, std::size_t lastReadPos) { //if this is a data packet if(packet.isDataPacket()) { //store the data packet with the packet collector m_packetCollector.addDataPacket(packet); } else if(packet.isDiscoveryPacket()) { //store the node discovery packet with the packet collector m_packetCollector.addNodeDiscoveryPacket(packet); } //if this is not a data packet else { //this could be a valid ASPP command response findMatchingResponse(packet, lastReadPos); } }