/*******************************************************************\ Name: fedummy.c Created by: K.Olchanski Contents: Front end for creating dummy data \********************************************************************/ #include #include #include #include #include #include #include #include #include #include #include #include #include "midas.h" #define FE_NAME "feslow" #define EQ_NAME "Slow" #define EQ_EVID 1 /* make frontend functions callable from the C framework */ #ifdef __cplusplus extern "C" { #endif /*-- Globals -------------------------------------------------------*/ /* The frontend name (client name) as seen by other MIDAS clients */ char *frontend_name = FE_NAME; /* The frontend file name, don't change it */ char *frontend_file_name = __FILE__; /* frontend_loop is called periodically if this variable is TRUE */ BOOL frontend_call_loop = TRUE; /* a frontend status page is displayed with this frequency in ms */ //INT display_period = 3000; INT display_period = 0; /* maximum event size produced by this frontend */ INT max_event_size = 2000; INT max_event_size_frag = 0; /* buffer size to hold events */ INT event_buffer_size = 10*2000; /*-- Function declarations -----------------------------------------*/ INT frontend_init(); INT frontend_exit(); INT begin_of_run(INT run_number, char *error); INT end_of_run(INT run_number, char *error); INT pause_run(INT run_number, char *error); INT resume_run(INT run_number, char *error); INT frontend_loop(); HNDLE hDB; INT gbl_run_number; int read_slow_event(char *pevent, int off); /*-- Equipment list ------------------------------------------------*/ EQUIPMENT equipment[] = { { EQ_NAME, /* equipment name */ { EQ_EVID, (1<