 const int azDrvPin = 18;
 const int azSgnPin = 19;
 const int ppsPin = 6;
-const int updatePer = 1000;
 const float xtalTol = 20e-6;
 const float maxTimeTol = 0.5; // seconds
 const long maxTimeSyncAge = (long)( 0.5 + maxTimeTol / xtalTol );
-
+const long rotorUpdateInterval = 200000;
+const float deg2rad = 3.1415927 / 180.0;
 /*
  * Set addresses of EEPROM parameters 
  */


void ppsSvc() {
  if ( DEBUG ) {
    Serial.print( "." );
  }
  rotorUpdateFlg = true;

  // Set clock(s) to UTC time if a valid fix came in since the last PPS
  if ( DEBUG ) digitalClockDisplay();
  if ( gpsTimeValid && gpsTimeFlg ) {
    time_t oldTime = getTeensy3Time();
    setTime( gpsHr,gpsMin,gpsSec,gpsDay,gpsMon,gpsYr ); // "Library" time    

char aprs[APRSLEN], aprsBuf[APRSLEN];
int aprsIndex = 0;
boolean aprsRdy, aprsChkFlg, aprsErrFlg, aprsBufCurrent, aprsValid;
boolean aprsFlg, aprsNewFlg;
long aprsTime, lastAprsTime; // standard time in seconds with decimal fraction to ms
float aprsLat, aprsLon, aprsAlt, aprsVg, aprsHdg;
float lastAprsAlt; // needed to keep track of prior value to calculate Vz

char term[TERMLEN], aprsfiBuf[APRSFILEN], cmdBuf[CMDLEN];
int termIndex = 0;
