UART Driver to receive asynchronous Serial Comms from a Raspberry Pi and parse the results.
SerialComms.h
- Committer:
- sk398
- Date:
- 2016-02-15
- Revision:
- 0:8ac1280934b4
- Child:
- 1:bf3fb80028d8
File content as of revision 0:8ac1280934b4:
#ifndef SERIAL_COMMS_H #define SERIAL_COMMS_H #define SERIAL_BAUD_RATE 115200 #define NUM_BYTES_RECEIVING 4 #define TRUE 1 #define FALSE 0 class SerialComms { public: SerialComms(Serial *HLC_Conn); int *returnMotorSpeeds(); private: bool dataUpdate; int receiverBuffer[NUM_BYTES_RECEIVING]; Serial *_HLC_Conn; void incoming(); protected: }; #endif