public abstract class MobileItemModule
extends org.lsst.ccs.framework.Module
| Modifier and Type | Field and Description |
|---|---|
protected boolean |
itemMoving |
protected Lock |
lock |
protected Condition |
motionCompleted |
| Constructor and Description |
|---|
MobileItemModule(String moduleName,
int aTickMillis) |
| Modifier and Type | Method and Description |
|---|---|
protected String |
executeAction(FcsEnumerations.MobileItemAction action,
long timeoutForAction)
This executes an action which moves the MobileItem and waits for the end od this action.
|
abstract boolean |
isActionCompleted(FcsEnumerations.MobileItemAction action) |
abstract void |
postAction(FcsEnumerations.MobileItemAction action) |
void |
readSensorsUntilActionIsCompleted(FcsEnumerations.MobileItemAction action,
long beginTime,
long timeout)
Start reading the sensors at a fixed rate (scheduler.scheduleAtFixedRate) until the action is completed or the timeout for this action is past.
|
void |
shutdownNow()
This shutdowns the scheduler.
|
abstract void |
startAction(FcsEnumerations.MobileItemAction action) |
abstract void |
updateStateWithSensorsToCheckIfActionIsCompleted() |
alias, change, checkHardware, dropConfigurationContext, getCheckedValueFromConfiguration, getChildren, getContext, getModule, getName, getNObserverThreads, getObservables, getSubsystem, getTickMillis, init, initModule, listens, newConfigurationContext, notifyChange, notifyChangeWithoutPreliminaryChecks, processUpdate, publishData, publishData, publishData, publishData, publishData, publishData, publishData, register, removeLogPanicState, sendToReply, sendToStatus, setBeanName, setContext, setEnvironment, setHandlerLevel, setLogLevel, setName, setNObserverThreads, setObservables, setStateModularSubsystem, setStateModularSubsystem, setTickMillis, shutdownCommand, start, startTicking, tick, updateaddObserver, clearChanged, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, notifyObservers, setChangedprotected volatile boolean itemMoving
protected final Lock lock
protected final Condition motionCompleted
public MobileItemModule(String moduleName, int aTickMillis)
public abstract boolean isActionCompleted(FcsEnumerations.MobileItemAction action)
public abstract void updateStateWithSensorsToCheckIfActionIsCompleted()
throws Exception
Exceptionpublic abstract void startAction(FcsEnumerations.MobileItemAction action) throws org.lsst.ccs.bus.BadCommandException, org.lsst.ccs.bus.ErrorInCommandExecutionException, HardwareException
org.lsst.ccs.bus.BadCommandExceptionorg.lsst.ccs.bus.ErrorInCommandExecutionExceptionHardwareExceptionpublic abstract void postAction(FcsEnumerations.MobileItemAction action) throws org.lsst.ccs.bus.BadCommandException, org.lsst.ccs.bus.ErrorInCommandExecutionException, HardwareException
org.lsst.ccs.bus.BadCommandExceptionorg.lsst.ccs.bus.ErrorInCommandExecutionExceptionHardwareExceptionprotected String executeAction(FcsEnumerations.MobileItemAction action, long timeoutForAction) throws org.lsst.ccs.bus.BadCommandException, org.lsst.ccs.bus.ErrorInCommandExecutionException, HardwareException
action, - timeoutorg.lsst.ccs.bus.BadCommandExceptionorg.lsst.ccs.bus.ErrorInCommandExecutionExceptionHardwareExceptionpublic void readSensorsUntilActionIsCompleted(FcsEnumerations.MobileItemAction action, long beginTime, long timeout)
action - beginTime - timeout - public void shutdownNow()
shutdownNow in class org.lsst.ccs.framework.ModuleCopyright © 2013 LSST. All Rights Reserved.