Hall-D Software
alpha
|
#include <DAQ/daq_param_type.h>
Go to the source code of this file.
Macros | |
#define | SUPPRESS_DRIFT_CHAMBER_HITS_OVERFLOW_WARNINGS 1 |
#define | FADC250_MAX_CHAN 16 |
#define | FADC250_MAX_HITS 4 |
#define | FADC250_MAX_WINDOW 512 |
#define | FADC250_MAX_LATENCY 2048 |
#define | FADC250_MAX_NSB 512 |
#define | FADC250_MAX_NSA 512 |
#define | FADC250_WINDOW_WIDTH 50 |
#define | FADC250_BL_HEADER(slot, blnum, cnt) {*dabufp++ = 0x80000000 | (slot << 22) | (FADC250 << 18) | ((blnum&0x3ff) << 8) | cnt; } |
#define | FADC250_BL_TRAILER(slot, nwords) {*dabufp++ = 0x88000000 | (slot << 22) | nwords; } |
#define | FADC250_EV_HEADER(slot, trig) {*dabufp++ = 0x90000000 | (slot << 22) | (trig&0x3fffff); } |
#define | FADC250_EV_TS_LOW(timestamp) {*dabufp++ = 0x98000000 | (timestamp&(0x0000000000ffffffLLU)); } |
#define | FADC250_EV_TS_HIGH(timestamp) {*dabufp++ = (timestamp&(0x0000ffffff000000LLU)) >> 24; } |
#define | FADC250_EV_PARAM1(nsb, nsa, pl) {*dabufp++ = (nsb) << 20 | (nsa) << 11 | pl; } |
#define | FADC250_RW_HEADER(chan, ww) {*dabufp++ = 0xA0000000 | (chan << 23) | ww ; } |
#define | FADC250_RW_DATA(s1, s2) {*dabufp++ = (s1 << 16) | s2 ; } |
#define | FADC250_WI_SUM(chan, sum) {*dabufp++ = 0xA8000000 | (chan << 23) | (sum&0x3fffff) ; } |
#define | FADC250_RP_HEADER(chan, pn, fs) {*dabufp++ = 0xB0000000 | (chan << 23) | (pn << 21) | (fs) ; } |
#define | FADC250_RP_DATA(s1, s2) {*dabufp++ = (s1 << 16) | s2 ; } |
#define | FADC250_PI_SUM(chan, pn, sum) {*dabufp++ = 0xB8000000 | (chan << 23) | (pn << 21) | (sum&0x7ffff) ; } |
#define | FADC250_PI_TIME(chan, pn, time) {*dabufp++ = 0xC0000000 | (chan << 23) | (pn << 21) | (time&0x7ffff); } |
#define | FADC250_PI_PED(chan, pn, ped, peak) {*dabufp++ = 0xD0000000 | (chan << 23) | (pn << 21) | ((ped&0x1ff)<<12) | (peak&0xfff); } |
#define | FADC250_FILLER {*dabufp++ = 0xF8000000; } |
#define | FADC125_MAX_CHAN 72 |
#define | FADC125_MAX_HITS 4 |
#define | FADC125_MAX_WINDOW 512 |
#define | FADC125_MAX_LATENCY 2048 |
#define | FADC125_MAX_NSB 512 |
#define | FADC125_MAX_NSA 512 |
#define | FADC125_WINDOW_WIDTH 50 |
#define | FADC125_BL_HEADER(slot, blnum, cnt) {*dabufp++ = 0x80000000 | (slot << 22) | (FADC125 << 18) | ((blnum&0x3ff) << 8) | cnt; } |
#define | FADC125_BL_TRAILER(slot, nwords) {*dabufp++ = 0x88000000 | (slot << 22) | nwords; } |
#define | FADC125_EV_HEADER(slot, trig) {*dabufp++ = 0x90000000 | (slot << 22) | (trig&0x3fffff); } |
#define | FADC125_EV_TS_LOW(timestamp) {*dabufp++ = 0x98000000 | (timestamp&(0x0000000000ffffffLLU)); } |
#define | FADC125_EV_TS_HIGH(timestamp) {*dabufp++ = (timestamp&(0x0000ffffff000000LLU)) >> 24; } |
#define | FADC125_RW_HEADER(chan, ww) {*dabufp++ = 0xA0000000 | (chan << 20) | (ww&0x1fffff) ; } |
#define | FADC125_RW_DATA(s1, s2) {*dabufp++ = (s1 << 16) | s2 ; } |
#define | FADC125_WI_SUM(chan, sum) {*dabufp++ = 0xA8000000 | (chan << 20) | (sum&0x1fffff) ; } |
#define | FADC125_RP_HEADER(chan, pn, fs) {*dabufp++ = 0xB0000000 | (chan << 20) | (pn << 18) | (fs&0x3ffff) ; } |
#define | FADC125_RP_DATA(s1, s2) {*dabufp++ = (s1 << 16) | s2 ; } |
#define | FADC125_PI_SUM(chan, sum) {*dabufp++ = 0xB8000000 | (chan << 20) | (sum&0xfffff) ; } |
#define | FADC125_PI_TIME(chan, qf, time) {*dabufp++ = 0xC0000000 | (chan << 20) | (qf << 18) | (time&0xffff); } |
#define | FADC125_PI_PED(chan, pn, ped, peak) {*dabufp++ = 0xD0000000 | ((chan << 23)&0x0f) | (pn << 21) | ((ped&0x1ff)<<12) | (peak&0xfff) ; } |
#define | FADC125_FILLER {*dabufp++ = 0xF8000000; } |
#define | F1TDC32_MAX_CHAN 32 |
#define | F1TDC32_MAX_HITS 8 |
#define | F1TDC32_MAX_CHIPS 8 |
#define | F1TDC32_BL_HEADER(slot, blnum, cnt) {*dabufp++ = 0x80000000 | (slot << 22) | (F1TDC32 << 18) | ((blnum&0x3ff) << 8) | cnt; } |
#define | F1TDC32_BL_TRAILER(slot, nwords) {*dabufp++ = 0x88000000 | (slot << 22) | nwords; } |
#define | F1TDC32_EV_HEADER(slot, trig) {*dabufp++ = 0x90000000 | (slot << 22)| (trig&0x3fffff); } |
#define | F1TDC32_EV_TS_LOW(timestamp) {*dabufp++ = 0x98000000 | (timestamp&(0x0000000000ffffffLLU)); } |
#define | F1TDC32_EV_TS_HIGH(timestamp) {*dabufp++ = (timestamp&(0x000000ffff000000LLU)) >> 24; } |
#define | F1TDC32_F1_HEADER(cdata, chip, chan_on_chip, trig, trig_time) {*dabufp++ = 0xC0000000 | ((cdata&0x1F) << 22) | (0 << 23) | (chip << 3) | (chan_on_chip << 0) | ((trig&0x3f) << 16) | ((trig_time&0x1ff) << 7); } |
#define | F1TDC32_F1_DATA(cdata, chip, chan_on_chip, time) {*dabufp++ = 0xB8000000 | ((cdata&0x1F) << 22) | (1 << 23) | (chip << 19) | (chan_on_chip << 16) | (time&0xffff); } |
#define | F1TDC32_FILLER(slot) {*dabufp++ = 0xF8000000 | (slot << 22); } |
#define | F1TDC32_CHIP_NUM(chan) (chan >> 2) |
#define | F1TDC32_CHAN_ON_CHIP(chan) ((chan & 0x03) << 1) |
#define | F1TDC48_MAX_CHAN 48 |
#define | F1TDC48_MAX_HITS 8 |
#define | F1TDC48_MAX_CHIPS 6 |
#define | F1TDC48_BL_HEADER(slot, blnum, cnt) {*dabufp++ = 0x80000000 | (slot << 22) | (F1TDC48 << 18) | ((blnum&0x3ff) << 8) | cnt; } |
#define | F1TDC48_BL_TRAILER(slot, nwords) {*dabufp++ = 0x88000000 | (slot << 22) | nwords; } |
#define | F1TDC48_EV_HEADER(slot, trig) {*dabufp++ = 0x90000000 | (slot << 22) | (trig&0x3fffff); } |
#define | F1TDC48_EV_TS_LOW(timestamp) {*dabufp++ = 0x98000000 | (timestamp&(0x0000000000ffffffLLU)); } |
#define | F1TDC48_EV_TS_HIGH(timestamp) {*dabufp++ = (timestamp&(0x0000ffffff000000LLU)) >> 24; } |
#define | F1TDC48_F1_HEADER(cdata, chip, chan_on_chip, trig, trig_time) {*dabufp++ = 0xC0000000 | ((cdata&0x1F) << 22) | (0 << 23) | (chip << 3) | (chan_on_chip << 0) | ((trig&0x3f) << 16) | ((trig_time&0x1ff) << 7); } |
#define | F1TDC48_F1_DATA(cdata, chip, chan_on_chip, time) {*dabufp++ = 0xB8000000 | ((cdata&0x1F) << 22) | (1 << 23) | (chip << 19) | (chan_on_chip << 16) | (time&0xffff); } |
#define | F1TDC48_FILLER(slot) {*dabufp++ = 0xF8000000 | (slot << 22); } |
#define | F1TDC48_CHIP_NUM(chan) (chan >> 3) |
#define | F1TDC48_CHAN_ON_CHIP(chan) (chan & 0x07) |
#define | CAEN1290_MAX_CHAN 32 |
#define | CAEN1290_MAX_HITS 8 |
#define | CAEN1290_MAX_CHIPS 4 |
#define | CAEN1290_BL_HEADER(slot, evt) {*dabufp++ = 0x40000000 | (evt << 5) | (slot); } |
#define | CAEN1290_BL_TRAILER(slot, nwords, status) {*dabufp++ = 0x80000000 | ((status&0x7) << 24) | (nwords << 5) | (slot); } |
#define | CAEN1290_TDC_HEADER(chip, evt, bid) {*dabufp++ = 0x08000000 | ((chip&0x3) << 24) | ((evt&0xfff) << 12) | (bid&0xfff); } |
#define | CAEN1290_TDC_DATA(edge, chan, time) {*dabufp++ = 0x00000000 | ((edge&1) << 26) | ((chan&0x1f) << 21) | (time&0x1fffff); } |
#define | CAEN1290_TDC_TRAILER(chip, evt, nwords) {*dabufp++ = 0x18000000 | ((chip&0x3) << 24) | ((evt&0xfff) << 12) | (nwords&0xfff); } |
#define | CAEN1290_TDC_ERROR(chip, eflags) { *dabufp++ = 0x20000000 | ((chip&0x3) << 24) | (eflags&0x7fff); } |
#define | CAEN1290_FILLER {*dabufp++ = 0xC0000000; } |
#define | MAX_CONFIG_PARS 20 |
Functions | |
void | GetPedestals (uint32_t *peds, uint32_t Npeds) |
int | fadc250_write_data (CODA_EVENT_INFO *event, int roc, int slot, int mode) |
int | fadc125_write_data (CODA_EVENT_INFO *event, int roc, int slot, int mode) |
int | f1tdc32_write_data (CODA_EVENT_INFO *event, int roc, int slot, int mode) |
int | f1tdc48_write_data (CODA_EVENT_INFO *event, int roc, int slot, int mode) |
int | caen1290_write_data (CODA_EVENT_INFO *event, int roc, int slot, int mode) |
void | WriteDAQconfigBank (CODA_CRATE_MAP *crate, int roc) |
#define CAEN1290_BL_HEADER | ( | slot, | |
evt | |||
) | {*dabufp++ = 0x40000000 | (evt << 5) | (slot); } |
Definition at line 552 of file mc2coda_modules.h.
Referenced by caen1290_write_data().
#define CAEN1290_BL_TRAILER | ( | slot, | |
nwords, | |||
status | |||
) | {*dabufp++ = 0x80000000 | ((status&0x7) << 24) | (nwords << 5) | (slot); } |
Definition at line 553 of file mc2coda_modules.h.
Referenced by caen1290_write_data().
#define CAEN1290_FILLER {*dabufp++ = 0xC0000000; } |
Definition at line 561 of file mc2coda_modules.h.
Referenced by caen1290_write_data().
#define CAEN1290_MAX_CHAN 32 |
Definition at line 546 of file mc2coda_modules.h.
Referenced by caen1290_write_data().
#define CAEN1290_MAX_CHIPS 4 |
Definition at line 548 of file mc2coda_modules.h.
#define CAEN1290_MAX_HITS 8 |
Definition at line 547 of file mc2coda_modules.h.
Referenced by caen1290_write_data().
#define CAEN1290_TDC_DATA | ( | edge, | |
chan, | |||
time | |||
) | {*dabufp++ = 0x00000000 | ((edge&1) << 26) | ((chan&0x1f) << 21) | (time&0x1fffff); } |
Definition at line 556 of file mc2coda_modules.h.
Referenced by caen1290_write_data().
#define CAEN1290_TDC_ERROR | ( | chip, | |
eflags | |||
) | { *dabufp++ = 0x20000000 | ((chip&0x3) << 24) | (eflags&0x7fff); } |
Definition at line 559 of file mc2coda_modules.h.
#define CAEN1290_TDC_HEADER | ( | chip, | |
evt, | |||
bid | |||
) | {*dabufp++ = 0x08000000 | ((chip&0x3) << 24) | ((evt&0xfff) << 12) | (bid&0xfff); } |
Definition at line 555 of file mc2coda_modules.h.
Referenced by caen1290_write_data().
#define CAEN1290_TDC_TRAILER | ( | chip, | |
evt, | |||
nwords | |||
) | {*dabufp++ = 0x18000000 | ((chip&0x3) << 24) | ((evt&0xfff) << 12) | (nwords&0xfff); } |
Definition at line 557 of file mc2coda_modules.h.
Referenced by caen1290_write_data().
#define F1TDC32_BL_HEADER | ( | slot, | |
blnum, | |||
cnt | |||
) | {*dabufp++ = 0x80000000 | (slot << 22) | (F1TDC32 << 18) | ((blnum&0x3ff) << 8) | cnt; } |
Definition at line 277 of file mc2coda_modules.h.
Referenced by f1tdc32_write_data().
#define F1TDC32_BL_TRAILER | ( | slot, | |
nwords | |||
) | {*dabufp++ = 0x88000000 | (slot << 22) | nwords; } |
Definition at line 278 of file mc2coda_modules.h.
Referenced by f1tdc32_write_data().
Definition at line 295 of file mc2coda_modules.h.
Referenced by f1tdc32_write_data().
Definition at line 294 of file mc2coda_modules.h.
Referenced by f1tdc32_write_data().
Definition at line 280 of file mc2coda_modules.h.
Referenced by f1tdc32_write_data().
#define F1TDC32_EV_TS_HIGH | ( | timestamp | ) | {*dabufp++ = (timestamp&(0x000000ffff000000LLU)) >> 24; } |
Definition at line 282 of file mc2coda_modules.h.
#define F1TDC32_EV_TS_LOW | ( | timestamp | ) | {*dabufp++ = 0x98000000 | (timestamp&(0x0000000000ffffffLLU)); } |
Definition at line 281 of file mc2coda_modules.h.
Referenced by f1tdc32_write_data().
#define F1TDC32_F1_DATA | ( | cdata, | |
chip, | |||
chan_on_chip, | |||
time | |||
) | {*dabufp++ = 0xB8000000 | ((cdata&0x1F) << 22) | (1 << 23) | (chip << 19) | (chan_on_chip << 16) | (time&0xffff); } |
Definition at line 290 of file mc2coda_modules.h.
Referenced by f1tdc32_write_data().
#define F1TDC32_F1_HEADER | ( | cdata, | |
chip, | |||
chan_on_chip, | |||
trig, | |||
trig_time | |||
) | {*dabufp++ = 0xC0000000 | ((cdata&0x1F) << 22) | (0 << 23) | (chip << 3) | (chan_on_chip << 0) | ((trig&0x3f) << 16) | ((trig_time&0x1ff) << 7); } |
Definition at line 289 of file mc2coda_modules.h.
Referenced by f1tdc32_write_data().
#define F1TDC32_FILLER | ( | slot | ) | {*dabufp++ = 0xF8000000 | (slot << 22); } |
Definition at line 292 of file mc2coda_modules.h.
Referenced by f1tdc32_write_data().
#define F1TDC32_MAX_CHAN 32 |
Definition at line 271 of file mc2coda_modules.h.
Referenced by f1tdc32_write_data().
#define F1TDC32_MAX_CHIPS 8 |
Definition at line 273 of file mc2coda_modules.h.
#define F1TDC32_MAX_HITS 8 |
Definition at line 272 of file mc2coda_modules.h.
Referenced by f1tdc32_write_data().
#define F1TDC48_BL_HEADER | ( | slot, | |
blnum, | |||
cnt | |||
) | {*dabufp++ = 0x80000000 | (slot << 22) | (F1TDC48 << 18) | ((blnum&0x3ff) << 8) | cnt; } |
Definition at line 416 of file mc2coda_modules.h.
Referenced by f1tdc48_write_data().
#define F1TDC48_BL_TRAILER | ( | slot, | |
nwords | |||
) | {*dabufp++ = 0x88000000 | (slot << 22) | nwords; } |
Definition at line 417 of file mc2coda_modules.h.
Referenced by f1tdc48_write_data().
Definition at line 434 of file mc2coda_modules.h.
Referenced by f1tdc48_write_data().
Definition at line 433 of file mc2coda_modules.h.
Referenced by f1tdc48_write_data().
#define F1TDC48_EV_HEADER | ( | slot, | |
trig | |||
) | {*dabufp++ = 0x90000000 | (slot << 22) | (trig&0x3fffff); } |
Definition at line 419 of file mc2coda_modules.h.
Referenced by f1tdc48_write_data().
#define F1TDC48_EV_TS_HIGH | ( | timestamp | ) | {*dabufp++ = (timestamp&(0x0000ffffff000000LLU)) >> 24; } |
Definition at line 421 of file mc2coda_modules.h.
#define F1TDC48_EV_TS_LOW | ( | timestamp | ) | {*dabufp++ = 0x98000000 | (timestamp&(0x0000000000ffffffLLU)); } |
Definition at line 420 of file mc2coda_modules.h.
Referenced by f1tdc48_write_data().
#define F1TDC48_F1_DATA | ( | cdata, | |
chip, | |||
chan_on_chip, | |||
time | |||
) | {*dabufp++ = 0xB8000000 | ((cdata&0x1F) << 22) | (1 << 23) | (chip << 19) | (chan_on_chip << 16) | (time&0xffff); } |
Definition at line 429 of file mc2coda_modules.h.
Referenced by f1tdc48_write_data().
#define F1TDC48_F1_HEADER | ( | cdata, | |
chip, | |||
chan_on_chip, | |||
trig, | |||
trig_time | |||
) | {*dabufp++ = 0xC0000000 | ((cdata&0x1F) << 22) | (0 << 23) | (chip << 3) | (chan_on_chip << 0) | ((trig&0x3f) << 16) | ((trig_time&0x1ff) << 7); } |
Definition at line 428 of file mc2coda_modules.h.
Referenced by f1tdc48_write_data().
#define F1TDC48_FILLER | ( | slot | ) | {*dabufp++ = 0xF8000000 | (slot << 22); } |
Definition at line 431 of file mc2coda_modules.h.
Referenced by f1tdc48_write_data().
#define F1TDC48_MAX_CHAN 48 |
Definition at line 410 of file mc2coda_modules.h.
Referenced by f1tdc48_write_data().
#define F1TDC48_MAX_CHIPS 6 |
Definition at line 412 of file mc2coda_modules.h.
#define F1TDC48_MAX_HITS 8 |
Definition at line 411 of file mc2coda_modules.h.
Referenced by f1tdc48_write_data().
#define FADC125_BL_HEADER | ( | slot, | |
blnum, | |||
cnt | |||
) | {*dabufp++ = 0x80000000 | (slot << 22) | (FADC125 << 18) | ((blnum&0x3ff) << 8) | cnt; } |
Definition at line 146 of file mc2coda_modules.h.
Referenced by fadc125_write_data().
#define FADC125_BL_TRAILER | ( | slot, | |
nwords | |||
) | {*dabufp++ = 0x88000000 | (slot << 22) | nwords; } |
Definition at line 147 of file mc2coda_modules.h.
Referenced by fadc125_write_data().
#define FADC125_EV_HEADER | ( | slot, | |
trig | |||
) | {*dabufp++ = 0x90000000 | (slot << 22) | (trig&0x3fffff); } |
Definition at line 149 of file mc2coda_modules.h.
Referenced by fadc125_write_data().
#define FADC125_EV_TS_HIGH | ( | timestamp | ) | {*dabufp++ = (timestamp&(0x0000ffffff000000LLU)) >> 24; } |
Definition at line 151 of file mc2coda_modules.h.
#define FADC125_EV_TS_LOW | ( | timestamp | ) | {*dabufp++ = 0x98000000 | (timestamp&(0x0000000000ffffffLLU)); } |
Definition at line 150 of file mc2coda_modules.h.
Referenced by fadc125_write_data().
#define FADC125_FILLER {*dabufp++ = 0xF8000000; } |
Definition at line 165 of file mc2coda_modules.h.
Referenced by fadc125_write_data().
#define FADC125_MAX_CHAN 72 |
Definition at line 137 of file mc2coda_modules.h.
Referenced by fadc125_write_data().
#define FADC125_MAX_HITS 4 |
Definition at line 138 of file mc2coda_modules.h.
Referenced by fadc125_write_data().
#define FADC125_MAX_LATENCY 2048 |
Definition at line 140 of file mc2coda_modules.h.
#define FADC125_MAX_NSA 512 |
Definition at line 142 of file mc2coda_modules.h.
#define FADC125_MAX_NSB 512 |
Definition at line 141 of file mc2coda_modules.h.
#define FADC125_MAX_WINDOW 512 |
Definition at line 139 of file mc2coda_modules.h.
#define FADC125_PI_PED | ( | chan, | |
pn, | |||
ped, | |||
peak | |||
) | {*dabufp++ = 0xD0000000 | ((chan << 23)&0x0f) | (pn << 21) | ((ped&0x1ff)<<12) | (peak&0xfff) ; } |
Definition at line 163 of file mc2coda_modules.h.
Referenced by fadc125_write_data().
Definition at line 161 of file mc2coda_modules.h.
Referenced by fadc125_write_data().
#define FADC125_PI_TIME | ( | chan, | |
qf, | |||
time | |||
) | {*dabufp++ = 0xC0000000 | (chan << 20) | (qf << 18) | (time&0xffff); } |
Definition at line 162 of file mc2coda_modules.h.
Referenced by fadc125_write_data().
#define FADC125_RP_DATA | ( | s1, | |
s2 | |||
) | {*dabufp++ = (s1 << 16) | s2 ; } |
Definition at line 159 of file mc2coda_modules.h.
#define FADC125_RP_HEADER | ( | chan, | |
pn, | |||
fs | |||
) | {*dabufp++ = 0xB0000000 | (chan << 20) | (pn << 18) | (fs&0x3ffff) ; } |
Definition at line 158 of file mc2coda_modules.h.
#define FADC125_RW_DATA | ( | s1, | |
s2 | |||
) | {*dabufp++ = (s1 << 16) | s2 ; } |
Definition at line 154 of file mc2coda_modules.h.
Definition at line 153 of file mc2coda_modules.h.
Definition at line 156 of file mc2coda_modules.h.
#define FADC125_WINDOW_WIDTH 50 |
Definition at line 143 of file mc2coda_modules.h.
Referenced by fadc125_write_data(), and WriteDAQconfigBank().
#define FADC250_BL_HEADER | ( | slot, | |
blnum, | |||
cnt | |||
) | {*dabufp++ = 0x80000000 | (slot << 22) | (FADC250 << 18) | ((blnum&0x3ff) << 8) | cnt; } |
Definition at line 21 of file mc2coda_modules.h.
Referenced by fadc250_write_data().
#define FADC250_BL_TRAILER | ( | slot, | |
nwords | |||
) | {*dabufp++ = 0x88000000 | (slot << 22) | nwords; } |
Definition at line 22 of file mc2coda_modules.h.
Referenced by fadc250_write_data().
#define FADC250_EV_HEADER | ( | slot, | |
trig | |||
) | {*dabufp++ = 0x90000000 | (slot << 22) | (trig&0x3fffff); } |
Definition at line 24 of file mc2coda_modules.h.
Referenced by fadc250_write_data().
#define FADC250_EV_PARAM1 | ( | nsb, | |
nsa, | |||
pl | |||
) | {*dabufp++ = (nsb) << 20 | (nsa) << 11 | pl; } |
Definition at line 27 of file mc2coda_modules.h.
#define FADC250_EV_TS_HIGH | ( | timestamp | ) | {*dabufp++ = (timestamp&(0x0000ffffff000000LLU)) >> 24; } |
Definition at line 26 of file mc2coda_modules.h.
#define FADC250_EV_TS_LOW | ( | timestamp | ) | {*dabufp++ = 0x98000000 | (timestamp&(0x0000000000ffffffLLU)); } |
Definition at line 25 of file mc2coda_modules.h.
Referenced by fadc250_write_data().
#define FADC250_FILLER {*dabufp++ = 0xF8000000; } |
Definition at line 41 of file mc2coda_modules.h.
Referenced by fadc250_write_data().
#define FADC250_MAX_CHAN 16 |
Definition at line 12 of file mc2coda_modules.h.
Referenced by fadc250_write_data().
#define FADC250_MAX_HITS 4 |
Definition at line 13 of file mc2coda_modules.h.
Referenced by fadc250_write_data().
#define FADC250_MAX_LATENCY 2048 |
Definition at line 15 of file mc2coda_modules.h.
#define FADC250_MAX_NSA 512 |
Definition at line 17 of file mc2coda_modules.h.
#define FADC250_MAX_NSB 512 |
Definition at line 16 of file mc2coda_modules.h.
#define FADC250_MAX_WINDOW 512 |
Definition at line 14 of file mc2coda_modules.h.
#define FADC250_PI_PED | ( | chan, | |
pn, | |||
ped, | |||
peak | |||
) | {*dabufp++ = 0xD0000000 | (chan << 23) | (pn << 21) | ((ped&0x1ff)<<12) | (peak&0xfff); } |
Definition at line 39 of file mc2coda_modules.h.
Referenced by fadc250_write_data().
#define FADC250_PI_SUM | ( | chan, | |
pn, | |||
sum | |||
) | {*dabufp++ = 0xB8000000 | (chan << 23) | (pn << 21) | (sum&0x7ffff) ; } |
Definition at line 37 of file mc2coda_modules.h.
Referenced by fadc250_write_data().
#define FADC250_PI_TIME | ( | chan, | |
pn, | |||
time | |||
) | {*dabufp++ = 0xC0000000 | (chan << 23) | (pn << 21) | (time&0x7ffff); } |
Definition at line 38 of file mc2coda_modules.h.
Referenced by fadc250_write_data().
#define FADC250_RP_DATA | ( | s1, | |
s2 | |||
) | {*dabufp++ = (s1 << 16) | s2 ; } |
Definition at line 35 of file mc2coda_modules.h.
#define FADC250_RP_HEADER | ( | chan, | |
pn, | |||
fs | |||
) | {*dabufp++ = 0xB0000000 | (chan << 23) | (pn << 21) | (fs) ; } |
Definition at line 34 of file mc2coda_modules.h.
#define FADC250_RW_DATA | ( | s1, | |
s2 | |||
) | {*dabufp++ = (s1 << 16) | s2 ; } |
Definition at line 30 of file mc2coda_modules.h.
Definition at line 29 of file mc2coda_modules.h.
Definition at line 32 of file mc2coda_modules.h.
#define FADC250_WINDOW_WIDTH 50 |
Definition at line 18 of file mc2coda_modules.h.
Referenced by fadc250_write_data(), and WriteDAQconfigBank().
#define MAX_CONFIG_PARS 20 |
Definition at line 651 of file mc2coda_modules.h.
Referenced by WriteDAQconfigBank().
#define SUPPRESS_DRIFT_CHAMBER_HITS_OVERFLOW_WARNINGS 1 |
Definition at line 8 of file mc2coda_modules.h.
int caen1290_write_data | ( | CODA_EVENT_INFO * | event, |
int | roc, | ||
int | slot, | ||
int | mode | ||
) |
Definition at line 565 of file mc2coda_modules.h.
References CAEN1290, CAEN1290_BL_HEADER, CAEN1290_BL_TRAILER, CAEN1290_FILLER, CAEN1290_MAX_CHAN, CAEN1290_MAX_HITS, CAEN1290_TDC_DATA, CAEN1290_TDC_HEADER, CAEN1290_TDC_TRAILER, chan, coda_hit_info::chan_id, coda_hit_info::crate_id, dabufp, coda_event_info::hits, MAX_HITS_PER_CHAN, coda_hit_info::module_id, coda_hit_info::module_mode, printf(), and coda_hit_info::slot_id.
Referenced by mc2codaCloseEvent().
int f1tdc32_write_data | ( | CODA_EVENT_INFO * | event, |
int | roc, | ||
int | slot, | ||
int | mode | ||
) |
Definition at line 298 of file mc2coda_modules.h.
References chan, coda_hit_info::chan_id, coda_hit_info::crate_id, dabufp, F1TDC32, F1TDC32_BL_HEADER, F1TDC32_BL_TRAILER, F1TDC32_CHAN_ON_CHIP, F1TDC32_CHIP_NUM, F1TDC32_EV_HEADER, F1TDC32_EV_TS_LOW, F1TDC32_F1_DATA, F1TDC32_F1_HEADER, F1TDC32_FILLER, F1TDC32_MAX_CHAN, F1TDC32_MAX_HITS, coda_event_info::hits, MAX_HITS_PER_CHAN, coda_hit_info::module_id, coda_hit_info::module_mode, printf(), and coda_hit_info::slot_id.
Referenced by mc2codaCloseEvent().
int f1tdc48_write_data | ( | CODA_EVENT_INFO * | event, |
int | roc, | ||
int | slot, | ||
int | mode | ||
) |
Definition at line 438 of file mc2coda_modules.h.
References chan, coda_hit_info::chan_id, coda_hit_info::crate_id, dabufp, F1TDC48, F1TDC48_BL_HEADER, F1TDC48_BL_TRAILER, F1TDC48_CHAN_ON_CHIP, F1TDC48_CHIP_NUM, F1TDC48_EV_HEADER, F1TDC48_EV_TS_LOW, F1TDC48_F1_DATA, F1TDC48_F1_HEADER, F1TDC48_FILLER, F1TDC48_MAX_CHAN, F1TDC48_MAX_HITS, coda_event_info::hits, MAX_HITS_PER_CHAN, coda_hit_info::module_id, coda_hit_info::module_mode, printf(), and coda_hit_info::slot_id.
Referenced by mc2codaCloseEvent().
int fadc125_write_data | ( | CODA_EVENT_INFO * | event, |
int | roc, | ||
int | slot, | ||
int | mode | ||
) |
Definition at line 169 of file mc2coda_modules.h.
References chan, coda_hit_info::chan_id, coda_hit_info::crate_id, dabufp, FADC125, FADC125_BL_HEADER, FADC125_BL_TRAILER, FADC125_EV_HEADER, FADC125_EV_TS_LOW, FADC125_FILLER, FADC125_MAX_CHAN, FADC125_MAX_HITS, FADC125_PI_PED, FADC125_PI_SUM, FADC125_PI_TIME, FADC125_WINDOW_WIDTH, GetPedestals(), coda_hit_info::hdata, coda_event_info::hits, MAX_HITS_PER_CHAN, coda_hit_info::module_id, coda_hit_info::module_mode, printf(), coda_hit_info::slot_id, and sum.
Referenced by mc2codaCloseEvent().
int fadc250_write_data | ( | CODA_EVENT_INFO * | event, |
int | roc, | ||
int | slot, | ||
int | mode | ||
) |
Definition at line 45 of file mc2coda_modules.h.
References chan, coda_hit_info::chan_id, coda_hit_info::crate_id, dabufp, FADC250, FADC250_BL_HEADER, FADC250_BL_TRAILER, FADC250_EV_HEADER, FADC250_EV_TS_LOW, FADC250_FILLER, FADC250_MAX_CHAN, FADC250_MAX_HITS, FADC250_PI_PED, FADC250_PI_SUM, FADC250_PI_TIME, FADC250_WINDOW_WIDTH, GetPedestals(), coda_hit_info::hdata, coda_event_info::hits, MAX_HITS_PER_CHAN, coda_hit_info::module_id, coda_hit_info::module_mode, printf(), coda_hit_info::slot_id, and sum.
Referenced by mc2codaCloseEvent().
void GetPedestals | ( | uint32_t * | peds, |
uint32_t | Npeds | ||
) |
Generate a set of pedestal values based on the global variables. Ths will fill in the first Npeds-1 values in "peds" with a pedestal near zero and Npeds-th value will be near the mean pedestal setting. The idea is that the last value delivered will contain the mean pedestal for all channels in the module plus common mode noise. The first set of values will contain individual pedestal fluctuations for each channel. The f250 and f125 will use the one common pedestal to adjust the pulse integral and pulse peak values. For the measured pedestals output in Pulse Pedestal words, the stochastic part is added in as well to represent the inaccuracy of that measurement. Note that this means the actual pedestal value used is not actually written to the output file anywhere.
If the global boolean NO_PEDESTAL is set to true, then all values will be set to zero.
If the global NO_RANDOM_PEDESTAL is set to true, then the first Npeds-1 values will be set to zero and the last value to the mean pedestal (=MEAN_PEDESTAL) with no random variation.
The values MEAN_PEDESTAL, SIGMA_COMMON_PEDESTAL, and SIGMA_INDIVIDUAL_PEDESTAL are used to calculate the values. Random sampling is done from Gaussian's with the specified sigmas.
Generate a set of pedestal values based on the global variables. Ths will fill in the first Npeds-1 values in "peds" with a pedestal near zero and Npeds-th value will be near the mean pedestal setting. The idea is that the last value delivered will contain the mean pedestal for all channels in the module plus common mode noise. The first set of values will contain individual pedestal fluctuations for each channel. The f250 and f125 will use the one common pedestal to adjust the pulse integral and pulse peak values. For the measured pedestals output in Pulse Pedestal words, the stochastic part is added in as well to represent the inaccuracy of that measurement. Note that this means the actual pedestal value used is not actually written to the output file anywhere.
If the global boolean NO_PEDESTAL is set to true, then all values will be set to zero.
If the global NO_RANDOM_PEDESTAL is set to true, then the first Npeds-1 values will be set to zero and the last value to the mean pedestal (=MEAN_PEDESTAL) with no random variation.
The values MEAN_PEDESTAL, SIGMA_COMMON_PEDESTAL, and SIGMA_INDIVIDUAL_PEDESTAL are used to calculate the values. Random sampling is done from Gaussian's with the specified sigmas.
Definition at line 19 of file mc2coda_random.cc.
References MEAN_PEDESTAL, NO_PEDESTAL, NO_RANDOM_PEDESTAL, randgen, SIGMA_COMMON_PEDESTAL, and SIGMA_INDIVIDUAL_PEDESTAL.
Referenced by fadc125_write_data(), and fadc250_write_data().
void WriteDAQconfigBank | ( | CODA_CRATE_MAP * | crate, |
int | roc | ||
) |
Definition at line 653 of file mc2coda_modules.h.
References CAEN1190, CAEN1290, dabufp, DATA_BANK_CLOSE, DATA_BANK_OPEN, F1TDC32, F1TDC48, FADC125, FADC125_WINDOW_WIDTH, FADC250, FADC250_WINDOW_WIDTH, kPARAM125_NPED, kPARAM125_NSA_NSB, kPARAM125_WINWIDTH, kPARAM250_NPED, kPARAM250_NSA_NSB, kPARAMCAEN1290_WINOFFSET, kPARAMF1_HSDIV, kPARAMF1_REFCNT, MAX_CONFIG_PARS, MAX_SLOTS, coda_crate_map::module_map, coda_crate_map::moduleMask, TD, TID, and UNKNOWN.
Referenced by mc2codaCloseEvent().