Parsers all inertial data and stores it in a corresponding container
InertialParser( |
| ) |
Constructor for InertialParser
packetCollector | the InertialPacketCollector to be associated with this parser |
The InertialPacketCollector associated with this parser and it's parent device
The ResponseCollector associated with this parser and it's parent device
void processPacket( |
| ) |
Takes an InertialPacket, adds it to the data container if it is a data packet, or adds it to the appropriate handler depending on the packet type
packet | A verified, valid InertialPacket |
void findMatchingResponse( |
| ) |
Takes an InertialPacket and checks if the packet collector has any responses it is waiting on. If it does, and the packet matches the expected response, the packet is "given" to the packet collector.
packet | An InertialPacket to match against expected responses |
InertialDataFields parseFields( |
| ) |
Parses the InertialDataFields out of the InertialPacket and returns them in a container.
packet | The InertialPacket to parse the fields from |
A vector of InertialDataFields parsed from the packet
InertialParseResult parseAsPacket( |
| ) |
Takes a DataBuffer that has had its read position moved to the start of a packet and verifies that the bytes form a valid Inertial (MIP) packet
data | A DataBuffer with its read position at the start of a packet (0x7565) |
packet | An InertialPacket to hold all the packet information if the packet is verified from the DataBuffer |
An InertialParseResult describing if the packet was verified, or why it failed verification
bool findPacketInBytes( |
| ) |
Checks for packets after the current bytes buffer's read position (starting at the next byte, not the current one). If a packet is found, the packet is processed and the byte buffer's read position is moved. If a packet is not found, nothing changes in the byte buffer
data | The bytes to look through for a packet |
true if a MIP Inertial packet is found, false otherwise
void parse( |
| ) |
Takes a DataBuffer and finds the next MIP Inertial Packet, or the next command response that is expected by the base station.
If an ASPP packet is found, the packet will be stored in the WirelessPacketCollector If a command response is found and is expected, it will be handled and passed to the base station directly.
data | A DataBuffer containing bytes that should be parsed for MicroStrain packets |