public abstract class Electromagnet extends Magnet
| Modifier and Type | Class and Description |
|---|---|
static class |
Electromagnet.Property
accessible properties
|
| Modifier and Type | Field and Description |
|---|---|
protected boolean |
_useFieldReadback
indicates whether to use the actual field readback or the field setting in the getField() method
|
static java.lang.String |
FIELD_RB_HANDLE
field readback handle
|
protected java.lang.String |
mainSupplyId
the ID of this magnet's main power supply
|
static java.lang.String |
s_strType
the node type
|
leff, m_bucMagnetchannelSuite, m_bolIsSoft, m_bolStatus, m_bolValid, m_bucAlign, m_bucAper, m_bucTwiss, m_dblLen, m_dblPos, m_dblS, m_mapAttrs, m_objAccel, m_seqParent, m_strEId, m_strId, m_strPIdDIPOLE, HORIZONTAL, NO_ORIENTATION, OCT, OCTUPOLE, poles, QUAD, QUADRUPOLE, SEXT, SEXTUPOLE, SOL, SOLENOID, VERTICAL| Constructor and Description |
|---|
Electromagnet(java.lang.String strId)
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
Channel |
findChannel(java.lang.String handle)
Find the channel for the specified handle searching the main supply if necessary.
|
double |
getCurrent()
Get the main power supply current in this electromagnet via ca (A)
|
int |
getCycleState()
Gets the cycle state of the magnet.
|
double |
getDesignPropertyValue(java.lang.String propertyName)
Get the design value for the specified property
|
double |
getField()
Get the field in this electromagnet via ca.
|
double |
getFieldInt()
Get the integrated field in this electromagnet
T-m/(m^(n-1)), where n = 1 for dipole, 2 for quad, etc.
|
double |
getFieldReadback()
Get the field in this electromagnet via ca.
|
double |
getFieldSetting()
Get the value to which the main power supply's field contribution is set.
|
java.util.Collection<java.lang.String> |
getHandles()
Get the channel handles.
|
Channel[] |
getLivePropertyChannels(java.lang.String propertyName)
Get the array of channels for the specified property
|
double |
getLivePropertyValue(java.lang.String propertyName,
double[] channelValues)
Get the live property value for the corresponding array of channel values in the order given by getLivePropertyChannels()
|
MagnetMainSupply |
getMainSupply()
Get the main power supply for this magnet.
|
double |
getTotalFieldSetting()
Get the value to which the field is set including both the main supply and possible trim supply contributions.
|
boolean |
isPermanent()
Since this is an electro-magnet we override the inherited method to
advertise this characteristic.
|
double |
lowerAlarmFieldLimit()
Get the field lower settable limit of the main power supply in T/(m^(n-1)), where n = 1 for dipole, 2 for quad, etc.
|
double |
lowerCurrentLimit()
get the main power supply current lower settable limit (A)
|
double |
lowerDisplayFieldLimit()
Get the field lower settable limit of the main power supply in T/(m^(n-1)), where n = 1 for dipole, 2 for quad, etc.
|
double |
lowerFieldLimit()
Get the field lower settable limit of the main power supply
in T/(m^(n-1)), where n = 1 for dipole, 2 for quad, etc.
|
double |
lowerWarningFieldLimit()
Get the field lower settable limit of the main power supply in T/(m^(n-1)), where n = 1 for dipole, 2 for quad, etc.
|
void |
setCurrent(double newCurrent)
set the main power supply current in the magnet (A)
|
void |
setCycleEnable(boolean enable)
Set the cycle enable state of the magnet.
|
void |
setField(double newField)
Set the main power supply field contribution in the magnet.
|
void |
setUseFieldReadback(boolean useFieldReadback)
Set whether or not to use the field readback in the getField() method.
|
double |
toCAFromField(double field)
Convert the field value to a channel access value.
|
double |
toFieldFromCA(double rawValue)
Convert the raw channel access value to get the field.
|
void |
update(DataAdaptor adaptor)
Update the node with data from the provided adaptor.
|
protected void |
updatePowerSupplies(DataAdaptor powerSupplyAdaptor)
Update data from the power supply data adaptor.
|
double |
upperAlarmFieldLimit()
Get the field upper settable limit of the main power supply in T/(m^(n-1)), where n = 1 for dipole, 2 for quad, etc.
|
double |
upperCurrentLimit()
get the main power supply current lower settable limit (A)
|
double |
upperDisplayFieldLimit()
Get the field upper settable limit of the main power supply in T/(m^(n-1)), where n = 1 for dipole, 2 for quad, etc.
|
double |
upperFieldLimit()
Get the field upper settable limit of the main power supply
in T/(m^(n-1)), where n = 1 for dipole, 2 for quad, etc.
|
double |
upperWarningFieldLimit()
Get the field upper settable limit of the main power supply in T/(m^(n-1)), where n = 1 for dipole, 2 for quad, etc.
|
boolean |
useFieldReadback()
Determines whether the field readback is used in the getField() method.
|
void |
write(DataAdaptor adaptor)
Encode data from the node into the provided adaptor.
|
protected void |
writePowerSupplies(DataAdaptor powerSupplyAdaptor)
Write data to the power supply data adaptor.
|
addBucket, getDesignField, getDfltField, getEffLength, getMagBucket, getNormField, getOrientation, getPolarity, getTangField, isCorrector, isHorizontal, isMagnet, isPole, isSkew, isVertical, setDfltField, setMagBucketchannelSuite, clear, dataLabel, getAccelerator, getAlign, getAndConnectChannel, getAper, getBucket, getBuckets, getChannel, getEId, getId, getLength, getParent, getPId, getPitchAngle, getPosition, getPrimaryAncestor, getRollAngle, getSDisplay, getSoftType, getStatus, getTwiss, getType, getValid, getXOffset, getYawAngle, getYOffset, getZOffset, hasBucket, hasParent, isKindOf, lazilyGetAndConnect, removeFromParent, setAccelerator, setAlign, setAper, setLength, setParent, setPitchAngle, setPosition, setRollAngle, setSDisplay, setStatus, setTwiss, setValid, setXOffset, setYawAngle, setYOffset, setZOffset, toStringclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitisKindOfpublic static final java.lang.String s_strType
public static final java.lang.String FIELD_RB_HANDLE
protected boolean _useFieldReadback
protected java.lang.String mainSupplyId
public void update(DataAdaptor adaptor) throws java.lang.NumberFormatException
update in interface DataListenerupdate in class AcceleratorNodeadaptor - The data providerjava.lang.NumberFormatExceptionprotected void updatePowerSupplies(DataAdaptor powerSupplyAdaptor)
powerSupplyAdaptor - The data provider of power supply information.public void write(DataAdaptor adaptor)
write in interface DataListenerwrite in class AcceleratorNodeadaptor - The data storeprotected void writePowerSupplies(DataAdaptor powerSupplyAdaptor)
powerSupplyAdaptor - The data sink for the power supply informationpublic void setUseFieldReadback(boolean useFieldReadback)
useFieldReadback - true to use the field readback and false to use the field setting.public boolean useFieldReadback()
public java.util.Collection<java.lang.String> getHandles()
getHandles in class AcceleratorNodepublic Channel findChannel(java.lang.String handle)
findChannel in class AcceleratorNodehandle - The handle for the channel to get.public MagnetMainSupply getMainSupply()
public double getDesignPropertyValue(java.lang.String propertyName)
getDesignPropertyValue in class AcceleratorNodepublic double getLivePropertyValue(java.lang.String propertyName,
double[] channelValues)
getLivePropertyValue in class AcceleratorNodepublic Channel[] getLivePropertyChannels(java.lang.String propertyName)
getLivePropertyChannels in class AcceleratorNodepublic void setCycleEnable(boolean enable)
throws ConnectionException,
PutException
enable - True to enable cycling; false to disable cycling.ConnectionExceptionPutExceptionpublic int getCycleState()
throws ConnectionException,
GetException
ConnectionExceptionGetExceptionpublic double getField()
throws ConnectionException,
GetException
ConnectionExceptionGetExceptionpublic double getFieldReadback()
throws ConnectionException,
GetException
ConnectionExceptionGetExceptionpublic double getFieldInt()
throws ConnectionException,
GetException
ConnectionExceptionGetExceptionpublic void setField(double newField)
throws ConnectionException,
PutException
newField - is the new field level in T/(m^(n-1)), where n = 1 for dipole, 2 for quad, etc.ConnectionExceptionPutExceptionpublic double getFieldSetting()
throws ConnectionException,
GetException
ConnectionExceptionGetExceptionpublic double getTotalFieldSetting()
throws ConnectionException,
GetException
ConnectionExceptionGetExceptionpublic final double toFieldFromCA(double rawValue)
rawValue - the raw channel valuepublic final double toCAFromField(double field)
field - the magnetic field in T/m^(n-1)public double upperFieldLimit()
throws ConnectionException,
GetException
ConnectionExceptionGetExceptionpublic double lowerFieldLimit()
throws ConnectionException,
GetException
ConnectionExceptionGetExceptionpublic double upperDisplayFieldLimit()
throws ConnectionException,
GetException
ConnectionExceptionGetExceptionpublic double lowerDisplayFieldLimit()
throws ConnectionException,
GetException
ConnectionExceptionGetExceptionpublic double upperWarningFieldLimit()
throws ConnectionException,
GetException
ConnectionExceptionGetExceptionpublic double lowerWarningFieldLimit()
throws ConnectionException,
GetException
ConnectionExceptionGetExceptionpublic double upperAlarmFieldLimit()
throws ConnectionException,
GetException
ConnectionExceptionGetExceptionpublic double lowerAlarmFieldLimit()
throws ConnectionException,
GetException
ConnectionExceptionGetExceptionpublic double getCurrent()
throws ConnectionException,
GetException
ConnectionExceptionGetExceptionpublic void setCurrent(double newCurrent)
throws ConnectionException,
PutException
newCurrent - is the new current (A)ConnectionExceptionPutExceptionpublic double upperCurrentLimit()
throws ConnectionException,
GetException
ConnectionExceptionGetExceptionpublic double lowerCurrentLimit()
throws ConnectionException,
GetException
ConnectionExceptionGetExceptionpublic boolean isPermanent()
isPermanent in interface MagnetTypeisPermanent in class Magnet