public interface EPOSController extends PieceOfHardware, org.lsst.ccs.framework.HasLifecycle, org.lsst.ccs.framework.ClearAlertHandler
alertSeparator| Modifier and Type | Method and Description |
|---|---|
default org.lsst.ccs.framework.ClearAlertHandler.ClearAlertCode |
canClearAlert(org.lsst.ccs.bus.data.Alert alert) |
void |
changeMode(EPOSEnumerations.EposMode newMode)
This methods changes the mode to the new mode given as an argument.
|
default void |
changeProfileVelocity(int newVelocity)
change ProfileVelocity to a new value.
|
default void |
checkEnabled()
Check if controller is enable otherwise, throw an Exception.
|
void |
checkFault()
Check if the controller is in fault.
|
void |
checkParameters(EPOSEnumerations.EposMode aMode)
Check parameters for a given EPOS mode : compare the values stored in the
Configuration System and the values stored in controller CPU.
|
default void |
checkTargetReached(long timeout)
check if target is reached in HOMING or PROFILE_POSITION commands and throws
an Exception if not.
|
static long |
convertEPOSValue(EPOSEnumerations.Parameter param,
long value,
String myName)
values transmitted by EPOSController can be : UNSIGNED32, UNSIGNED16,
UNSIGNED8 for UNSIGNED parameter INTEGER32, INTEGER16, INTEGER8 for SIGNED
parameter This method convert a value sent by device to the value to be used
in fcs.
|
default StatusDataPublishedByEPOSController |
createStatusDataPublishedByEPOSController()
Creates an object to be published on the STATUS bus by an EPOSController.
|
default void |
defineAbsolutePosition(int position)
Defines the actual position as the absolute position which value is given as
an argument.
|
default void |
definePositionFromNegativeLimitSwitch() |
default void |
disableOperation()
cf doc EPOS2_Firmware_Specification § 3.2 Device Control lower byte of
control word: 0xxx 0111
|
default void |
disableVoltage()
cf doc EPOS2_Firmware_Specification § 3.2 Device Control lower byte of
control word: 0xxx xx0x
|
String |
displayErrorHistory()
Return a printed list of errors that occured on this controller.
|
default void |
enable()
This methods enables the controller : i.e.
|
default void |
enableAndWriteAbsolutePosition(int pos)
Enable controller and go to absolute position.
|
default void |
enableAndWriteCurrent(int aValue)
Enable, set mode CURRENT and write current.
|
default void |
enableAndWriteRelativePosition(int pos)
Enable controller and go to relative position.
|
int |
getCurrent() |
int[] |
getErrorHistory() |
String |
getErrorRegister() |
EPOSEnumerations.EposMode |
getMode()
Return the EPOS mode stored in field mode.
|
int |
getPosition() |
int |
getVelocity() |
default boolean |
isEnabled()
Returns true if the controller is disabled.
|
boolean |
isEnabledToPublish()
For GUI.
|
boolean |
isInError()
Return true if controller is in fault.
|
default boolean |
isInMode(EPOSEnumerations.EposMode aMode)
return true if this controller is in the mode given as argument.
|
boolean |
isParametersOK()
This methods returns true if the values of parameters stored in CPU are the
same than those stored in the configuration system.
|
default boolean |
isTargetReached()
In HOMING mode and PROFILE_POSITION mode this indicates that the position is
reached.
|
default String |
printStatusWordInBinary()
print status word bit by bit for end user and tests
|
default void |
quickStop()
Send a quickStop command to the controller.
|
short |
readControlWord() |
int |
readCurrent()
Read actual current on the controller CPU.
|
int |
readCurrentAverageValue()
Read Average current on controller CPU.
|
int |
readFollowingError()
read Following Error on controller CPU.
|
EPOSEnumerations.EposMode |
readMode()
read the EPOS mode on the controller CPU.
|
int |
readNumberOfErrors()
Return the number of errors that occured on this controller.
|
long |
readParameter(EPOSEnumerations.Parameter parameter)
Reads in the EPOS CPU the value of the Parameter.
|
default long |
readParameter(String parameterName)
Reads in the EPOS CPU the value of the Parameter which parameter name is
given as argument.
|
default String |
readParameters()
Read the parameters for the actual mode.
|
default String |
readParameters(EPOSEnumerations.EposMode aMode)
Read all the value of parameters for a given EPOS mode and return a printed
list of this values.
|
default String |
readParameters(String modeInString)
This methods reads in the CPU of the EPOS the values of the parameters for a
given mode.
|
default int |
readPosition()
Reads in the CPU the value of the parameter PositionActualValue and returns
it in a decimal format.
|
default int |
readPositionSensorType()
Read parameter PositionSensorType in CPU of controller and return read value.
|
default long |
readProfileVelocity()
In PROFILE_POSITION returns the value of the parameter ProfileVelocity.
|
default int |
readSSIPosition()
Read the position returned by the absolute encoder (single serial data).
|
int |
readStatusWord()
Read StatusWord on controller CPU.
|
int |
readVelocity()
read velocity on the controller CPU.
|
void |
setEnabledToPublish(boolean enabledToPublish) |
default void |
shutdownController()
shutdowns controller cf doc EPOS2_Firmware_Specification § 3.2 Device Control
lower byte of control word: 0xxx x110
|
default void |
stopAction()
Stop action and shutdownController(shutdown) controller.
|
default void |
stopPosition()
Stop motion when in mode PROFILE_POSITION.
|
default void |
stopVelocity()
Stop motion when in mode PROFILE_VELOCITY.
|
default void |
switchOn()
switch controller ON cf doc EPOS2_Firmware_Specification § 3.2 Device Control
lower byte of control word: 0xxx x111
|
default void |
switchOnEnableOperation()
Switch on and enable controller.
|
void |
writeControlWord(int w)
Write controlWord to the controller.
|
void |
writeCurrent(int aValue)
In current mode this methods send a current to the motor.
|
void |
writeParameter(EPOSEnumerations.Parameter parameter,
int val)
Write on the CPU of the controller a value given in hexadecimal format for a
parameter.
|
default void |
writeParameters()
Write in the CPU of the EPOS device the values of the parameters set for the
mode in configuration system.
|
void |
writeParameters(EPOSEnumerations.EposMode mode)
This methods writes in the CPU of the EPOS devis the values of the parameters
set for the mode.
|
default void |
writeParameters(Map<String,Integer> paramMap)
Write to the CPU of the EPOS a map of parameters.
|
void |
writeTargetPosition(int aValue)
In PROFILE_POSITION mode this methods set the target position.
|
void |
writeTargetVelocity(int velocity)
set the target velocity.
|
checkBooted, checkId, checkInitialized, createStatusDataPublishedByHardware, doInitializePDOs, getName, getNodeID, getSerialNB, initializeAndCheckHardware, initializePDOs, isBooted, isInitialized, printState, publishData, raiseAlarmIfMissing, setBooted, updateFromPDOonEmergencyMessage, onFault, onFaultResetclearAlarm, getAlertSeparator, getAlertService, getSubsystem, raiseAlarm, raiseAlarm, raiseAlarm, raiseAlarm, raiseWarning, raiseWarningboolean isEnabledToPublish()
void setEnabledToPublish(boolean enabledToPublish)
int readStatusWord()
short readControlWord()
void writeControlWord(int w)
w - FcsHardwareException@Command(type=QUERY,
level=1,
description="print status word in binary.")
default String printStatusWordInBinary()
@Command(type=ACTION,
level=1,
description="Shutdown the controller.")
default void shutdownController()
@Command(type=ACTION,
level=1,
description="Switch ON the controller.")
default void switchOn()
@Command(type=ACTION,
level=1,
description="Disable voltage. This command does not activate holding brake. cf doc EPOS2_Firmware_Specification \u00a7 3.2 Device Control")
default void disableVoltage()
@Command(type=ACTION,
level=1,
description="Disable operation. This command activates holding brake. cf doc EPOS2_Firmware_Specification \u00a7 3.2 Device Control")
default void disableOperation()
@Command(type=ACTION,
level=1,
description="Switch on and enable controller.")
default void switchOnEnableOperation()
FcsHardwareException@Command(type=ACTION,
level=1,
description="Stop action and disable(shutdown) controller.")
default void stopAction()
@Command(type=ACTION,
level=1,
description="QuickStop.")
default void quickStop()
FcsHardwareException@Command(type=ACTION,
level=1,
description="This methods enables the controller : i.e. this makes it able to receive commands.")
default void enable()
SDORequestException@Command(type=ACTION,
level=1,
description="Check if controller is enabled otherwise, throw an Exception.")
default void checkEnabled()
@Command(type=QUERY,
level=1,
description="Returns true if the controller is enabled.")
default boolean isEnabled()
void changeMode(EPOSEnumerations.EposMode newMode)
newMode - SDORequestExceptionEPOSEnumerations.EposMode readMode()
FcsHardwareExceptionEPOSEnumerations.EposMode getMode()
@Command(type=QUERY,
description="return true if this controller is in the mode given as argument.")
default boolean isInMode(EPOSEnumerations.EposMode aMode)
aMode - int readCurrent()
SDORequestExceptionFcsHardwareExceptionint readCurrentAverageValue()
int readVelocity()
int readFollowingError()
@Command(type=ACTION,
level=1,
description="In current mode this methods send a current to the motor.")
void writeCurrent(int aValue)
throws EPOSConfigurationException
aValue - UNIT=mA / FORMAT=decimal the value of the current to be sent.EPOSConfigurationExceptionSDORequestException@Command(type=ACTION,
level=3,
description="Enables controller and sets the current value in the EPOS CPU.")
default void enableAndWriteCurrent(int aValue)
aValue - @Command(type=ACTION,
level=3,
description="Define the actual position as position given as argument.")
default void defineAbsolutePosition(int position)
position - SDORequestExceptionRejectedCommandExceptiondefault void definePositionFromNegativeLimitSwitch()
@Command(type=QUERY,
level=1,
alias="readPositionActualValue",
description="In PROFILE_POSITION Mode this methods returns the actual position.")
default int readPosition()
SDORequestExceptionint getPosition()
int getCurrent()
int getVelocity()
@Command(type=QUERY,
level=1,
description="Read the position returned by the absolute encoder (single serial data).")
default int readSSIPosition()
SDORequestException@Command(type=QUERY,
level=1,
description="In PROFILE_POSITION returns the value of the parameter ProfileVelocity.")
default long readProfileVelocity()
SDORequestException@Command(type=QUERY,
level=1,
description="Read PositionSensorType.")
default int readPositionSensorType()
@Command(type=ACTION,
level=1,
description="In PROFILE_POSITION mode this methods set the target position.")
void writeTargetPosition(int aValue)
aValue - UNIT=mA / FORMAT=decimal the value of the current to be sent.SDORequestException@Command(type=ACTION,
level=1,
description="In PROFILE_VELOCITY mode this methods set the target velocity.")
void writeTargetVelocity(int velocity)
velocity - default void changeProfileVelocity(int newVelocity)
newVelocity - boolean isParametersOK()
long readParameter(EPOSEnumerations.Parameter parameter)
parameter - void writeParameter(EPOSEnumerations.Parameter parameter, int val)
parameter - val - the value.FcsHardwareExceptionvoid checkParameters(EPOSEnumerations.EposMode aMode)
aMode - FcsHardwareExceptionvoid writeParameters(EPOSEnumerations.EposMode mode)
mode - SDORequestException@Command(type=ACTION,
level=3,
description="Write in the CPU of the EPOS device the values of the parameters set for the mode.")
default void writeParameters()
@Command(type=QUERY,
level=1,
description="Reads in the EPOS CPU the decimal value of the Parameter which parameter name is given as argument.")
default long readParameter(String parameterName)
parameterName - name of the parameter to readSDORequestException@Command(type=QUERY,
level=1,
description="Read the parameters for the actual mode.")
default String readParameters()
@Command(type=QUERY,
level=1,
description="This methods reads in the CPU of the EPOS the values of the parameters for a given mode.")
default String readParameters(String modeInString)
modeInString - SDORequestExceptiondefault String readParameters(EPOSEnumerations.EposMode aMode)
aMode - FcsHardwareExceptiondefault void writeParameters(Map<String,Integer> paramMap)
paramMap - SDORequestExceptionstatic long convertEPOSValue(EPOSEnumerations.Parameter param, long value, String myName)
param - value - myName - boolean isInError()
String getErrorRegister()
int[] getErrorHistory()
int readNumberOfErrors()
SDORequestExceptionFcsHardwareExceptionString displayErrorHistory()
SDORequestExceptionFcsHardwareExceptionvoid checkFault()
@Command(type=QUERY,
level=1,
description="In HOMING mode and PROFILE_POSITION mode this indicates that the position is reached.")
default boolean isTargetReached()
SDORequestExceptiondefault void checkTargetReached(long timeout)
timeout - @Command(type=ACTION,
level=3,
description="Enable controller and go to absolute position. Doesn\'t check condition. DANGER !!!! ")
default void enableAndWriteAbsolutePosition(int pos)
pos - @Command(type=ACTION,
level=3,
description="Enable controller and go to relative position. Doesn\'t check condition. DANGER !!!! ")
default void enableAndWriteRelativePosition(int pos)
pos - @Command(type=ACTION,
level=1,
description="Stop motion when in mode PROFILE_POSITION.")
default void stopPosition()
@Command(type=ACTION,
level=1,
description="Stop motion when in mode PROFILE_VELOCITY.")
default void stopVelocity()
default org.lsst.ccs.framework.ClearAlertHandler.ClearAlertCode canClearAlert(org.lsst.ccs.bus.data.Alert alert)
canClearAlert in interface org.lsst.ccs.framework.ClearAlertHandlerdefault StatusDataPublishedByEPOSController createStatusDataPublishedByEPOSController()
Copyright © 2019 LSST. All rights reserved.