MirrorCoverLocksDevice

class lsst.ts.MTMount.mock.MirrorCoverLocksDevice(controller)

Bases: lsst.ts.MTMount.mock.point_to_point_device.PointToPointDevice

Mirror cover locks.

Supports all commands except MOVE and MOVE_VELOCITY.

Unlike the real system, the drive argument must always be -1 (meaning all drives). That suffices for the CSC.

Parameters:
controller : MockController

Mock controller.

Attributes Summary

all_command_names
power_on Return true if the device is powered on.

Methods Summary

add_methods() Add do_methods to the command dict
assert_drive_all(command) Assert that the drive argument is -1 (all drives).
assert_on() Raise RuntimeError if device off or in an alarm state.
close() Cancel any background tasks and clean up resources.
do_close(command)
do_move(command)
do_move_all(command)
do_move_velocity(command)
do_open(command)
do_power(command)
do_reset_alarm(command)
do_stop(command) Stop the actuator.
monitor_move_command(command) Return a task that is set done when the move is done.
move(position, command) Move to the specified position.
supersede_move_command() Report the current move command (if any) as superseded.

Attributes Documentation

all_command_names = {'ENCODER_INTERFACE_BOX_RESET_ERROR', 'CAMERA_CABLE_WRAP_DRIVE_ENABLE', 'LOCKING_PINS_POWER', 'BOTH_AXES_STOP', 'EXIT', 'MIRROR_COVER_LOCKS_MOVE_VELOCITY', 'STATE_INFO', 'MAIN_POWER_SUPPLY_POWER', 'TOP_END_CHILLER_POWER', 'OIL_SUPPLY_SYSTEM_RESET_ALARM', 'ENCODER_INTERFACE_BOX_REFERENCE', 'ENCODER_INTERFACE_BOX_EXIT', 'ENCODER_INTERFACE_BOX_RESET', 'AZIMUTH_THERMAL_POWER', 'ELEVATION_AXIS_DRIVE_RESET', 'ENABLE_CAMERA_WRAP', 'AZIMUTH_AXIS_MOVE_VELOCITY', 'DEPLOYABLE_PLATFORM_STOP', 'MIRROR_COVER_LOCKS_MOVE_ALL', 'START', 'TRANSFER_FUNCTION_AZIMUTH_EXCITATION', 'AZIMUTH_AXIS_DRIVE_RESET', 'OPEN_MIRROR_COVER', 'ELEVATION_AXIS_MOVE_VELOCITY', 'LOCKING_PINS_RESET_ALARM', 'CAMERA_CABLE_WRAP_TRACK', 'CAMERA_CABLE_WRAP_DRIVE_RESET', 'MIRROR_COVERS_RETRACT', 'BALANCE_RESET_ALARM', 'MIRROR_COVERS_MOVE', 'CAMERA_CABLE_WRAP_MOVE', 'DEPLOYABLE_PLATFORM_POWER', 'ELEVATION_AXIS_RESET_ALARM', 'MIRROR_COVERS_MOVE_VELOCITY', 'BALANCE_POWER', 'SAFETY_RESET', 'AZIMUTH_AXIS_POWER', 'MIRROR_COVERS_RESET_ALARM', 'ELEVATION_AXIS_STOP', 'LOCKING_PINS_MOVE_ALL', 'AZIMUTH_AXIS_DRIVE_ENABLE', 'AZIMUTH_AXIS_ENABLE_TRACKING', 'AZIMUTH_CABLE_WRAP_MOVE', 'MIRROR_COVERS_STOP', 'ELEVATION_AXIS_ENABLE_TRACKING', 'OIL_SUPPLY_SYSTEM_POWER_OIL', 'LOCKING_PINS_MOVE_VELOCITY', 'TRANSFER_FUNCTION_ELEVATION_EXCITATION', 'AZIMUTH_AXIS_HOME', 'BOTH_AXES_MOVE', 'TRACK_TARGET', 'AZIMUTH_AXIS_TRACK', 'CAMERA_CABLE_WRAP_POWER', 'BALANCE_STOP', 'AZIMUTH_CABLE_WRAP_MOVE_VELOCITY', 'DEPLOYABLE_PLATFORM_RESET_ALARM', 'ELEVATION_AXIS_MOVE', 'APPLICATION_EXIT', 'AZIMUTH_CABLE_WRAP_RESET_ALARM', 'DEPLOYABLE_PLATFORM_MOVE_VELOCITY', 'CAMERA_CABLE_WRAP_MOVE_VELOCITY', 'OIL_SUPPLY_SYSTEM_POWER_COOLING', 'MIRROR_COVER_LOCKS_MOVE', 'AZIMUTH_AXIS_MOVE', 'AZIMUTH_THERMAL_RESET_ALARM', 'AZIMUTH_CABLE_WRAP_POWER', 'MAIN_POWER_SUPPLY_RESET_ALARM', 'MIRROR_COVERS_DEPLOY', 'ERROR', 'ASK_FOR_SET_OF_SETTINGS', 'ELEVATION_THERMAL_RESET_ALARM', 'CABINET_TRACK_AMBIENT', 'AZIMUTH_AXIS_STOP', 'LOCKING_PINS_STOP', 'ELEVATION_AXIS_DRIVE_ENABLE', 'LOCKING_PINS_MOVE', 'ELEVATION_AXIS_TRACK', 'TOP_END_CHILLER_TRACK_AMBIENT', 'AZIMUTH_CABLE_WRAP_DRIVE_RESET', 'ASK_FOR_COMMAND', 'MIRROR_COVER_LOCKS_RESET_ALARM', 'ENTER_CONTROL', 'STAND_BY', 'DISABLE_CAMERA_WRAP', 'OIL_SUPPLY_SYSTEM_POWER_MAIN_PUMP', 'AZIMUTH_CABLE_WRAP_DRIVE_ENABLE', 'AZIMUTH_THERMAL_TRACK_AMBIENT', 'DISABLE', 'ELEVATION_AXIS_HOME', 'STOP_MOUNT', 'OIL_SUPPLY_SYSTEM_POWER', 'ELEVATION_THERMAL_TRACK_AMBIENT', 'AZIMUTH_CABLE_WRAP_STOP', 'AZIMUTH_CABLE_WRAP_ENABLE_TRACKING', 'BALANCE_MOVE', 'BOTH_AXES_TRACK', 'MOVE_TO_TARGET', 'CLEAR_ERRORS', 'ENABLE', 'AZIMUTH_AXIS_RESET_ALARM', 'CAMERA_CABLE_WRAP_STOP', 'MIRROR_COVER_LOCKS_POWER', 'AZIMUTH_CABLE_WRAP_TRACK', 'SYSTEM_READY', 'ENCODER_INTERFACE_BOX_POWER', 'ENTER_PUBLISHONLY', 'DEPLOYABLE_PLATFORM_LOCK_EXTENSION', 'CAMERA_CABLE_WRAP_RESET_ALARM', 'CAMERA_CABLE_WRAP_ENABLE_TRACKING', 'OVERRIDE_CAUSES', 'ELEVATION_AXIS_POWER', 'PXI_COMMAND_DONE', 'MIRROR_COVER_LOCKS_STOP', 'MIRROR_COVERS_POWER', 'CABINET_RESET_ALARM', 'ENCODER_INTERFACE_BOX_CLEAR_POSITION_ERROR', 'TOP_END_CHILLER_RESET_ALARM', 'ELEVATION_THERMAL_POWER', 'CLOSE_MIRROR_COVER'}
power_on

Return true if the device is powered on.

Notes

Override this implementation if the device has multiple subsystems that can individually be powered on.

Methods Documentation

add_methods()

Add do_methods to the command dict

assert_drive_all(command)

Assert that the drive argument is -1 (all drives).

assert_on()

Raise RuntimeError if device off or in an alarm state.

close()

Cancel any background tasks and clean up resources.

do_close(command)
do_move(command)
do_move_all(command)
do_move_velocity(command)
do_open(command)
do_power(command)
do_reset_alarm(command)
do_stop(command)

Stop the actuator.

monitor_move_command(command)

Return a task that is set done when the move is done.

Parameters:
command : Command

Move command.

Returns:
task : asyncio.Task

A task that is set done when the move is done.

move(position, command)

Move to the specified position.

Parameters:
position : float

Desired position, in degrees.

command : Command

Command to monitor and report done.

Returns:
duration : float

Minimum duration of move (sec)

supersede_move_command()

Report the current move command (if any) as superseded.