304,6 → 304,10 |
int nb=d->event(data,BSIZE); |
//tmulk(); |
// zapis v datoteko |
if (nb<0){ |
ieve--; |
continue; |
} |
hdr[1]=nb+4*sizeof(int); |
hdr[2]=time(NULL); |
hdr[3]=ieve; |
317,10 → 321,14 |
events = data[0]; |
evsize = data[ib++]&0xffff; |
if (ieve %100 == 0) printf("nb=%d Event:%d events=%d EvSize:%d\n",nb, ieve, events, evsize); |
if (evsize<2) { |
ieve--; |
continue; |
} |
for (int i=0;i<evsize;i++) { |
//if (debug) printf("%d\t%08x\n", ib, data[ib]); |
if (data[ib]== END_MARKER) break; |
if (i%2==0) { |
if (ib%2==0) { |
unsigned short word1 =data[ib ]&0xFFFF; |
unsigned short word2 =data[ib+1]&0xFFFF; |
unsigned short tdc = word1; |