 
 Razorboard razor;
 
+const unsigned short GYRO_SAMPLING = 90; //to be optimized experimentally
+
 void setup() {
   car.begin();
   frontSonar.attach(FRONT_US_TRIG_PIN, FRONT_US_ECHO_PIN);

  encoder.attach(ENCODER_DIG_PIN);
  encoder.begin(); //start counting
  gyro.attach();
  gyro.begin(); //start measuring
  razor.attach(&Serial3);
  pinMode(BT_STATE_PIN, INPUT);
  Serial2.begin(9600);

        int degrees = input.substring(1).toInt();
        car.setAngle(degrees);
      } else if (input.startsWith("h")) {
        gyro.begin(GYRO_SAMPLING);
      } else {
        Serial2.println(encodedNetstring("Bad input"));
      }
