67#define FE_NAME "feoV1740_SIM"
69#define FE_NAME "feoV1740"
72#define UNUSED(x) ((void)(x))
183 itv1740->SetSettingsTouched(
true);
184 printf(
"Settings %s touched. Changes will take effect at start of next run.\n",
key.
name);
220 ov1740.back().verbose = 1;
233 printf(
"Board#:%d Module_Handle[%d]:%d (active:%d)\n",
236 ov1740.back().CheckBoardType();
246 printf(
"*** RUNNING SIMULATION ***\n");
262 cout <<
"frontend_exit";
290 printf(
"<<< Begin of begin_of_run\n");
295 if (!
itv1740->IsConnected())
continue;
310 printf(
">>> End of begin_of_run\n\n");
327 printf(
"<<< Begin of end_of_run \n");
339 cout <<
"End of EOR. handle=" <<
itv1740->GetHandle() <<
" link=" <<
itv1740->GetLink()
349 printf(
">>> End Of end_of_run\n\n");
400 cout <<
"frontend_lopp";
477 cout <<
"interrupt_configure";
517 if (!
itv1740->IsConnected())
continue;
BOOL frontend_call_loop
frontend_loop is called periodically if this variable is TRUE
int Nloop
Number of loops executed in event polling.
void seq_callback(INT hDB, INT hseq, void *info)
Sequencer callback info.
INT max_event_size
maximum event size produced by this frontend
INT frontend_exit()
Frontend exit.
bool runStopRequested
stop run requested
INT frontend_init()
Frontend initialization.
INT event_buffer_size
buffer size to hold events
bool runInProgress
run is in progress
#define EQ_TRGMSK
Trigger mask.
INT max_event_size_frag
maximum event size for fragmented events (EQ_FRAGMENTED)
INT interrupt_configure(INT cmd, INT source, POINTER_T adr)
Interrupt configuration (not implemented)
int Ncount
Loop count for event polling timeout.
BOOL debug
debug printouts
#define UNUSED(x)
Suppress compiler warnings.
void interrupt_routine(void)
Interrupt Service Routine.
INT poll_event(INT source, INT count, BOOL test)
Polling routine for events.
#define FE_NAME
Frontend name.
INT read_trigger_event(char *pevent, INT off)
Trigger event readout.
EQUIPMENT equipment[]
Main structure for midas equipment.
INT display_period
a frontend status page is displayed with this frequency in ms
char * frontend_name
The frontend name (client name) as seen by other MIDAS clients.
char * frontend_file_name
The frontend file name, don't change it.
INT begin_of_run(INT run_number, char *error)
Begin of Run.
INT frontend_loop()
Frontend loop.
INT end_of_run(INT run_number, char *error)
End of Run.
INT read_scaler_event(char *pevent, INT off)
Scaler event readout.
vector< v1740CONET2 > ov1740
objects for the v1740 modules controlled by this frontend
vector< v1740CONET2 >::iterator itv1740
iterator
#define Nv1740
Set the number of v1720 modules to be used.
INT bk_close(void *event, void *pdata)
void bk_init(void *event)
void bk_init32(void *event)
void bk_create(void *event, const char *name, WORD type, void **pdata)
INT bk_size(const void *event)
INT cm_transition(INT transition, INT run_number, char *errstr, INT errstr_size, INT async_flag, INT debug_flag)
INT cm_set_watchdog_params(BOOL call_watchdog, DWORD timeout)
#define CMD_INTERRUPT_ATTACH
#define CMD_INTERRUPT_DISABLE
#define CMD_INTERRUPT_ENABLE
#define CMD_INTERRUPT_DETACH
INT cm_msg(INT message_type, const char *filename, INT line, const char *routine, const char *format,...)
INT db_get_key(HNDLE hDB, HNDLE hKey, KEY *key)
INT db_set_value(HNDLE hDB, HNDLE hKeyRoot, const char *key_name, const void *data, INT data_size, INT num_values, DWORD type)
int set_equipment_status(const char *name, const char *equipment_status, const char *status_class)
TH1X EXPRT * h1_book(const char *name, const char *title, int bins, double min, double max)