/********************************************************************\ Name: HVConfig.cc Created by: Sebastian Commichau, November 2008 commichau@phys.ethz.ch Contents: Class reading the HV utility configuration file \********************************************************************/ #include "HVConfig.h" HVConfig::HVConfig(const char *configfile) { // Read configuration file FILE *f; if ((f = fopen(configfile,"r")) == NULL) { printf("Could not open configuration file: %s\n", configfile); throw; } printf("Opening configuration file: %s\n", configfile); // Determine number of entries in 'Boards' card and allocate memeory NumHVBoards = (int) ReadCard("Boards", NULL, 'n', f); fUSBDevice = new char* [NumHVBoards]; for (int i=0; i1 read array) while ((card_val=strtok(NULL," \t\n"))!=NULL && card_val[0]!='#' && Count++