Rotator Controller

To provide moon tracking for my 70cm 4x crossed Yagi array and for my 23cm 2m dish, an Arduino Nano was programmed to control Yaesu G5500 and KR400/KR500 rotators. The latter were modified with relays switching each direction.

Schematic

The Arduino Nano takes serial commands from the PC Graphic User Interface (GUI) and controls the rotators. The standard potentiometer feedback is used to determine the rotator position. If it is found necessary, the controller software will provide a function to calibrate the actual position values and store in EEPROM,

Arduino Software Design Note

Commands are read from USB serial in GS232 like format “W az.i el.e “. Format is checked by frame length, header, range of azimuth and elevation. Azimuth and elevation step concurrently once commands are passed. 

The received data is then parsed into azimuth and elevation commands.

Every second the position of each rotator is calculated from the voltages from the two ends and the wiper. The average value from the last four seconds is compared with the commands to correct the position of each.

// Main Loop **//        
// 
// Main Loop executes every 100 ms
void loop()  {
  azimAvgDegs = getAzimDegs();      // get azimuth position
  elevAvgDegs = getElevDegs();   // get elevation position
  checkAzimuth();  
  checkElevation();  
  if (azimStopped == false) {
    correctAzimuth();               // includes checks for end of range and at target    
  }  
  if (elevStopped == false) {
    correctElevation();              // includes checks for end of range and at target    
  }  
// Look for new command every second  – tracking sent every 15 and 45 sec from PC
  if (tenthsCount == 0)  {          
 //   if ((azimCmd == 0) && (!elevStopped))  {
    receiveData();                  // receive command from PC time sync and tracking VB6    
  }  
  delay(100);
  maintainClock();  
}

A copy of the software (.zip) may be downloaded from https://www.dropbox.com/scl/fo/nsiyfbni7srk0pgby5tmp/AAoXyQOoi9O3y14mmO22quw?rlkey=uh6yhnytsvlopezq3tk1g996d&st=h1kxibnp&dl=0. The file is provided for information without guarantees as the suitability of the software for your application. It is provided as is and may contain defects and errors. Email questions may be answered. Otherwise, no support is provided. <mycallsign> at WIA.org.au

PC Time Sync and Tracking