 const int Straight = 191;
 const int HalfRight = 223;
 const int HardRight = 255;
-/*  Servo range is 50 mm for brake, 100 mm for steering.
-    Servo is fully retracted on a pulse width of 2 ms;
+/*  Elcano Servo range is 50 mm for brake, 100 mm for steering.
+
+    Elcano servo has a hardware controller that moves to a
+    particular position based on a PWM signal from Arduino.
+    Wikispeed servo is the same, except that controller box has
+    buttons for extend, retract, or moving to three preset positions.
+    
+    Elcano servo is fully retracted on a pulse width of 2 ms;
     fully extended at 1 ms and centered at 1.5 ms.
     There is a deadband of 8 us.
     At 12v, servo operating speed is 56mm/s with no load or
     35 mm/s at maximum load.
-    
     The Arduino PWM signal is at 490 Hz or 2.04 ms.
     0 is always off; 255 always on. One step is 7.92 us.
     
+    Either servo has five wires, with observed bahavior of:
+    White: 0V
+    Yellow: 5V
+    Blue: 0-5V depending on position of servo.
+    Black: 12V while servo extends; 0V at rest or retracting.
+    Red:   12V while retracting; 0V at rest or extending.
+    The reading on the Blue line has hysteresis when Elcano sends a PWM signal; 
+    there appear to be different (PWM, position) pairs when retracting or extending.
+    Motor speed is probably controlled by the current on the red or black line.   
 */
 
   const int Motor = 0;

 // make loop faster
 // limit servo motion during loop to step size 
  unsigned long fred = millis();  
  Serial.print(fred - TimeNow);
  Serial.print(",");
  do  //  Delay so that loop is not faster than 10 Hz.
  {
    EndTime = millis();
  } while (EndTime < NextLoopTime_ms);
  Serial.print(EndTime - fred);
  Serial.print(",");
  Serial.print(NextLoopTime_ms);
  Serial.print(",");
  Serial.println(OutsideTime);
 

} 

void RampTest()
{
  static int Position[] ={ 0, 0, 0};
  const int i = Brakes;
    for (int j = 80; j <800; j += 20) /*Instrument[i].MinPosition; j<= Instrument[i].MaxPosition;
    j += Instrument[i].StepSize) */
    {
        Serial.print("Move up ");
        Instrument[i].move(j);
      
//       if( digitalRead(Instrument[i].EnablePin) == HIGH)
//       {
//           if (abs(Instrument[i].move(Position[i]) - Position[i]) < Instrument[i].CloseEnough)
//           {
//             if (Position[i] = Position[i]? 0: 1023;
//           }
//       }
        delay(500);
    }
    for (int j = Instrument[i].MaxPosition; j>= Instrument[i].MinPosition;
    j -= 20)
    {
         Serial.print("Move down ");
        Instrument[i].move(j);
        delay(500);
    }
 
}
