Package gda.device.detector.countertimer
Class TfgScalerWithDarkCurrent
java.lang.Object
gda.factory.ConfigurableBase
gda.factory.FindableConfigurableBase
gda.device.DeviceBase
gda.device.scannable.ScannableBase
gda.device.detector.DetectorBase
gda.device.detector.countertimer.CounterTimerBase
gda.device.detector.countertimer.TFGCounterTimer
gda.device.detector.countertimer.TfgScaler
gda.device.detector.countertimer.TfgScalerWithDarkCurrent
- All Implemented Interfaces:
CounterTimer,Detector,DarkCurrentDetector,Device,Scannable,Configurable,Findable,gda.observable.IObservable,Serializable
- Direct Known Subclasses:
TfgScalerWithLogValues,TFGScalerWithRatio
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classParameters for dark current collection -
Field Summary
Fields inherited from class gda.device.detector.countertimer.TfgScaler
numChannelsToRead, scaler, timeChannelRequiredFields inherited from class gda.device.detector.countertimer.TFGCounterTimer
isTFGv2Fields inherited from class gda.device.detector.countertimer.CounterTimerBase
slave, timerFields inherited from class gda.device.detector.DetectorBase
collectionTimeFields inherited from class gda.device.scannable.ScannableBase
__doc__, DEFAULT_INPUT_NAME, DEFAULT_OUTPUT_FORMAT, extraNames, inputNames, level, outputFormatFields inherited from class gda.device.DeviceBase
DEFAULT_PROTECTION_LEVEL_PROPERTYFields inherited from interface gda.device.Scannable
ATTR_NEXUS_CATEGORY, ATTR_NX_CLASS, DEFAULT_INPUT_NAME, VALUE_UNAVAILABLE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidReads and sets the darkCurrentprotected DoubleadjustChannelForDarkCurrent(Double rawCounts, Double dkCounts, Double collectionTime) protected double[]adjustForDarkCurrent(double[] values, Double collectionTime) voidCalled for every Scannable at the end of a group of nested scans (or a single scan if that is the case).voidReads the dark current.Double[]booleanbooleanvoidsetDarkCurrent(DarkCurrentResults darkCurrent) voidsetDarkCurrentCollectionTime(Double darkCurrentCollectionTime) voidsetDarkCurrentRequired(boolean darkCurrentRequired) voidsetUseReset(boolean useReset) True by default, set to false if the shutter used to collect the dark current should not have reset called before opening.Methods inherited from class gda.device.detector.countertimer.TfgScaler
addFrameSet, addFrameSet, atCommandFailure, atScanLineStart, clearFrameSets, collectData, configure, countAsync, createsOwnFiles, getAttribute, getDescription, getDetectorID, getDetectorType, getFirstDataChannel, getInputNames, getMinimumReadoutDelay, getNumChannelsToRead, getScaler, getScalerName, getTotalChans, isTimeChannelRequired, readChannel, readChans, readFrame, readFrame, readout, readoutCurrentFrame, readoutFrames, setAttribute, setFirstDataChannel, setMinimumReadoutDelay, setNumChannelsToRead, setScaler, setScalerName, setTimeChannelRequired, start, stopMethods inherited from class gda.device.detector.countertimer.TFGCounterTimer
isTFGv2, setTFGv2Methods inherited from class gda.device.detector.countertimer.CounterTimerBase
getCurrentCycle, getCurrentFrame, getMaximumFrames, getStatus, getTimer, getTimerName, isSlave, loadFrameSets, restart, setCycles, setSlave, setTimer, setTimerNameMethods inherited from class gda.device.detector.DetectorBase
asynchronousMoveTo, checkPositionValid, endCollection, getCollectionTime, getDataDimensions, getPosition, isBusy, prepareForCollection, setCollectionTime, toFormattedStringMethods inherited from class gda.device.scannable.ScannableBase
__call__, __call__, __doc__, __getitem__, __len__, __repr__, __str__, atLevelEnd, atLevelMoveStart, atLevelStart, atPointEnd, atPointStart, atScanLineEnd, externalToInternal, getExtraNames, getLevel, getOutputFormat, getScanMetadataAttribute, getScanMetadataAttributeNames, getScanMetadataAttributes, internalToExternal, isAt, moveTo, rawAsynchronousMoveTo, rawGetPosition, setExtraNames, setInputNames, setLevel, setOutputFormat, setScanMetadataAttribute, setScanMetadataAttributes, throwExceptionIfInvalidTarget, toString, validateScannable, valueUnavailableString, waitWhileBusy, waitWhileBusyMethods inherited from class gda.device.DeviceBase
addIObserver, close, deleteIObserver, deleteIObservers, getName, getProtectionLevel, isBeingObserved, isConfigureAtStartup, notifyIObservers, setConfigureAtStartup, setName, setProtectionLevelMethods inherited from class gda.factory.ConfigurableBase
isConfigured, reconfigure, setConfiguredMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface gda.factory.Configurable
isConfigureAtStartup, isConfigured, reconfigureMethods inherited from interface gda.device.Detector
endCollection, getCollectionTime, getDataDimensions, getFileStructure, prepareForCollection, setCollectionTime, waitWhileBusyMethods inherited from interface gda.device.Device
close, getProtectionLevel, setProtectionLevelMethods inherited from interface gda.observable.IObservable
addIObserver, deleteIObserver, deleteIObserversMethods inherited from interface gda.device.Scannable
asynchronousMoveTo, atLevelEnd, atLevelMoveStart, atLevelStart, atPointEnd, atPointStart, atScanLineEnd, checkPositionValid, getExtraNames, getLevel, getOutputFormat, getPosition, getScanMetadataAttribute, getScanMetadataAttributeNames, getScanMetadataAttributes, isAt, isBusy, moveTo, setExtraNames, setInputNames, setLevel, setOutputFormat, setScanMetadataAttribute, setScanMetadataAttributes, toFormattedString
-
Constructor Details
-
TfgScalerWithDarkCurrent
public TfgScalerWithDarkCurrent()
-
-
Method Details
-
acquireDarkCurrent
Reads and sets the darkCurrent- Throws:
DeviceExceptionException
-
atScanStart
Reads the dark current.- Specified by:
atScanStartin interfaceScannable- Overrides:
atScanStartin classScannableBase- Throws:
DeviceException- See Also:
-
atScanEnd
Description copied from class:ScannableBaseCalled for every Scannable at the end of a group of nested scans (or a single scan if that is the case).Note that this is only called if the Scan finishes normally, or has been requested to finish early. This will not be called if the scan finishes due to an exception of any kind. See
Scannable.atCommandFailure()Default behaviour is to do nothing. Inheriting classes have the option to implement this if their specific behaviour requires it.- Specified by:
atScanEndin interfaceScannable- Overrides:
atScanEndin classTfgScaler- Throws:
DeviceException- See Also:
-
setDarkCurrent
-
getDarkCurrentResults
- Specified by:
getDarkCurrentResultsin interfaceDarkCurrentDetector- Returns:
- results from Dark Current reading, typically ordered I0, It, Iref
-
getDarkCurrent
-
isDarkCurrentRequired
public boolean isDarkCurrentRequired() -
setDarkCurrentRequired
public void setDarkCurrentRequired(boolean darkCurrentRequired) -
setDarkCurrentCollectionTime
-
getDarkCurrentCollectionTime
-
isUseReset
public boolean isUseReset() -
setUseReset
public void setUseReset(boolean useReset) True by default, set to false if the shutter used to collect the dark current should not have reset called before opening.- Parameters:
useReset-
-
adjustForDarkCurrent
-
adjustChannelForDarkCurrent
-