Changeset 112 for hvcontrol/src
- Timestamp:
- 09/24/09 11:28:59 (15 years ago)
- Location:
- hvcontrol/src
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
hvcontrol/src/ProcessIO.cc
r111 r112 619 619 else { 620 620 PrintMessage("Error: Could not set HV of board %d, chain %d, channel %d. Skipping channel\n",fHVBoard[Board]->GetBoardNumber(),Chain,Channel); 621 //SlowDataClass->NewEntry("Error");622 //SlowDataClass->AddToEntry("%s %d %d %d %d %.2f ",fHVBoard[Board]->BoardName,Board, Chain, Channel, Target, calib->DACToHV(Target,Board,Chain,Channel));621 SlowDataClass->NewEntry("Error"); 622 SlowDataClass->AddToEntry("%s %d %d %d %d %.2f ",fHVBoard[Board]->BoardName,Board, Chain, Channel, Target, calib->DACToHV(Target,Board,Chain,Channel)); 623 623 return false; 624 624 } 625 625 } 626 //SlowDataClass->NewEntry("Value");627 //SlowDataClass->AddToEntry("%s %d %d %d %d %.2f ",fHVBoard[Board]->BoardName,Board, Chain, Channel, Target, calib->DACToHV(Target,Board,Chain,Channel));626 SlowDataClass->NewEntry("Value"); 627 SlowDataClass->AddToEntry("%s %d %d %d %d %.2f ",fHVBoard[Board]->BoardName,Board, Chain, Channel, Target, calib->DACToHV(Target,Board,Chain,Channel)); 628 628 return true; 629 629 } … … 633 633 void ProcessIO::Monitor() { 634 634 635 static unsigned int MismatchCount, ErrorCount; 636 635 637 for (int i=0; i<NumHVBoards; i++) { 636 638 637 639 if (fHVBoard[i]->GetStatus() != 1) { 638 PrintMessage("Error: Monitor, could not read status of board %d\n", fHVBoard[i]->GetBoardNumber()); 640 PrintMessage("Error: Monitor could not read status of board %d\n", fHVBoard[i]->GetBoardNumber()); 641 sleep(1); 642 if (ErrorCount++ > 10) { 643 PrintMessage("Too many errors from HV monitor, terminating program after next command\n"); 644 Exit = true; 645 pthread_kill(SocketThread, SIGUSR1); 646 } 639 647 } 640 648 … … 645 653 646 654 if (!fHVBoard[i]->WrapOK) { 647 PrintMessage("Error: Wrap counter mismatch board %d\n",fHVBoard[i]->GetBoardNumber()); 655 if (MismatchCount++>10) PrintMessage("Error: Wrap counter mismatch board %d\n",fHVBoard[i]->GetBoardNumber()); 656 else PrintMessage("Too many wrap counter mismatches, stopping messages\n"); 648 657 } 649 658 -
hvcontrol/src/ProcessIO.h
r111 r112 45 45 pthread_t HVMonitor; // exit function sends signal to these threads 46 46 pthread_t SocketThread; 47 47 48 48 bool Verbose; 49 49 int Socket; // -1 if not connected
Note:
See TracChangeset
for help on using the changeset viewer.