|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.util.Observable
org.lsst.ccs.framework.Module
org.lsst.ccs.subsystems.fcs.CarouselModule
public class CarouselModule
This is a representation of the hardware of the carousel. It receives commands from the FCSMAinModule and send back an anknowledge. It publishes data on the status bus. In engineering mode it can receive commands from the engineering console. It has a latch, an engine which are connected to real or simulated hardware.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class org.lsst.ccs.framework.Module |
|---|
org.lsst.ccs.framework.Module.ValueUpdate |
| Field Summary | |
|---|---|
protected int |
nbSockets
|
static java.lang.String |
publishedByCarouselOutputName
|
| Fields inherited from class org.lsst.ccs.framework.Module |
|---|
log, name, nObserverThreads, registry, tickMillis |
| Constructor Summary | |
|---|---|
CarouselModule()
|
|
| Method Summary | |
|---|---|
static double |
addAngle(double angle1,
double angle2)
Add 2 angles : an angle is a double which value is between -360 and +360 |
void |
engageClampsContact()
After a rotation, when the carousel is stopped the power contact can be engaged again. |
Motor |
getCarouselMotor()
|
Actuator |
getClampActuatorXminus()
|
Actuator |
getClampActuatorXplus()
|
FilterClampModule |
getClampXminus()
This method returns the clampX- which is at standby position. |
FilterClampModule |
getClampXplus()
This method returns the clampX+ which is at standby position. |
Filter |
getFilterAtStandby()
This methods return the filter which is in the socket at standby position. |
java.lang.String |
getFilterInStandbyName()
|
double |
getFilterPosition(Filter filter)
|
Latch |
getLatch()
|
int |
getNbSockets()
|
double |
getPosition()
The carousel position measures the rotation angle of the carousel within the fixed part of the camera. |
CarouselSocket |
getSocketAtStandby()
This methods returns the socket at standby position or null if there is no socket at standby position. |
int |
getSocketNumber(Filter filter)
|
CarouselSocket[] |
getSockets()
|
double |
getStandbyPositionForFilter(Filter filter)
|
ModuleState |
getState()
|
StatusDataPublishedByCarousel |
getStatusData()
|
java.lang.String |
grabbeFilterAtStandby(Filter filter)
This method has to be executed when a filter has just been moved on the carousel at standby position by the autochanger. |
java.lang.String |
grabbeFilterAtStandby(java.lang.Object filterName)
|
void |
initModule()
|
void |
initPublishedData()
|
boolean |
isAbleToMove()
The carousel can be locked by a break or prevented to move by the autochanger fliprail. |
boolean |
isLocked()
|
boolean |
isOnStandby(Filter filter)
|
boolean |
isReadyToGrabbeAFilterAtStandby()
This method let us know if the carousel is ready to receive a filter at standby position : - the carousel must not rotate - an empty socket is at standby position. |
boolean |
isRotating()
|
java.lang.String |
lock()
Lock the carousel (or engage the break). |
protected java.lang.String |
moveFilterToStandby(Filter filter)
This method rotates the carousel to put the given filter in front of the autochanger (standby position). |
void |
printSockets()
Print for every socket on carousel, the name of the filter it contains. |
void |
processUpdate(java.util.Observable source,
org.lsst.ccs.framework.Module.ValueUpdate v)
What to do when the Modules we observe send there new values : we notify our own observers |
java.lang.String |
releaseClamps()
This is a command that can be sent to the carousel. |
void |
releaseClampsContact()
Before rotating the carousel we have to release the power contact between the moving part and the fixed part. |
void |
removeFilterFromCarousel(Filter filter)
|
java.lang.String |
rotate(double angle)
Rotates carousel for an angle given as a parameter. |
void |
setCarouselMotor(Motor engine)
|
void |
setClampActuatorXminus(Actuator clampActuator)
|
void |
setClampActuatorXplus(Actuator clampActuator)
|
void |
setLatch(Latch latch)
|
void |
setNbSockets(int nbSockets)
|
void |
setSockets(CarouselSocket[] sockets)
|
void |
setState(ModuleState state)
|
java.lang.String |
stop()
Stop the carousel if it is rotating. |
void |
tick()
What has to be done for each tick of the timer. |
java.lang.String |
toString()
|
void |
ungrabbeFilterAtStandby(Filter filter)
|
java.lang.String |
unlock()
Unlock the carousel (or disengage the break) |
java.lang.String |
unlockClamps(Filter filter)
|
| Methods inherited from class org.lsst.ccs.framework.Module |
|---|
getContext, getModule, getName, getNObserverThreads, getObservables, getSubsystem, getTickMillis, init, listens, publishData, publishData, publishData, publishData, sendToReply, sendToStatus, setBeanName, setContext, setName, setNObserverThreads, setObservables, setStateModularSubsystem, setStateModularSubsystem, setTickMillis, shutdownNow, start, update |
| Methods inherited from class java.util.Observable |
|---|
addObserver, clearChanged, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, notifyObservers, setChanged |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
protected int nbSockets
public static java.lang.String publishedByCarouselOutputName
| Constructor Detail |
|---|
public CarouselModule()
| Method Detail |
|---|
public CarouselSocket[] getSockets()
public void setSockets(CarouselSocket[] sockets)
public double getPosition()
Carousel
getPosition in interface Carouselpublic Motor getCarouselMotor()
public void setCarouselMotor(Motor engine)
public Latch getLatch()
public void setLatch(Latch latch)
public ModuleState getState()
public void setState(ModuleState state)
public int getNbSockets()
public void setNbSockets(int nbSockets)
nbSockets - the nbSockets to setpublic Actuator getClampActuatorXminus()
public void setClampActuatorXminus(Actuator clampActuator)
clampActuatorXminus - the clampActuatorXminus to setpublic Actuator getClampActuatorXplus()
public void setClampActuatorXplus(Actuator clampActuator)
clampActuatorXminus - the clampActuatorXminus to setpublic FilterClampModule getClampXminus()
public FilterClampModule getClampXplus()
public void initModule()
initModule in class org.lsst.ccs.framework.Modulepublic void initPublishedData()
public StatusDataPublishedByCarousel getStatusData()
public java.lang.String toString()
toString in class java.lang.Object
public void processUpdate(java.util.Observable source,
org.lsst.ccs.framework.Module.ValueUpdate v)
processUpdate in class org.lsst.ccs.framework.Modulepublic CarouselSocket getSocketAtStandby()
Carousel
getSocketAtStandby in interface Carouselpublic Filter getFilterAtStandby()
public java.lang.String getFilterInStandbyName()
public boolean isReadyToGrabbeAFilterAtStandby()
throws HardwareErrorDetectedException
HardwareErrorDetectedExceptionpublic boolean isRotating()
public boolean isAbleToMove()
Carousel
isAbleToMove in interface Carouselpublic boolean isLocked()
public java.lang.String stop()
Carousel
stop in interface Carouselpublic java.lang.String lock()
Carousel
lock in interface Carouselpublic java.lang.String unlock()
Carousel
unlock in interface Carousel
public java.lang.String rotate(double angle)
throws java.lang.IllegalArgumentException,
org.lsst.ccs.bus.BadCommandException
rotate in interface CarouselangleEntered - : rotation angle
The rotation angle can be positive or negative.
It must be a double and have a value between -360.0 and 360.0
IllegalArgumentException, - BadCommandException
java.lang.IllegalArgumentException - if the angle given as parameter
is not in the ranges of available values.
org.lsst.ccs.bus.BadCommandException - if the carousel is already rotating or is
unable to move.public void tick()
tick in class org.lsst.ccs.framework.Module
public void removeFilterFromCarousel(Filter filter)
throws org.lsst.ccs.bus.BadCommandException,
HardwareErrorDetectedException,
org.lsst.ccs.bus.ErrorInCommandExecutionException
org.lsst.ccs.bus.BadCommandException
HardwareErrorDetectedException
org.lsst.ccs.bus.ErrorInCommandExecutionExceptionpublic double getFilterPosition(Filter filter)
public double getStandbyPositionForFilter(Filter filter)
public int getSocketNumber(Filter filter)
filter -
protected java.lang.String moveFilterToStandby(Filter filter)
throws java.lang.InterruptedException,
org.lsst.ccs.bus.BadCommandException
org.lsst.ccs.bus.BadCommandException
java.lang.InterruptedExceptionpublic void printSockets()
public java.lang.String grabbeFilterAtStandby(java.lang.Object filterName)
throws org.lsst.ccs.bus.BadCommandException,
org.lsst.ccs.bus.ErrorInCommandExecutionException,
HardwareErrorDetectedException
org.lsst.ccs.bus.BadCommandException
org.lsst.ccs.bus.ErrorInCommandExecutionException
HardwareErrorDetectedException
public java.lang.String grabbeFilterAtStandby(Filter filter)
throws org.lsst.ccs.bus.BadCommandException,
org.lsst.ccs.bus.ErrorInCommandExecutionException,
HardwareErrorDetectedException
filter -
org.lsst.ccs.bus.BadCommandException
org.lsst.ccs.bus.ErrorInCommandExecutionException
HardwareErrorDetectedException
public void ungrabbeFilterAtStandby(Filter filter)
throws org.lsst.ccs.bus.BadCommandException,
org.lsst.ccs.bus.ErrorInCommandExecutionException,
HardwareErrorDetectedException
org.lsst.ccs.bus.BadCommandException
org.lsst.ccs.bus.ErrorInCommandExecutionException
HardwareErrorDetectedException
public java.lang.String releaseClamps()
throws org.lsst.ccs.bus.BadCommandException,
org.lsst.ccs.bus.ErrorInCommandExecutionException
Carousel
releaseClamps in interface Carouselorg.lsst.ccs.bus.BadCommandException
org.lsst.ccs.bus.ErrorInCommandExecutionException
public java.lang.String unlockClamps(Filter filter)
throws org.lsst.ccs.bus.BadCommandException,
org.lsst.ccs.bus.ErrorInCommandExecutionException,
HardwareErrorDetectedException
unlockClamps in interface Carouselorg.lsst.ccs.bus.BadCommandException
org.lsst.ccs.bus.ErrorInCommandExecutionException
HardwareErrorDetectedExceptionpublic boolean isOnStandby(Filter filter)
public static double addAngle(double angle1,
double angle2)
angle1 - angle2 -
public void releaseClampsContact()
Carousel
releaseClampsContact in interface Carouselpublic void engageClampsContact()
Carousel
engageClampsContact in interface Carousel
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||