Package xal.smf.impl
Class WireHarp.DaqConfig
java.lang.Object
xal.smf.scada.ScadaRecord
xal.smf.impl.profile.ParameterSet
xal.smf.impl.WireHarp.DaqConfig
- All Implemented Interfaces:
Cloneable
,ProfileDevice.IProfileDomain
,DataListener
- Enclosing class:
- WireHarp
Class
· There is a pretty egregious kluge on the attribute
WireHarp.DaqConfig
. A data structure containing fields
that indicate the status of the data acquisition capabilities. In
particular, there are status records for the operation of each wire
within each measurement plane (eg., horizontal, vertical, diagonal).
NOTE
· There is a pretty egregious kluge on the attribute
DaqConfig.cntWires
. The value is hard coded with the
constant DaqConfig.CNT_WIRES
since there is no way to
dynamically acquire this value.- Since:
- Apr 11, 2014
- Author:
- Christopher K. Allen
-
Nested Class Summary
Nested classes/interfaces inherited from class xal.smf.scada.ScadaRecord
ScadaRecord.IFieldDescriptor
-
Field Summary
FieldsModifier and TypeFieldDescriptiondouble[]
Array of wire positions on the beam axis for the diagonal projection plane.double[]
Array of wire positions on the beam axis for the horizontal projection plane.double[]
Array of wire positions on the beam axis for the vertical projection plane.int
Type code of the current fitting profile
0 = Super Gaussian
1 = Super Gaussian × Gaussian
2 = Super Gaussian + Gaussian
3 = Super Gaussian × Parabolastatic final ScadaFieldMap
Map of field names to field SCADA descriptors for this structureint
Bit record indicating operation status for each wire of the diagonal wire set.int
Bit record indicating operation status for each wire of the horizontal wire set.int
Bit record indicating operation status for each wire of the vertical wire set. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic WireHarp.DaqConfig
Convenience method for retrieving a new initialized data structure populated from the given device state.double
Return the left-most position of the projection interval, that is, the minimum valued endpoint.double
Return the length of the real interval containing the projection data.int
Returns the number of signal samples in the profile data, that is, the number of data points in the domain.double[]
Returns the array of sampling positions for the profile databoolean
validWire
(ProfileDevice.ANGLE ang, int index) Check if the indicated wire is valid, that is, producing valid data.int
Returns the number of valid harp wires for the given projection plane.boolean[]
Creates an array of status flags for each harp wire for the given transverse plane.Methods inherited from class xal.smf.impl.profile.ParameterSet
dataLabel
Methods inherited from class xal.smf.scada.ScadaRecord
clone, getFieldDescriptor, getFieldDescriptorMap, getFieldDescriptors, loadHardwareValues, setFieldFromPV, setHardwareValues, setPvFromField, toString, update, write
-
Field Details
-
FLD_MAP
Map of field names to field SCADA descriptors for this structure -
arrPosHor
Array of wire positions on the beam axis for the horizontal projection plane. -
arrPosVer
Array of wire positions on the beam axis for the vertical projection plane. -
arrPosDia
Array of wire positions on the beam axis for the diagonal projection plane. -
recWiresHor
Bit record indicating operation status for each wire of the horizontal wire set.
bolStatus = 2n & statWireHor
where n=0,1,... is the index of the wire.
Do Not access this field directly! -
recWiresVer
Bit record indicating operation status for each wire of the vertical wire set.
bolStatus = 2n & statWireVer
where n=0,1,... is the index of the wire.
Do Not access this field directly! -
recWiresDia
Bit record indicating operation status for each wire of the diagonal wire set.
bolStatus = 2n & statWireDia
where n=0,1,... is the index of the wire.
Do Not access this field directly! -
fitTypeCode
Type code of the current fitting profile
0 = Super Gaussian
1 = Super Gaussian × Gaussian
2 = Super Gaussian + Gaussian
3 = Super Gaussian × Parabola
-
-
Constructor Details
-
DaqConfig
public DaqConfig()Create a new, uninitializedDaqConfig
object.- Since:
- Jan 21, 2010
-
DaqConfig
Create a newDaqConfig
object containing the status information of the given device.- Parameters:
smfHarp
- wire harp device under query- Throws:
ConnectionException
- unable to connect parameter read back channelGetException
- general field initialization exception- Since:
- Jan 21, 2010
-
-
Method Details
-
acquire
Convenience method for retrieving a new initialized data structure populated from the given device state.- Parameters:
smfHarp
- data acquisition device- Returns:
- current set of device status parameters
- Throws:
ConnectionException
- unable to connect parameter read back channelGetException
- general field initialization exception- Since:
- Mar 20, 2014
-
validWireCount
Returns the number of valid harp wires for the given projection plane.- Parameters:
ang
- projection angle for the harp- Returns:
- number of wires producing valid data for the given harp
- Since:
- Jun 5, 2014
-
validWire
Check if the indicated wire is valid, that is, producing valid data. The given wire index must be in the range [0,N] where N is the number of wires in the harp.- Parameters:
ang
- the transverse plane of the profile (i.e., wire set)index
- the index of the wire within the harp- Returns:
true
if the indicated wire is working correctly,false
otherwise- Throws:
IllegalArgumentException
- the index provided was not in the correct range- Since:
- Apr 14, 2014
-
validWires
Creates an array of status flags for each harp wire for the given transverse plane. The array size equals the number of wires in the harp (cntWires
), the index into the array is the index of the harp wire.- Parameters:
ang
- transverse plane of the profile- Returns:
- array containing status flags indexed by harp wire
- Since:
- Apr 14, 2014
-
getSampleCount
Description copied from interface:ProfileDevice.IProfileDomain
Returns the number of signal samples in the profile data, that is, the number of data points in the domain.- Specified by:
getSampleCount
in interfaceProfileDevice.IProfileDomain
- Parameters:
angle
- the projection angle of the data set- Returns:
- number of data samples of the given angle
- Since:
- Apr 24, 2014
- See Also:
-
getSamplePositions
Returns the array of sampling positions for the profile data- Specified by:
getSamplePositions
in interfaceProfileDevice.IProfileDomain
- Parameters:
angle
- the projection angle of the data set- Returns:
- sample axis positions of the projection data
- Since:
- Apr 24, 2014
- See Also:
-
getInitialPosition
Description copied from interface:ProfileDevice.IProfileDomain
Return the left-most position of the projection interval, that is, the minimum valued endpoint.- Specified by:
getInitialPosition
in interfaceProfileDevice.IProfileDomain
- Parameters:
angle
- the projection angle of the data set- Returns:
- left endpoint of the projection interval
- Since:
- Apr 24, 2014
- See Also:
-
getIntervalLength
Description copied from interface:ProfileDevice.IProfileDomain
Return the length of the real interval containing the projection data. That is, return the length of the smallest interval containing the projection data. Note that this value may be different than the "scan length" as it may depend upon the measurement plane. The value, L, is typically given by the formula
L = α Nsteps ΔL
where α is the correction factor, Nsteps is the number of scan steps, and ΔL is the step length. For example, if the scan actuator arm is physically at a 45 ° angle to the given measurement plane then α = 1/√2.- Specified by:
getIntervalLength
in interfaceProfileDevice.IProfileDomain
- Parameters:
angle
- the projection angle of the data set- Returns:
- length of the interval of definition for the given data set
- Since:
- Apr 24, 2014
- See Also:
-