   motor.setM2Speed(0);
 }
 
-// Movement helpers
-int speedToPower(uint8_t speed) {
-  int v;
-  switch(speed) {
-    case 1:
-      v = 150;
-      break;
-    case 2:
-      v = 250;
-      break;
-    case 3:
-      v = 300;
-      break;
-    default:
-      v = 0;
-      break;
-  }
-  
-  // Return a safe motor power
-  return motorProtection(v);
-}
-
 // Emergency checks
 int motorProtection(int v) {
-  if (v <= MAX_POWER && v >= MIN_POWER) {
+  if (v >= 0 && v <= MAX_POWER) {
     return v;
   } else {
     Serial.println("DANGER: too much V!");


#define BUFFSIZE   128
#define MAX_POWER  400
#define MIN_POWER -400

// Command interpreter logic
const static boolean DEBUG = false;


  if (bytesRead == 2) {
    // Send commands to internal controller
    jeepCommandInterpreter(extractMovement(), extractSpeed());
    resetBuffer();
  }
}
