adsc Class Reference

Driver for ADSC detectors (Q4, Q4r, Q210, Q210r, Q270, Q315, Q315r). More...

Inheritance diagram for adsc:

ADDriver asynNDArrayDriver

List of all members.

Public Member Functions

 adsc (const char *portName, const char *modelName)
 Constructor for ADSC driver; most parameters are simply passed to ADDriver::ADDriver.
virtual ~adsc ()
virtual asynStatus writeInt32 (asynUser *pasynUser, epicsInt32 value)
 Called when asyn clients call pasynInt32->write().
virtual asynStatus writeFloat64 (asynUser *pasynUser, epicsFloat64 value)
 Called when asyn clients call pasynFloat64->write().
virtual asynStatus writeOctet (asynUser *pasynUser, const char *value, size_t nChars, size_t *nActual)
 Called when asyn clients call pasynOctet->write().
virtual asynStatus drvUserCreate (asynUser *pasynUser, const char *drvInfo, const char **pptypeName, size_t *psize)
 Sets pasynUser->reason to one of the enum values for the parameters defined for this class if the drvInfo field matches one the strings defined for it.
void report (FILE *fp, int details)
 Report status of the driver.
void imageAcquisitionTask ()

Protected Member Functions

AdscStatus_t acquireImages ()
void acquisitionFinished (int adstatus)
void clearLastDarksParameters ()
AdscStatus_t createFileNameNoIncrement (char *dst, size_t dstSize)
const char * getAdscCcdStateString (int ccdState)
AdscStatus_t getImage (int lastImage)
int getImageSize (AdscModel_t model, int binMode)
int getImageSizeX (AdscModel_t model, int binMode)
int getImageSizeY (AdscModel_t model, int binMode)
AdscStatus_t loadPerDatasetParameters ()
AdscStatus_t loadPerImageParameters ()
AdscStatus_t readDetectorCondition ()
AdscStatus_t resetControlLibrary ()
AdscStatus_t setBinModeInParams (int binMode)
void setLastDarksParameters (double exposureTime, int adc, int bin)
AdscStatus_t setOkToExpose (int isEnabled)
AdscStatus_t setExternSwTriggerControl (AdscExternSwTriggerControl_t value)
int shouldTakeDarks ()
AdscStatus_t startExposure ()
AdscStatus_t stopExposure ()
AdscStatus_t takeDarks (const char *destDir)
AdscStatus_t takeDarksIfRequired ()
AdscStatus_t takeImage (const char *fullFileName, int imageKind, int lastImage, int triggerMode)
AdscStatus_t imageAcquired ()
AdscStatus_t waitForDetectorState (int desiredState, double timeout, int failOnErrorState)
AdscStatus_t waitForExternalTrigger (epicsEventId eventId)
AdscStatus_t writeDetectorParametersBeforeDataset ()
AdscStatus_t writeDetectorParametersBeforeImage ()

Protected Attributes

AdscModel_t model
int lastImage
double lastDarksExposureTime
int lastDarksAdc
int lastDarksBin
int perDatasetReuseDarks
int perDatasetDezinger
int perDatasetAdc
int perDatasetRaw
int perDatasetImageTransform
int perDatasetStoredDarks
int perDatasetAxis
double perDatasetExposureTime
double perDatasetAcquirePeriod
int perDatasetBin
int perDatasetImageMode
int perDatasetTriggerMode
int perDatasetNumImages
double perImageBeamCenterX
double perImageBeamCenterY
double perImageDistance
double perImageTwoTheta
double perImageWavelength
double perImageImageWidth
double perImagePhi
double perImageOmega
double perImageKappa
char perImageFullFileName [MAX_FILENAME_LEN]
epicsEventId startEventId
epicsEventId stopEventId
epicsEventId startTriggerEventId
epicsEventId stopTriggerEventId
epicsEventId lastImageEventId


Detailed Description

Driver for ADSC detectors (Q4, Q4r, Q210, Q210r, Q270, Q315, Q315r).

Constructor & Destructor Documentation

adsc::adsc ( const char *  portName,
const char *  modelName 
)

Constructor for ADSC driver; most parameters are simply passed to ADDriver::ADDriver.

After calling the base class constructor, this method creates a thread to collect the detector data and sets reasonable default values for the parameters defined in this class, asynNDArrayDriver and ADDriver.

Parameters:
[in] portName The name of the asyn port driver to be created
[in] modelName The model name of the detector being used; choices are "Q4", "Q4r", "Q210", "Q210r", "Q270", "Q315", or "Q315r"

adsc::~adsc (  )  [virtual]


Member Function Documentation

AdscStatus_t adsc::acquireImages (  )  [protected]

void adsc::acquisitionFinished ( int  adstatus  )  [protected]

void adsc::clearLastDarksParameters (  )  [protected]

AdscStatus_t adsc::createFileNameNoIncrement ( char *  dst,
size_t  dstSize 
) [protected]

asynStatus adsc::drvUserCreate ( asynUser *  pasynUser,
const char *  drvInfo,
const char **  pptypeName,
size_t *  psize 
) [virtual]

Sets pasynUser->reason to one of the enum values for the parameters defined for this class if the drvInfo field matches one the strings defined for it.

If the parameter is not recognized by this class then calls ADDriver::drvUserCreate. Uses asynPortDriver::drvUserCreateParam.

Parameters:
[in] pasynUser pasynUser structure that driver modifies
[in] drvInfo String containing information about what driver function is being referenced
[out] pptypeName Location in which driver puts a copy of drvInfo
[out] psize Location where driver puts size of param
Returns:
asynSuccess if a matching string was found, asynError if not found

Reimplemented from ADDriver.

const char * adsc::getAdscCcdStateString ( int  ccdState  )  [protected]

AdscStatus_t adsc::getImage ( int  lastImage  )  [protected]

int adsc::getImageSize ( AdscModel_t  model,
int  binMode 
) [protected]

int adsc::getImageSizeX ( AdscModel_t  model,
int  binMode 
) [protected]

int adsc::getImageSizeY ( AdscModel_t  model,
int  binMode 
) [protected]

AdscStatus_t adsc::imageAcquired (  )  [protected]

void adsc::imageAcquisitionTask (  ) 

AdscStatus_t adsc::loadPerDatasetParameters (  )  [protected]

AdscStatus_t adsc::loadPerImageParameters (  )  [protected]

AdscStatus_t adsc::readDetectorCondition (  )  [protected]

void adsc::report ( FILE *  fp,
int  details 
) [virtual]

Report status of the driver.

Prints details about the driver if details>0. It then calls the ADDriver::report() method.

Parameters:
[in] fp File pointed passed by caller where the output is written to
[in] details If >0 then driver details are printed

Reimplemented from asynNDArrayDriver.

AdscStatus_t adsc::resetControlLibrary (  )  [protected]

AdscStatus_t adsc::setBinModeInParams ( int  binMode  )  [protected]

AdscStatus_t adsc::setExternSwTriggerControl ( AdscExternSwTriggerControl_t  value  )  [protected]

void adsc::setLastDarksParameters ( double  exposureTime,
int  adc,
int  bin 
) [protected]

AdscStatus_t adsc::setOkToExpose ( int  isEnabled  )  [protected]

int adsc::shouldTakeDarks (  )  [protected]

AdscStatus_t adsc::startExposure (  )  [protected]

AdscStatus_t adsc::stopExposure (  )  [protected]

AdscStatus_t adsc::takeDarks ( const char *  destDir  )  [protected]

AdscStatus_t adsc::takeDarksIfRequired (  )  [protected]

AdscStatus_t adsc::takeImage ( const char *  fullFileName,
int  imageKind,
int  lastImage,
int  triggerMode 
) [protected]

AdscStatus_t adsc::waitForDetectorState ( int  desiredState,
double  timeout,
int  failOnErrorState 
) [protected]

AdscStatus_t adsc::waitForExternalTrigger ( epicsEventId  eventId  )  [protected]

AdscStatus_t adsc::writeDetectorParametersBeforeDataset (  )  [protected]

AdscStatus_t adsc::writeDetectorParametersBeforeImage (  )  [protected]

asynStatus adsc::writeFloat64 ( asynUser *  pasynUser,
epicsFloat64  value 
) [virtual]

Called when asyn clients call pasynFloat64->write().

This function performs actions for some parameters, including ADAcquireTime, AdscTwoTheta, etc. For all parameters it sets the value in the parameter library and calls any registered callbacks.

Parameters:
[in] pasynUser pasynUser structure that encodes the reason and address
[in] value Value to write

asynStatus adsc::writeInt32 ( asynUser *  pasynUser,
epicsInt32  value 
) [virtual]

Called when asyn clients call pasynInt32->write().

This function performs actions for some parameters, including ADAcquire, ADBinX, etc. For all parameters it sets the value in the parameter library and calls any registered callbacks.

Parameters:
[in] pasynUser pasynUser structure that encodes the reason and address
[in] value Value to write

Reimplemented from ADDriver.

asynStatus adsc::writeOctet ( asynUser *  pasynUser,
const char *  value,
size_t  nChars,
size_t *  nActual 
) [virtual]

Called when asyn clients call pasynOctet->write().

This function performs actions for some parameters, including NDFilePath, etc. For all parameters it sets the value in the parameter library and calls any registered callbacks.

Parameters:
[in] pasynUser pasynUser structure that encodes the reason and address
[in] value Value to write
[in] nChars Number of characters to write
[out] nActual Number of characters actually written

Reimplemented from asynNDArrayDriver.


Member Data Documentation

int adsc::lastDarksAdc [protected]

int adsc::lastDarksBin [protected]

double adsc::lastDarksExposureTime [protected]

int adsc::lastImage [protected]

epicsEventId adsc::lastImageEventId [protected]

AdscModel_t adsc::model [protected]

double adsc::perDatasetAcquirePeriod [protected]

int adsc::perDatasetAdc [protected]

int adsc::perDatasetAxis [protected]

int adsc::perDatasetBin [protected]

int adsc::perDatasetDezinger [protected]

double adsc::perDatasetExposureTime [protected]

int adsc::perDatasetImageMode [protected]

int adsc::perDatasetNumImages [protected]

int adsc::perDatasetRaw [protected]

int adsc::perDatasetReuseDarks [protected]

int adsc::perDatasetStoredDarks [protected]

int adsc::perDatasetTriggerMode [protected]

double adsc::perImageBeamCenterX [protected]

double adsc::perImageBeamCenterY [protected]

double adsc::perImageDistance [protected]

char adsc::perImageFullFileName[MAX_FILENAME_LEN] [protected]

double adsc::perImageImageWidth [protected]

double adsc::perImageKappa [protected]

double adsc::perImageOmega [protected]

double adsc::perImagePhi [protected]

double adsc::perImageTwoTheta [protected]

double adsc::perImageWavelength [protected]

epicsEventId adsc::startEventId [protected]

epicsEventId adsc::startTriggerEventId [protected]

epicsEventId adsc::stopEventId [protected]

epicsEventId adsc::stopTriggerEventId [protected]


The documentation for this class was generated from the following file:

Generated on Tue Aug 25 16:53:03 2009 for areaDetector by  doxygen 1.5.7.1