 
 enum COMMAND {
   NONE = -1, 
-  TURN_HEAD = 0, // value = servo microseconds
-  SONAR = 1,        
+  TURN_HEAD, // value = servo microseconds
+  SONAR,  
+  SET_MOTOR_LEFT,    // value -255 - 255
+  SET_MOTOR_RIGHT,
+  SET_MOTORS, 
   COMMAND_MAX
 } currentCommand;
 

#define SERVO_WAIT_TIME_MILLIS 30
#define SONAR_WAIT_TIME_MILLIS 30

#define SERVO_MIN_MS 600
#define SERVO_MAX_MS 2400

#define COMMAND_BUFFER_LENGTH 12

Servo servo;

NewPing sonar(TRIGGER_PIN, ECHO_PIN, MAX_DISTANCE);


/**

COMMAND SYNTAX:
===============
"[COMMAND];[VALUE]"

COMMANDS AND VALUES:
====================
-1 NONE
0 TURN HEAD (600 - 2400)
1 SONAR PING (no value)
2 SET LEFT MOTOR SPEED (-255 - 255) 
3 SET RIGHT MOTOR SPEED (-255 - 255)
4 SET SPEED FOR BOTH MOTORS (-255 - 255)

*/



#include <Servo.h> 
#include <NewPing.h>
#include <AFMotor.h>

#define BAUD_RATE 115200
#define SERVO_HEAD 10
