 void loop()
 {
   digitalWrite(HbridgeEnablePin, HIGH);
-  double minTime_ms = 30;//Minimal time to have motor starting at maximum voltage
-  // read the analog in value:
+  // Read the analog in value
+  // The range was reduced 
   double sensorValueMin = 255;//0
   double sensorValueMax = 767;//1023
-  double deadBand = 0.05; // Should not be zero
+  double deadBand = 0.05; // Use to ensure zero speed. Should not be zero
   sensorValue = analogRead(analogInPin);
-  //alphaSigned = 2*((sensorValue-sensorValueMin)/(sensorValueMax - sensorValueMin)-0.5);  
+  // \todo: add a selection of voltage or serial input
+  // alphaSigned = 2*((sensorValue-sensorValueMin)/(sensorValueMax - sensorValueMin)-0.5);  
   double alpha = max(fabs(alphaSigned), deadBand);
   alpha = min(alpha, 1);
   if (alphaSigned>fabs(deadBand))
   {
+    // Forward rotation
     digitalWrite(HbridgeLogicPin1, HIGH);
     digitalWrite(HbridgeLogicPin2, LOW);
   }

 */
void serialEvent() {
  while (Serial.available()) {
    // get the new byte:
    char inChar = (char)Serial.read();
    // add it to the inputString:
    inputString += inChar;
    // if the incoming character is a newline, set a flag
    // so the main loop can do something about it:
    if (inChar == '\n') {
      stringComplete = true;

//    Serial.println(alphaSigned);   
    alpha = max(fabs(alphaSigned), deadBand);
    alpha = min(alpha, 1);
    if (alphaSigned>fabs(deadBand))
    {
      digitalWrite(HbridgeLogicPin1, HIGH);
      digitalWrite(HbridgeLogicPin2, LOW);
    }
    else 
    {
      if (alphaSigned<-fabs(deadBand))
      {
        digitalWrite(HbridgeLogicPin1, LOW);
        digitalWrite(HbridgeLogicPin2, HIGH);
      }
      else
      {
        digitalWrite(HbridgeLogicPin1, LOW);
        digitalWrite(HbridgeLogicPin2, LOW);
      }
    }
//    Serial.print("alpha = " );                       
//    Serial.println(alpha);   
    elapsedTime_ms = millis() - initialTime;
