#include <ArSickPacket.h>
Inheritance diagram for ArSickPacket:
This class reimplements some of the buf operations since the robot is little endian.
You can just look at the documentation for the ArBasePacket except for these functions here, setAddress, getAddress, verifyCheckSum, print, getID, and calcCheckSum.
Definition at line 43 of file ArSickPacket.h.
Public Member Functions | |
ArSickPacket (unsigned char sendingAddress=0) | |
Constructor. | |
ArTypes::Byte2 | calcCRC (void) |
returns the crc, probably used only internally | |
virtual void | duplicatePacket (ArSickPacket *packet) |
Duplicates the packet. | |
virtual void | finalizePacket (void) |
ArTypes::UByte | getID (void) |
returns the ID of the packet (first byte of data) | |
unsigned char | getReceivedAddress (void) |
Gets the address this packet was sent from (only use for receiving). | |
unsigned char | getSendingAddress (void) |
Sets the address to send this packet to (only use for sending). | |
ArTime | getTimeReceived (void) |
Gets the time the packet was received at. | |
virtual void | resetRead (void) |
void | setSendingAddress (unsigned char address) |
Sets the address to send this packet to (only use for sending). | |
void | setTimeReceived (ArTime timeReceived) |
Sets the time the packet was received at. | |
bool | verifyCRC (void) |
returns true if the crc matches what it should be | |
virtual | ~ArSickPacket () |
Destructor. | |
Protected Attributes | |
unsigned char | mySendingAddress |
ArTime | myTimeReceived |
|
Duplicates the packet. Copies the given packets buffer into the buffer of this packet, also sets this length and readlength to what the given packet has
Definition at line 123 of file ArSickPacket.cpp. |
|
Gets the address this packet was sent from (only use for receiving). This gets the address that this packet was received from. Note that this is only valid if this packet was received from a laser, if you want to know where a packet was addressed to use getSendingAdress instead.
Definition at line 69 of file ArSickPacket.cpp. |
|
Sets the address to send this packet to (only use for sending). This gets the address for use in sending packets, the address is what has been saved, then when a packet is finalizePacketd for sending, the address is put into the appropriate spot in the packet.
Definition at line 58 of file ArSickPacket.cpp. |
|
Sets the address to send this packet to (only use for sending). This sets the address for use in sending packets, the address is saved, then when a packet is finalizePacketd for sending, the address is put into the appropriate spot in the packet.
Definition at line 47 of file ArSickPacket.cpp. |