public class REBDevice
extends org.lsst.ccs.monitor.Device
implements org.lsst.ccs.framework.ClearAlertHandler, org.lsst.ccs.config.ConfigurationBulkChangeHandler
| Modifier and Type | Class and Description |
|---|---|
static class |
REBDevice.AdcData |
| Modifier and Type | Field and Description |
|---|---|
protected CcdType |
ccdType |
static int |
CHAN_HTR_POWER |
static int |
CHAN_HTR_VOLTS |
static int |
CHAN_RTD_INT_TEMP |
static int |
CHAN_RTD_INT_VOLT |
static int |
CHAN_TOTAL_POWER |
protected int |
configCcdMask |
protected int |
hdwTypeI |
protected int |
hwVersion |
static int |
NUM_HTR_CHANS |
static int |
NUM_RTD_CHANS |
static String |
RAFTS |
static String |
RAFTS_LIMITS |
protected int |
realCcdMask |
static int |
TYPE_ASP_TEMP |
static int |
TYPE_BD_POWER |
static int |
TYPE_BD_TEMP |
static int |
TYPE_BIAS_VOLT |
static int |
TYPE_CCD_CURR |
static int |
TYPE_CR_VOLT |
static int |
TYPE_HEATER |
static int |
TYPE_HV_SWITCH |
static int |
TYPE_RTD |
| Constructor and Description |
|---|
REBDevice() |
| Modifier and Type | Method and Description |
|---|---|
void |
build()
Early initialization (build phase).
|
org.lsst.ccs.framework.ClearAlertHandler.ClearAlertCode |
canClearAlert(org.lsst.ccs.bus.data.Alert alert)
Clears an alert.
|
int |
checkAspics()
Checks loaded ASPIC configuration data.
|
protected int[] |
checkChannel(String name,
int hwChan,
String type,
String subtype)
Checks a channel's parameters for validity.
|
void |
clearBiasDacs()
Clears bias DAC values.
|
void |
clearDacs()
Clears DAC values.
|
protected void |
close()
Closes the connection.
|
int |
getCcdMask()
Gets the mask of CCDs being used.
|
CcdType |
getCcdType()
Gets the CCD type.
|
int |
getHdwType()
Gets the hardware type.
|
int |
getHwVersion()
Gets the hardware version.
|
int |
getId()
Gets the REB ID.
|
String |
getIfcName()
Gets the network interface name.
|
ImageData |
getImage(int offset,
int count)
Gets a portion of the current image.
|
ImageData |
getImage(int ccd,
int offset,
int count)
Gets a portion of the current image.
|
org.lsst.ccs.drivers.reb.ImageMetadata |
getImageMetadata()
Gets the DAQ metadata for the current image.
|
ImageProc |
getImageProc()
Gets the associated image processor.
|
int |
getRaftNumber()
Gets the raft number.
|
REB |
getREBConfig()
Gets the REB configuration data.
|
int |
getRebNumber()
Gets the REB number.
|
StatusData |
getRebStatus()
Gets the REB status block.
|
int |
getRebType()
Gets the REB type.
|
RegisterData |
getRegister(int address,
int count)
Gets the contents of REB registers.
|
SequencerProc |
getSequencer()
Gets the associated sequencer.
|
long |
getSerialNumber()
Gets the serial number.
|
long |
getTime()
Gets the time base as Unix time.
|
long |
getTime(String rSet) |
protected void |
initChannel(String name,
int id,
int hwChan,
int type,
int subtype)
Initializes a channel (in this case only checks HW channel number).
|
protected void |
initDevice()
Performs basic initialization.
|
protected void |
initialize()
Performs full initialization.
|
boolean |
isBackBiasOn()
Gets the back bias on state.
|
boolean |
isSerialNumValid()
Gets whether the serial number is valid.
|
int |
loadAspics(boolean all)
Loads configuration data to the ASPICs.
|
int |
loadBiasDacs(boolean all)
Loads configured bias DAC values.
|
int |
loadDacs(boolean all)
Loads configured DAC values.
|
void |
postStart() |
void |
powerCCDs(boolean on)
Performs CCD power on/off sequences.
|
void |
powerCCDsOff()
Performs CCD power off sequence.
|
void |
powerCCDsOn()
Performs CCD power on sequence.
|
protected double |
readChannel(int hwChan,
int type)
Reads a channel.
|
protected void |
readChannelGroup()
Reads grouped channels.
|
double |
readChannelNow(int hwChan,
int type)
Reads a channel immediately.
|
double[] |
readPowerAdcs()
Reads the board power ADCs.
|
int |
readSeqIdleState()
Reads the sequencer idle state lines.
|
int |
resetAspics()
Resets the ASPICs.
|
void |
resetFrontEnd()
Resets the front end.
|
void |
setAllAspicGain(int gain)
Transversal setting of all Gains for the Aspics of this reb.
|
void |
setAllAspicRc(int rc)
Transversal setting of all Rcs for the Aspics of this reb.
|
void |
setAllAspicTM(boolean tm)
Transversal setting of all TM for the Aspics of this reb.
|
void |
setBackBias(boolean value)
Turns back bias on or off.
|
void |
setCcdType(CcdType ccdType)
Sets the CCD type.
|
void |
setClientFactory(org.lsst.ccs.drivers.reb.ClientFactory factory)
Sets the client factory.
|
void |
setFitsConditions(String filter,
double temperature,
double wavelength)
Sets the FITS file test conditions.
|
void |
setHeater(int heater,
double volts)
Sets a heater voltage.
|
void |
setHeaterPower(int heater,
double power)
Sets heater power.
|
protected void |
setOnline(boolean online) |
void |
setREBConfig(REB reb)
Sets the REB configuration data.
|
void |
setRegister(int address,
int[] values)
Sets the contents of REB registers.
|
void |
setTime()
Sets the time base to the current system time.
|
void |
simulateDisconnection()
Simulate a disconnect
|
void |
testCCDShorts()
Performs CCD shorts test.
|
void |
validateBulkChange(Map<String,Object> params)
Validates configuration parameter change.
|
void |
writeSeqIdleState(int value)
Writes the sequencer idle state lines.
|
addChannel, addLine, checkHardware, checkHwLine, checkLine, checkOnline, checkTimeout, configure, disable, dropChannel, enable, getFullName, getName, getOutputLines, init, initChannel, initSensors, isHwLineSet, isLineSet, isOnline, isTimeout, readChannel, readSensors, setHwLine, setLine, setLineWarm, setOutputLines, testOnlineclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitsetParameterBulkpublic static final String RAFTS
public static final String RAFTS_LIMITS
public static final int TYPE_BD_TEMP
public static final int TYPE_BD_POWER
public static final int TYPE_RTD
public static final int TYPE_ASP_TEMP
public static final int TYPE_BIAS_VOLT
public static final int TYPE_CCD_CURR
public static final int TYPE_CR_VOLT
public static final int TYPE_HEATER
public static final int TYPE_HV_SWITCH
public static final int CHAN_TOTAL_POWER
public static final int CHAN_HTR_VOLTS
public static final int CHAN_HTR_POWER
public static final int NUM_HTR_CHANS
public static final int CHAN_RTD_INT_TEMP
public static final int CHAN_RTD_INT_VOLT
public static final int NUM_RTD_CHANS
protected CcdType ccdType
protected int hdwTypeI
protected int configCcdMask
protected int realCcdMask
protected int hwVersion
public void build()
build in interface org.lsst.ccs.framework.HasLifecyclepublic void validateBulkChange(Map<String,Object> params)
validateBulkChange in interface org.lsst.ccs.config.ConfigurationBulkChangeHandlerparams - The map of configuration parameter values@Command(type=QUERY,
description="Get the REB ID")
public int getId()
@Command(type=QUERY,
description="Get the network interface name")
public String getIfcName()
@Command(type=QUERY,
description="Get the mask of CCDs being used")
public int getCcdMask()
public void setCcdType(CcdType ccdType)
ccdType - The CCD type@Command(type=QUERY,
description="Get the type of CCDs being used")
public CcdType getCcdType()
public void setClientFactory(org.lsst.ccs.drivers.reb.ClientFactory factory)
factory - The client factory@Command(type=QUERY,
description="Gets the REB type")
public int getRebType()
@Command(type=QUERY,
description="Gets the REB number")
public int getRebNumber()
@Command(type=QUERY,
description="Gets the raft number")
public int getRaftNumber()
@Command(type=QUERY,
description="Gets the hardware type")
public int getHdwType()
@Command(type=QUERY,
description="Get the hardware version")
public int getHwVersion()
@Command(type=QUERY,
description="Get the serial number")
public long getSerialNumber()
public boolean isSerialNumValid()
public org.lsst.ccs.framework.ClearAlertHandler.ClearAlertCode canClearAlert(org.lsst.ccs.bus.data.Alert alert)
canClearAlert in interface org.lsst.ccs.framework.ClearAlertHandleralert - The alertprotected void initDevice()
initDevice in class org.lsst.ccs.monitor.Deviceprotected void initialize()
initialize in class org.lsst.ccs.monitor.Devicepublic void postStart()
postStart in interface org.lsst.ccs.framework.HasLifecycleprotected void close()
close in class org.lsst.ccs.monitor.Deviceprotected int[] checkChannel(String name, int hwChan, String type, String subtype) throws Exception
checkChannel in class org.lsst.ccs.monitor.Devicename - The channel namehwChan - The hardware channeltype - The channel type stringsubtype - The channel subtype stringException - If parameters are invalidprotected void initChannel(String name, int id, int hwChan, int type, int subtype)
initChannel in class org.lsst.ccs.monitor.Devicename - The channel nameid - The channel IDhwChan - The hardware channeltype - The channel typesubtype - The channel subtypeprotected void readChannelGroup()
readChannelGroup in class org.lsst.ccs.monitor.Deviceprotected double readChannel(int hwChan,
int type)
readChannel in class org.lsst.ccs.monitor.DevicehwChan - The hardware channel numbertype - The encoded channel typepublic double readChannelNow(int hwChan,
int type)
readChannelNow in class org.lsst.ccs.monitor.DevicehwChan - The hardware channel numbertype - The encoded channel typepublic double[] readPowerAdcs()
throws RaftException
RaftExceptionpublic int readSeqIdleState()
throws RaftException
RaftExceptionpublic void writeSeqIdleState(int value)
throws RaftException
value - The lines valueRaftException@Command(type=ACTION,
description="Sets the REB configuration data")
public void setREBConfig(@Argument(name="reb",description="REB configuration data")
REB reb)
throws RaftException
reb - The REB configuration (object)RaftException@Command(type=QUERY,
description="Gets the REB configuration data")
public REB getREBConfig()
@Command(type=CONFIGURATION,
description="Set TM for all ASPICs on this REB")
public void setAllAspicTM(boolean tm)
tm - true for TM, false for normal@Command(type=CONFIGURATION,
description="Set gain for all ASPICs on this REB")
public void setAllAspicGain(int gain)
gain - the new gain value@Command(type=CONFIGURATION,
description="Set RC for all ASPICs on this REB")
public void setAllAspicRc(int rc)
rc - the new rc value@Command(type=ACTION,
description="Perform CCD power on/off sequence")
public void powerCCDs(@Argument(description="Whether to power on")
boolean on)
throws RaftException
on - Whether to power on (true) or off (false)RaftException@Command(type=ACTION,
description="Perform CCD power on sequence")
public void powerCCDsOn()
throws RaftException
RaftException@Command(type=ACTION,
description="Perform CCD power off sequence")
public void powerCCDsOff()
throws RaftException
RaftException@Command(type=ACTION,
description="Perform CCD shorts test")
public void testCCDShorts()
throws RaftException
RaftException@Command(type=ACTION,
description="Loads configured DAC values")
public int loadDacs(@Argument(description="Whether all DACs are loaded, or only changed ones")
boolean all)
throws RaftException
all - If true, all data are loaded; otherwise only changesRaftException@Command(type=ACTION,
description="Clear DAC values")
public void clearDacs()
throws RaftException
RaftException@Command(type=ACTION,
description="Loads configured bias DAC values")
public int loadBiasDacs(@Argument(description="Whether all DACs are loaded, or only changed ones")
boolean all)
throws RaftException
all - If true, all data are loaded; otherwise only changesRaftException@Command(type=ACTION,
description="Clear bias DAC values")
public void clearBiasDacs()
throws RaftException
RaftException@Command(type=ACTION,
description="Load configuration data to the ASPICs")
public int loadAspics(boolean all)
throws Exception
all - If true, all data are loaded; otherwise only changesException@Command(type=ACTION,
description="Reset the ASPICs")
public int resetAspics()
throws Exception
Exception@Command(type=ACTION,
description="Check loaded ASPIC configuration")
public int checkAspics()
throws Exception
Exception@Command(type=QUERY,
description="Get the back bias on state")
public boolean isBackBiasOn()
throws RaftException
RaftException@Command(type=ACTION,
description="Turn back bias on or off")
public void setBackBias(@Argument(description="The on state")
boolean value)
throws RaftException
value - The back bias on state to set (true or false)RaftException@Command(type=ACTION,
description="Set heater voltage")
public void setHeater(@Argument(description="Heater number")
int heater,
@Argument(description="The voltage")
double volts)
throws RaftException
heater - The heater number: 0 or 1volts - The voltage to setRaftException@Command(type=ACTION,
description="Set heater power")
public void setHeaterPower(@Argument(description="Heater number")
int heater,
@Argument(description="The power value")
double power)
throws RaftException
heater - The heater number: 0 or 1power - The power value to setRaftException@Command(type=ACTION,
description="Sets the time base to the current system time")
public void setTime()
throws RaftException
RaftException@Command(type=QUERY,
description="Gets the time base as Unix time")
public long getTime()
throws RaftException
RaftException@Command(type=QUERY,
description="Gets a trigger time as Unix time")
public long getTime(@Argument(name="regset",description="Register set name")
String rSet)
throws RaftException
RaftException@Command(type=ACTION,
description="Sets the FITS file test conditions")
public void setFitsConditions(@Argument(description="Filter name")
String filter,
@Argument(description="The temperature")
double temperature,
@Argument(description="The wavelength")
double wavelength)
filter - The filter nametemperature - The temperature set pointwavelength - The monochromator wavelength@Command(type=QUERY,
description="Get the DAQ metadata for the current image")
public org.lsst.ccs.drivers.reb.ImageMetadata getImageMetadata()
throws RaftException
RaftException@Command(type=QUERY,
description="Gets a portion of the current image")
public ImageData getImage(@Argument(description="Offset to the pixel data")
int offset,
@Argument(description="Number of pixels")
int count)
throws RaftException
offset - The offset (in pixels) to the first pixel data to obtain.count - The number of data pixels to obtain. If zero, all
the data, starting at offset, is obtained.RaftException@Command(type=QUERY,
description="Gets a portion of the current image")
public ImageData getImage(@Argument(description="CCD number")
int ccd,
@Argument(description="Offset to the pixel data")
int offset,
@Argument(description="Number of pixels")
int count)
throws RaftException
ccd - The CCD numberoffset - The offset (in pixels) to the first pixel data to obtain.count - The number of data pixels to obtain. If zero, all
the data, starting at offset, is obtained.RaftException@Command(type=ACTION,
description="Resets the front end")
public void resetFrontEnd()
throws RaftException
RaftException@Command(type=QUERY,
description="Gets the contents of REB registers")
public RegisterData getRegister(@Argument(description="Address of the first register")
int address,
@Argument(description="Number of registers to read")
int count)
throws RaftException
address - The address of the first register to readcount - The number of registers to readRaftException@Command(type=ACTION,
description="Sets the contents of REB registers")
public void setRegister(@Argument(description="Address of the first register")
int address,
@Argument(description="Values to write")
int[] values)
throws RaftException
address - The address of the first register to writevalues - The array of values to write to consecutive registersRaftException@Command(type=QUERY,
description="Gets the REB status block")
public StatusData getRebStatus()
throws RaftException
RaftExceptionpublic ImageProc getImageProc()
public SequencerProc getSequencer()
@Command(simulation=true) public void simulateDisconnection()
protected void setOnline(boolean online)
setOnline in class org.lsst.ccs.monitor.DeviceCopyright © 2019 LSST. All rights reserved.