Last active
April 2, 2018 19:22
-
-
Save araffin/2f0c89fd789264679504d7416b59e428 to your computer and use it in GitHub Desktop.
Order Enum
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// From https://github.com/sergionr2/RacingRobot | |
// replicated in https://github.com/araffin/cpp-arduino-serial | |
#ifndef ORDER_H | |
#define ORDER_H | |
// Define the orders that can be sent and received | |
enum Order { | |
HELLO = 0, // Hello order to initiate communication with the Arduino | |
SERVO = 1, // Command the Servomotor (control the direction of the car) | |
MOTOR = 2, // Command the Motor (control the speed of the car) | |
ALREADY_CONNECTED = 3, // Already connected to the Arduino | |
ERROR = 4, | |
RECEIVED = 5, // Aknowlegment message | |
STOP = 6, // Emergency stop | |
}; | |
typedef enum Order Order; | |
#endif |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment