45 #include <boost/thread.hpp> 61 for (
int i = 0; i < 8; ++i) { data[i] = 0x00; }
74 virtual void connect() = 0;
79 virtual void disconnect() = 0;
88 virtual int read(
unsigned char* buffer,
int size) = 0;
97 virtual int write(
unsigned char* buffer,
int size) = 0;
104 void getPacket(
Packet &packet);
111 void sendPacket(
Packet &packet);
127 unsigned char computeChecksum(
unsigned char* usb_packet);
135 DEFINE_EXCEPTION(PacketRetrievalException,
"Error retrieving a packet from the" 136 " SegwayRMP: ",
"Unspecified");
DEFINE_EXCEPTION(PacketRetrievalException,"Error retrieving a packet from the"" SegwayRMP: ","Unspecified")
std::vector< unsigned char > data_buffer