public class SftFilterLatch extends MobileItem
| Modifier and Type | Field and Description |
|---|---|
protected DigitalSensor |
filterPresenceSensor |
protected LatchActuator |
latchActuator |
protected DigitalSensor |
lockSensor |
protected DigitalSensor |
unlockSensor |
protected boolean |
updatingState
This is used when we update the latch state with the values returned by
the sensors.
|
currentAction, FCSLOG, hasToWaitForEndOfAction, lock, name, readSensorsHandle, s, scheduleralertSeparater| Constructor and Description |
|---|
SftFilterLatch(CompactIO filterSensorsDIO,
DigitalSensor lockSensor,
DigitalSensor unlockSensor,
DigitalSensor filterPresenceSensor,
LatchActuator latchActuator)
Build a new SftFilterLatchModule
|
| Modifier and Type | Method and Description |
|---|---|
void |
abortAction(FcsEnumerations.MobileItemAction action,
long delay)
aborts action actually running.
|
String |
close()
Close the latch : turn on the actuator, read the sensors and wait until
the latch is closed.
|
StatusDataPublishedByAutochangerLatch |
createStatusDataPublishedByLatch()
This methods is used in the single-filter-test.
|
DigitalSensor |
getFilterPresenceSensor() |
LatchActuator |
getLatchActuator() |
DigitalSensor |
getLockSensor() |
FcsEnumerations.LockStatus |
getLockStatus() |
FcsEnumerations.FilterPresenceStatus |
getPresenceStatus()
Return the filter presence status.
|
long |
getTimeoutForClosing() |
long |
getTimeoutForOpening() |
DigitalSensor |
getUnlockSensor() |
boolean |
isActionCompleted(FcsEnumerations.MobileItemAction action) |
boolean |
isControllerInFault() |
boolean |
isLocked() |
boolean |
myDevicesReady()
Returns true if hardware is connected and ready.
|
String |
open()
Open the latch if the carousel is holding the filter.
|
void |
postAction(FcsEnumerations.MobileItemAction action) |
void |
publishData()
Publish Data on status bus for trending data base and GUIs.
|
void |
quickStopAction(FcsEnumerations.MobileItemAction action,
long delay) |
void |
setLockStatus(FcsEnumerations.LockStatus lockStatus) |
void |
startAction(FcsEnumerations.MobileItemAction action)
starts the action given as argument.
|
String |
toString() |
void |
updateState(int value)
Update Latch State.
|
void |
updateStateWithSensors()
Reads latch sensors and updates latch state.
|
void |
updateStateWithSensorsToCheckIfActionIsCompleted()
reads sensors or any device and updates state from sensors
it can be also reading a position or a current on a motor controller.
|
abort, abort, cancelReadingSensors, checkReadyForAction, checkStopped, executeAction, getAlertService, getHaltRequired, getName, getSubsystem, isMoving, quickstop, readSensorsUntilActionIsCompleted, shutdown, signal, stop, stopActionNow, waitForEndOfActionclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitcheckHardware, checkStartedclearAlarm, raiseAlarm, raiseAlarm, raiseAlarm, raiseAlarm, raiseWarning, raiseWarningprotected final LatchActuator latchActuator
protected DigitalSensor filterPresenceSensor
protected DigitalSensor lockSensor
protected DigitalSensor unlockSensor
protected volatile boolean updatingState
public SftFilterLatch(CompactIO filterSensorsDIO, DigitalSensor lockSensor, DigitalSensor unlockSensor, DigitalSensor filterPresenceSensor, LatchActuator latchActuator)
filterSensorsDIO - lockSensor - unlockSensor - filterPresenceSensor - latchActuator - public long getTimeoutForClosing()
public long getTimeoutForOpening()
public DigitalSensor getFilterPresenceSensor()
public LatchActuator getLatchActuator()
public DigitalSensor getLockSensor()
public DigitalSensor getUnlockSensor()
public boolean isControllerInFault()
@Command(type=QUERY,
level=1,
description="Returns true if hardware is connected and ready.")
public boolean myDevicesReady()
myDevicesReady in class MobileItempublic boolean isActionCompleted(FcsEnumerations.MobileItemAction action)
isActionCompleted in class MobileItempublic void updateStateWithSensorsToCheckIfActionIsCompleted()
MobileItemupdateStateWithSensorsToCheckIfActionIsCompleted in class MobileItem@Command(type=QUERY,
level=1,
description="Reads latch sensors and updates latch state")
public void updateStateWithSensors()
FcsHardwareExceptionpublic void startAction(FcsEnumerations.MobileItemAction action) throws FcsHardwareException
MobileItemstartAction in class MobileItemFcsHardwareExceptionpublic void abortAction(FcsEnumerations.MobileItemAction action, long delay)
MobileItemabortAction in class MobileItempublic void postAction(FcsEnumerations.MobileItemAction action)
postAction in class MobileItempublic FcsEnumerations.LockStatus getLockStatus()
public void setLockStatus(FcsEnumerations.LockStatus lockStatus)
public FcsEnumerations.FilterPresenceStatus getPresenceStatus()
@Command(type=ACTION,
level=3,
description="Open latch")
public String open()
RejectedCommandExceptionFcsHardwareException@Command(type=ACTION,
level=3,
description="Close latch")
public String close()
FcsHardwareException@Command(type=QUERY,
level=1,
description="Return true if the latch is closed")
public boolean isLocked()
public void updateState(int value)
value - public StatusDataPublishedByAutochangerLatch createStatusDataPublishedByLatch()
public void publishData()
publishData in class MobileItempublic void quickStopAction(FcsEnumerations.MobileItemAction action, long delay)
quickStopAction in class MobileItemCopyright © 2018 LSST. All rights reserved.