1 | #ifndef FACT_EventBuilder
|
---|
2 | #define FACT_EventBuilder
|
---|
3 |
|
---|
4 | #ifdef __cplusplus
|
---|
5 | extern "C" {
|
---|
6 | #endif
|
---|
7 |
|
---|
8 | #include "FAD.h"
|
---|
9 |
|
---|
10 | /* global variables;
|
---|
11 | to avoid race canoditions, only one thread is allowed to write
|
---|
12 | the name of the variable defines which process shall write it:
|
---|
13 |
|
---|
14 | g_XXX : main control thread
|
---|
15 | gi_XX : input thread (reading from camera)
|
---|
16 | gw_XX : write thread (writing to disk)
|
---|
17 | qp_XX : processing thread(s) (processing data, eg. soft-trig)
|
---|
18 |
|
---|
19 | */
|
---|
20 | extern uint g_actTime ; //actual time, to be updated regularily
|
---|
21 | extern int g_runStat ; //main steering variable
|
---|
22 | extern int g_actBoards ; //number of boards that should exist at the moment
|
---|
23 | extern int g_reset ; //>0 = reset different levels of eventbuilder
|
---|
24 | extern int g_maxProc ;
|
---|
25 | extern size_t g_maxMem ; //maximum memory allowed for buffer
|
---|
26 |
|
---|
27 | extern PIX_MAP g_pixMap[NPIX] ;
|
---|
28 |
|
---|
29 | extern int g_maxBoards ; //maximum number of boards to be initialized
|
---|
30 | extern FACT_SOCK g_port[NBOARDS] ; // .port = baseport, .addr=string of IP-addr in dotted-decimal "ddd.ddd.ddd.ddd"
|
---|
31 |
|
---|
32 | extern uint gi_SecRate[MAX_SOCK] ; //MAX_SOCK defined in FACTEvent.h
|
---|
33 | extern uint gi_S10Rate[MAX_SOCK] ;
|
---|
34 | extern uint gi_MinRate[MAX_SOCK] ;
|
---|
35 | extern uint gi_ErrCnt[MAX_SOCK] ;
|
---|
36 | extern uint gi_NumConnect[NBOARDS]; //4 crates * 10 boards
|
---|
37 | extern uint gi_SecTime, gi_S10Time, gi_MinTime ;
|
---|
38 | extern uint gi_EvtStart ;
|
---|
39 | extern uint gi_EvtRead ;
|
---|
40 | extern uint gi_EvtBad ;
|
---|
41 | extern uint gi_EvtTot ;
|
---|
42 | extern int gi_maxSocks ; //maximum sockets that will be tried
|
---|
43 | extern int gi_runStat ;
|
---|
44 |
|
---|
45 | extern uint gp_EvtTot ;
|
---|
46 | extern int gp_runStat ;
|
---|
47 | extern uint gw_EvtTot ;
|
---|
48 | extern int gw_runStat ;
|
---|
49 |
|
---|
50 |
|
---|
51 |
|
---|
52 |
|
---|
53 | #ifdef __cplusplus
|
---|
54 | }
|
---|
55 | #endif
|
---|
56 |
|
---|
57 | #endif
|
---|