27 #include "StDaqLib/GENERIC/swaps.hh"
28 #include "TPCV1P0.Banks.hh"
30 using namespace OLDEVP;
32 int classname(Bank_TPCRBP)::swap()
35 int words = header.BankLength;
36 int iret = swap_raw(header.ByteOrder,&words,1);
41 if(iret < 0)
return iret;
44 iret = swap_raw(header.ByteOrder,(INT32 *)Mz,
sizeof(Mz)/4);
53 int classname(Bank_TPCADCD)::swap()
58 int classname(Bank_TPCADCR)::swap()
63 int classname(Bank_TPCPADK)::swap()
66 int words = header.BankLength;
67 int iret = swap_raw(header.ByteOrder,&words,1);
70 if(iret < 0)
return iret;
73 iret = swap_raw(header.ByteOrder,&bpADC,6);
80 int classname(Bank_TPCCPPR)::swap()
83 int words = header.BankLength;
84 int iret = swap_raw(header.ByteOrder,&words,1);
87 if(iret<0)
return iret;
90 iret = swap_short(header.ByteOrder,(INT32 *)entry,12288);
97 int classname(Bank_TPCSEQD)::swap()
99 int words = header.BankLength;
100 int iret = swap_raw(header.ByteOrder,&words,1);
103 if(iret < 0)
return iret;
105 words -= (
sizeof(header)/4);
106 swap_short(header.ByteOrder,(INT32 *)sequence,words);
109 iret = header.swap();
113 int classname(Bank_TPCCFGR)::swap()
115 return header.swap();
118 int classname(Bank_TPCBADR)::swap()
120 return header.swap();
123 int classname(Bank_TPCPEDR)::swap()
125 int iret = swap_raw(header.ByteOrder,&NumEvents,1);
126 if(iret <= 0)
return iret;
128 return header.swap();
131 int classname(Bank_TPCRMSR)::swap()
133 int iret = swap_raw(header.ByteOrder,&NumEvents,1);
134 if(iret <= 0)
return iret;
136 return header.swap();
139 int classname(Bank_TPCGAINR)::swap()
141 int iret = swap_raw(header.ByteOrder,&NumEvents,2);
142 if(iret <= 0)
return iret;
146 if(iret != 1)
return -1;
152 iret = header.swap();
155 char *curr = (
char *)
Gain;
156 for(
int i = 0; i < TPC_MZPADS; i++)