/* * drvVetroc.hh * Generic AreaDetector driver for JLAB VETROC board * * Created on: Oct 27, 2017 * Author: Hovanes Egiyan */ #ifndef VETROCAPP_SRC_DRVVETROC_HH_ #define VETROCAPP_SRC_DRVVETROC_HH_ /************/ /* Includes */ /************/ #include #include #include #include #include #include #include #include /* EPICS includes */ #include #include #include #include #include #include #include #include #include #include #include #include #include extern "C" { #include "jvme.h" #include "vetrocLib.h" } #include #include #include #include #include #include #include #include #include "ADDriver.h" #include "MtxLock.hh" #include "MutexedClass.hh" class drvVetroc: public ADDriver, public MutexedClass { protected: class VMELock { VMELock() { vmeBusLock(); } ~VMELock() { vmeBusUnlock(); } void lock() { vmeBusLock(); } void unlock() { vmeBusUnlock(); } }; static std::string driverName; // Name of the driver static unsigned paramNumber; // Number of parameters for MO board static unsigned maxChannels; // Number of channels on the MO board bool driverExists; // Flag indicating if already exists unsigned baseAddr; // Base address of the VME module epicsEventId eventID; // Event ID for waking up reading thread public: drvVetroc( const std::string portName, const unsigned baseAddr, int maxSizeX, int maxSizeY, NDDataType_t dataType, int maxBuffers, size_t maxMemory, int priority, int stackSize ); virtual ~drvVetroc(); }; #endif /* VETROCAPP_SRC_DRVVETROC_HH_ */