AlcapDAQ  1
Macros | Functions | Variables
rpc_master.cpp File Reference
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <sys/io.h>
#include "midas.h"
#include "crate.h"
#include "diag.h"
#include "odb_wrapper.h"
#include "rpc_mucap.h"

Go to the source code of this file.

Macros

#define DEFINE_RPC_LIST
 

Functions

INT rpc_ready_for_cycle (INT index, void *prpc_param[])
 
INT rpc_request_stop (INT index, void *prpc_param[])
 
INT rpc_master_init ()
 
INT rpc_master_pre_bor ()
 
INT rpc_master_bor ()
 
INT rpc_master_eor ()
 
INT rpc_master_poll_live ()
 
INT rpc_master_poll_dead ()
 
INT rpc_master_read (char *pevent)
 
BOOL crate_is_participating (INT crate_number)
 
INT cycle_ram ()
 

Variables

struct {
   BOOL   enabled
 
   BOOL   synchronous
 
   BOOL   participating
 
   BOOL   ready [3]
 
   HNDLE   conn
 
crate [MAX_CRATES]
 
INT event_number
 
INT request_stop_event
 
static BOOL enable_rpc_master
 
struct readout_module rpc_master_module
 

Macro Definition Documentation

#define DEFINE_RPC_LIST

Definition at line 13 of file rpc_master.cpp.

Function Documentation

BOOL crate_is_participating ( INT  crate_number)

Definition at line 193 of file rpc_master.cpp.

References crate, and crate_number.

Referenced by vmic_ttl_start_block().

194 {
195  return crate[crate_number].participating;
196 }
INT cycle_ram ( )

Definition at line 202 of file rpc_master.cpp.

References event_number.

203 {
204  return ((event_number + 1) % 2) + 1;
205 }
INT rpc_master_bor ( )
INT rpc_master_eor ( )
INT rpc_master_init ( )
INT rpc_master_poll_dead ( )
INT rpc_master_poll_live ( )
INT rpc_master_pre_bor ( )
INT rpc_master_read ( char *  pevent)
INT rpc_ready_for_cycle ( INT  index,
void *  prpc_param[] 
)
INT rpc_request_stop ( INT  index,
void *  prpc_param[] 
)

Variable Documentation

HNDLE conn

Definition at line 31 of file rpc_master.cpp.

struct { ... } crate[MAX_CRATES]
BOOL enable_rpc_master
static

Definition at line 36 of file rpc_master.cpp.

BOOL enabled

Definition at line 27 of file rpc_master.cpp.

INT event_number

Definition at line 34 of file rpc_master.cpp.

BOOL participating

Definition at line 29 of file rpc_master.cpp.

BOOL ready[3]

Definition at line 30 of file rpc_master.cpp.

INT request_stop_event

Definition at line 35 of file rpc_master.cpp.

struct readout_module rpc_master_module
BOOL synchronous

Definition at line 28 of file rpc_master.cpp.