#ifndef TPCCOMMANDCODERREADBACK_H #define TPCCOMMANDCODERREADBACK_H #include "RCUCommandCoder.h" #include "AltroCommandCoder.h" #include "BoardControllerCommandCoder.h" #include "RCUControlEngine.h" #include "CommandCoderBase.hpp" #include "../Container/RcuContainer.h" #include #include #include using namespace std; class TPCCommandCoderReadback:public CommandCoderBase { public: TPCCommandCoderReadback(); virtual ~TPCCommandCoderReadback(); virtual uint32_t* getDataBlock(); virtual int32_t createDataBlock(char* target, int tag); virtual vector& getError() { return fError; }; virtual std::string& getCoCoInfo() { return fVersion; }; virtual void reset(); void setBranch(uint32_t branch) { fBranch = branch; }; void setFec(uint32_t fec) { fFec = fec; }; void setAltro(uint32_t altro) { fAltro = altro; }; uint32_t getBranch() { return fBranch; }; uint32_t getFec() { return fFec; }; uint32_t getAltro() { return fAltro; }; private: int strtonum(string number); RcuContainer *fDataBlock;// The Data to be sent to RCU RCUCommandCoder *fRCU; // RCU Command Coder AltroCommandCoder *fALTRO; // ALTRO Command Coder BoardControllerCommandCoder *fBC; // BC Command Coder RCUControlEngine *fRCUce; // RCU Control Engine string fVersion; // TPC Command Coder Version string vector fError; // Error string uint32_t fBranch; uint32_t fFec; uint32_t fAltro; uint32_t fFwVersion; }; //=========================================================================== // The interface to the ICL: extern "C" { CommandCoderBase *getCoCoInst(void); } #endif // TPCCOMMANDCODERREADBACK_H