/*============================================================================= Name: dbaUtil.h Abs: structures for database access Auth:16-feb-2010, dfairley created Rev: ----------------------------------------------------------------------------*/ #include "copyright_SLAC.h" /*----------------------------------------------------------------------------- Mod: (newest to oldest) DD-MMM-YYYY, My Name: Changed such and such to so and so. etc. etc. DD-MMM-YYYY, Your Name: More changes ... The ordering of the revision history should be such that the NEWEST changes are at the HEAD of the list. =============================================================================*/ #ifndef INCdbaUtilH #define INCdbaUtilH #ifdef __cplusplus extern "C" { #endif #include /* EPICS dbAddr struct */ #define MAX_WF_SIZE 128 /* EPICS waveform NELM */ /* ** data struct for data msgs to epicsSend thread */ typedef struct { char *pvName_p; /* ptr to pv name */ DBADDR *dbAddr_ps; /* ptr to DBADDR; the val is put into this PV */ short dbrType; /* DBR type of data val */ double val; /* the value to place into PV */ } epicsData_ts; /* ** msg to epicsSend thread. This contains an array of epicsData_ts */ typedef struct { int nElements; epicsData_ts data[MAX_MEAS_DEVICES + MAX_ACT_DEVICES + MAX_STATES]; } epicsSendMsg_ts; /* DBNameToAddr structure for pvs read locally to this controller */ typedef struct { char pvName_ca[MAX_CHAR_EPICS_NAME]; /* null terminated pvname with which to */ /* dbNametoAddr */ DBADDR dbAddr; /* PV's dbNameToAddr address */ unsigned short value_s; /* value if unsigned short */ double value_d; /* value if double */ char value_ca [MAX_CHAR_EPICS_NAME]; /* value if string */ unsigned short value_sa [MAX_WF_SIZE]; /* value if waveform of unsigned shorts */ double value_da [MAX_WF_SIZE]; /* value if waveform of doubles */ } devNameAddr_ts; #ifdef __cplusplus } #endif #endif /*INCdbaUtilH*/