Changeset 11014 for trunk/FACT++/src
- Timestamp:
- 06/13/11 17:06:33 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/FACT++/src/fadctrl.cc
r10997 r11014 563 563 bool Check(const uint32_t *dat, uint32_t maxaddr, uint32_t maxval) 564 564 { 565 if (dat[0]> FAD::kMaxRegAddr)565 if (dat[0]>maxaddr) 566 566 { 567 567 ostringstream msg; … … 571 571 } 572 572 573 if (dat[1]> FAD::kMaxRegValue)573 if (dat[1]>maxval) 574 574 { 575 575 ostringstream msg; … … 603 603 return T::kSM_FatalError; 604 604 605 // ---- was uint32_t606 605 const int32_t *dat = evt.Ptr<int32_t>(); 607 606 608 // ---- -1 for all609 //if (!Check(dat, FAD::kMaxRoiAddr, FAD::kMaxRoiValue))610 // return T::GetCurrentState();611 612 607 for (BoardList::iterator i=fBoards.begin(); i!=fBoards.end(); i++) 613 i->second.second->CmdSetRoi(dat[0], dat[1]); 608 if (!i->second.second->CmdSetRoi(dat[0], dat[1])) 609 { 610 ostringstream msg; 611 msg << hex << "Channel " << dat[0] << " or Value " << dat[1] << " out of range."; 612 T::Error(msg); 613 return false; 614 } 615 614 616 615 617 return T::GetCurrentState(); … … 835 837 } 836 838 837 T::Out() << " Thread:";839 T::Out() << "Event builder thread:"; 838 840 if (!IsThreadRunning()) 839 841 T::Out() << " not"; … … 1027 1029 public: 1028 1030 StateMachineFAD(ostream &out=cout) : 1029 T(out, "FAD_CONTROL"), EventBuilderWrapper( static_cast<MessageImp&>(*this)), ba::io_service::work(static_cast<ba::io_service&>(*this)),1031 T(out, "FAD_CONTROL"), EventBuilderWrapper(*static_cast<MessageImp*>(this)), ba::io_service::work(static_cast<ba::io_service&>(*this)), 1030 1032 fStatus1(40), fStatus2(40), 1031 1033 fDimConnection("FAD_CONTROL/CONNECTIONS", "C:41", "")
Note:
See TracChangeset
for help on using the changeset viewer.