- Timestamp:
- 03/29/11 15:08:34 (14 years ago)
- Location:
- fact/FADctrl
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
fact/FADctrl/FAD.h
r10212 r10263 46 46 static void LaunchEventThread(class FAD *); 47 47 pthread_t Thread; 48 float EventUpdateDelay;49 48 50 49 int Datafile; … … 92 91 int Pipe[2]; 93 92 int NumEventsRequested; // Number of events requested 93 float EventUpdateDelay; 94 94 std::vector<std::string> BoardList; 95 95 }; -
fact/FADctrl/FADBoard.cc
r10262 r10263 348 348 struct sockaddr_in SocketAddress; 349 349 struct BoardStatus PrevStatus; 350 time_t LastUpdate = 0; 350 351 int Ret; 351 352 … … 506 507 507 508 // Update DIM services if necessary 508 if (memcmp(PrevStatus.Temp, Status.Temp, sizeof(Status.Temp)) != 0) { 509 DIM_Temp->updateService(Status.Temp, sizeof(Status.Temp)); 510 } 511 if (memcmp(PrevStatus.DAC, Status.DAC, sizeof(Status.DAC)) != 0) { 512 DIM_DAC->updateService(Status.DAC, sizeof(Status.DAC)); 513 } 514 if (memcmp(PrevStatus.ROI, Status.ROI, sizeof(Status.ROI)) != 0) { 515 DIM_ROI->updateService(Status.ROI, sizeof(Status.ROI)); 516 } 517 if (PrevStatus.BoardID != Status.BoardID) { 518 DIM_ID->updateService(&Status.BoardID, sizeof(Status.BoardID)); 509 if (time(NULL) - LastUpdate > m->EventUpdateDelay) { 510 LastUpdate = time(NULL); 511 512 if (memcmp(PrevStatus.Temp, Status.Temp, sizeof(Status.Temp)) != 0) { 513 DIM_Temp->updateService(Status.Temp, sizeof(Status.Temp)); 514 } 515 if (memcmp(PrevStatus.DAC, Status.DAC, sizeof(Status.DAC)) != 0) { 516 DIM_DAC->updateService(Status.DAC, sizeof(Status.DAC)); 517 } 518 if (memcmp(PrevStatus.ROI, Status.ROI, sizeof(Status.ROI)) != 0) { 519 DIM_ROI->updateService(Status.ROI, sizeof(Status.ROI)); 520 } 521 if (PrevStatus.BoardID != Status.BoardID) { 522 DIM_ID->updateService(&Status.BoardID, sizeof(Status.BoardID)); 523 } 519 524 } 520 525 -
fact/FADctrl/History.txt
r10262 r10263 19 19 28/3/2011 Boards with communication error set themselves inactive 20 20 29/3/2011 Added Status message service for each board (removed several console messages in turn) 21 Limited update rate of slow control data to 1 second or interval set by 'update'
Note:
See TracChangeset
for help on using the changeset viewer.