00001 #ifndef PIXELFECCONFIGINTERFACE_H
00002 #define PIXELFECCONFIGINTERFACE_H
00003
00012 #include <vector>
00013 #include <string>
00014 #include "CalibFormats/SiPixelObjects/interface/PixelHdwAddress.h"
00015
00016
00017 namespace pos{
00024 class PixelFECConfigInterface{
00025
00026 public:
00027
00028 PixelFECConfigInterface(){};
00029
00030 virtual ~PixelFECConfigInterface(){};
00031
00032
00033
00034
00035 virtual void setMaskAndTrimAll(const PixelHdwAddress& theROC,
00036 const std::vector<unsigned char>& allPixels,
00037 const bool buffermode=false)=0;
00038
00039 virtual void setDcolEnableAll(const PixelHdwAddress& theROC,
00040 unsigned char maskAndTrim,
00041 const bool buffermode=false )=0;
00042
00043
00044
00045
00046
00047
00048
00049
00050 virtual void setAllDAC(const PixelHdwAddress& theROC,
00051 const std::vector<unsigned int>& dacs,
00052 const bool buffermode=false) = 0;
00053
00054 virtual int roctrimload(int mfec, int fecchannel,
00055 int hubaddress, int portaddress, int rocid,
00056 const std::vector<unsigned char>& allPixels)=0;
00057
00058 virtual int rocinit(int mfec, int fecchannel,
00059 int hubaddress, int portaddress, int rocid,
00060 int mask, int trim)=0;
00061
00062 virtual int injectrstroc(const int mfec, const int bitstate)=0;
00063 virtual int injecttrigger(const int mfec, const int bitstate)=0;
00064 virtual int injectrsttbm(const int mfec, const int bitstate)=0;
00065 virtual int injectrstcsr(const int mfec, const int bitstate)=0;
00066 virtual int enablecallatency(const int mfec, const int bitstate)=0;
00067 virtual int disableexttrigger(const int mfec, const int bitstate)=0;
00068 virtual int loopnormtrigger(const int mfec, const int bitstate)=0;
00069 virtual int loopcaltrigger(const int mfec, const int bitstate)=0;
00070 virtual int callatencycount(const int mfec, const int latency)=0;
00071 virtual int getversion(const int mfec, unsigned long *data)=0;
00072 virtual int getversion(unsigned long *data)=0;
00073
00074 virtual int progdac(int mfec, int fecchannel,
00075 int hubaddress, int portaddress, int rocid,
00076 int dacaddress, int dacvalue,
00077 bool buffermode=false)=0;
00078
00079 virtual int clrcal(int mfec, int fecchannel,
00080 int hubaddress, int portaddress, int rocid,
00081 bool buffermode=false)=0;
00082
00083
00084 virtual int calpix(int mfec, int mfecchannel, int hubaddress,
00085 int portaddress,
00086 int rocid,
00087 int coladdr, int rowaddress,
00088 int caldata,
00089 bool buffermode=false)=0;
00090
00091 virtual int tbmcmd(int mfec, int fecchannel,
00092 int tbmchannel, int hubaddress, int portaddress,
00093 int offset, int databyte, int direction)=0;
00094
00095
00096 virtual int dcolenable(int mfec, int mfecchannel,
00097 int hubaddress, int portaddress, int rocid,
00098 int dcol, int dcolstate,
00099 bool buffermode=false)=0;
00100
00101
00102 virtual int progpix1(int mfec, int mfecchannel, int hubaddress, int portaddress,
00103 int rocid,
00104 int coladdr, int rowaddress,
00105 int mask, int trim, bool buffermode=false)=0;
00106
00107 virtual int progpix(int mfec, int mfecchannel, int hubaddress, int portaddress,
00108 int rocid,
00109 int coladdr, int rowaddress,
00110 unsigned char databyte, bool buffermode=false)=0;
00111
00112 virtual int qbufsend(void)=0;
00113
00114 virtual void fecDebug(int newstate)=0;
00115
00116 virtual int delay25Test(int mymfec,
00117 int myfecchannel,
00118 int myhubaddress,
00119 int mytbmchannel,
00120 int myportaddress,
00121 int myrocid,
00122 int mymask,
00123 int mytrim,
00124 int nTry,
00125 int commands,
00126 int& success0,
00127 int& success1,
00128 int& success2,
00129 int& success3,
00130 int& success4)=0;
00131
00132
00133 virtual int rocreset(int mfec, int fecchannel,
00134 int tbmchannel, int hubaddress)=0;
00135
00136
00137
00138
00139
00140
00141 };
00142 }
00143 #endif