#use eziopk25.lib

#define NUMRELAY 2

void main() {
  int i;

  //	initially, turn off all the high current output
  for (i = 0; i < NUMRELAY; ++i) {
    eioBrdRelay(i,0);
  }
  
  while (1) {
    for (i = 0; i < NUMRELAY; ++i) {
      printf("press a key to energize channel %d\n",i);
      while (!kbhit()) hitwd();
      getchar();
      eioBrdRelay(i,1);
      printf("press a key to deenergize channel %d\n",i);
      while (!kbhit()) hitwd();
      getchar();
      eioBrdRelay(i,0);
    }
  }
}