UtilityMonitor#

class lsst.ts.m2gui.UtilityMonitor#

Bases: object

Utility monitor to monitor the utility status.

Attributes#

signal_utilitySignalUtility

Signal to report the utility status.

signal_detailed_forceSignalDetailedForce

Signal to report the detailed force.

signal_positionSignalPosition

Signal to report the rigid body position.

signal_net_force_momentSignalNetForceMoment

Signal to send the net force, moment, and force balance status.

power_motor_calibrateddict

Calibrated motor power. The unit of voltage is volt and the unit of current is ampere.

power_communication_calibrateddict

Calibrated communication power. The unit of voltage is volt and the unit of current is ampere.

power_motor_rawdict

Raw motor power. The unit of voltage is volt and the unit of current is ampere.

power_communication_rawdict

Raw communication power. The unit of voltage is volt and the unit of current is ampere.

inclinometer_anglefloat

Inclinometer angle in degree.

inclinometer_angle_tmafloat

Inclinometer angle of telescope mount assembly (TMA) in degree.

breakersdict

Breakers. The key is the breaker name. If the breaker is triggered, the value is True. Otherwise, False.

temperaturesdict

Tempertures. The key is the temperature sensor name. The value is the related temperature in degree C.

displacementsdict

Displacement sensors. The key is the displacement sensor name. The value is the reading in the unit of mm.

digital_status_inputint

Digital input status as a 32 bits value. Each bit means different status. 1 means OK (or triggered). Otherwise 0.

digital_status_outputint

Digital output status as a 8 bits value. Each bit means different status. 1 means OK (or triggered). Otherwise 0.

hard_pointsdict

Hard points of the axial and tangential actuators.

forces_axialActuatorForceAxial

Detailed axial actuator forces.

forces_tangentActuatorForceTangent

Detailed tangent actuator forces.

force_error_tangentForceErrorTangent

Tangential force error to monitor the supporting force of mirror.

positionlist

Rigid body position: [x, y, z, rx, ry, rz] based on the hardpoint displacement. The unit of x, y, and z is um. The unit of rx, ry, and ry is arcsec.

position_imslist

Rigid body position: [x, y, z, rx, ry, rz] based on the independent measurement system (IMS). The unit of x, y, and z is um. The unit of rx, ry, and ry is arcsec.

net_force_totallist

Total actuator net force in Newton: [fx, fy, fz].

net_moment_totallist

Total actuator net moment in Newton * meter: [mx, my, mz].

force_balancelist

Force balance status: [fx, fy, fz, mx, my, mz]. The units of force and moment are Newton and Newton * meter.

Attributes Summary

Methods Summary

get_breakers(power_type)

Get the breakers of the specific power type.

get_displacement_sensors(direction)

Get the displacement sensors in a specific direction.

get_forces_axial()

Get the axial forces.

get_forces_tangent()

Get the tangent forces.

get_temperature_sensors(temperature_group)

Get the temperature sensors in a specific group.

report_utility_status()

Report the utility status.

reset_breakers(power_type)

Reset the breakers.

update_breaker(name, new_status)

Update the breaker status.

update_digital_status_input(new_status)

Update the digital input status (32 bits).

update_digital_status_output(new_status)

Update the digital output status (8 bits).

update_displacements(direction, ...)

Update the displacement sensor data.

update_force_balance(value_new)

Update the force balance status.

update_force_error_tangent(force_error_tangent)

Update the tangential force error that monitors the supporting force of mirror.

update_forces_axial(actuator_force)

Update the axial actuator forces.

update_forces_tangent(actuator_force)

Update the tangent actuator forces.

update_hard_points(axial, tangent)

Update the hard points.

update_inclinometer_angle(new_angle[, ...])

Update the angle of inclinometer.

update_net_force_moment_total(value_new[, ...])

Update the total net force or moment.

update_position(x, y, z, rx, ry, rz[, is_ims])

Update the position of rigid body.

update_power_calibrated(power_type, ...)

Update the calibrated power data.

update_power_raw(power_type, new_voltage, ...)

Update the raw power data.

update_temperature(temperature_group, ...)

Update the temperature data.

Attributes Documentation

NUM_DIGIT_AFTER_DECIMAL = 1#
NUM_DIGIT_AFTER_DECIMAL_DISPLACEMENT = 3#

Methods Documentation

get_breakers(power_type: PowerType) list[str]#

Get the breakers of the specific power type.

Parameters#

power_typeenum MTM2.PowerType

Power type.

Returns#

list [str]

List of the breakers.

get_displacement_sensors(direction: DisplacementSensorDirection) list[str]#

Get the displacement sensors in a specific direction.

Parameters#

directionenum DisplacementSensorDirection

Direction of the displacement sensors.

Returns#

list [str]

List of the sensors.

get_forces_axial() ActuatorForceAxial#

Get the axial forces.

Returns#

ActuatorForceAxial

Detailed axial actuator forces as a new copy of internal data.

get_forces_tangent() ActuatorForceTangent#

Get the tangent forces.

Returns#

ActuatorForceTangent

Detailed tangent actuator forces as a new copy of internal data.

get_temperature_sensors(temperature_group: TemperatureGroup) list[str]#

Get the temperature sensors in a specific group.

Parameters#

temperature_groupenum TemperatureGroup

Temperature group.

Returns#

list [str]

List of the sensors.

report_utility_status() None#

Report the utility status.

reset_breakers(power_type: PowerType) None#

Reset the breakers.

Parameters#

power_typeenum MTM2.PowerType

Power type.

update_breaker(name: str, new_status: bool) None#

Update the breaker status.

Parameters#

namestr

Breaker name, which is in the keys of self.breakers.

new_statusbool

New status of breaker. If the breake is triggered, put True, otherwise, False.

update_digital_status_input(new_status: int) None#

Update the digital input status (32 bits).

Parameters#

new_statusint

New status.

update_digital_status_output(new_status: int) None#

Update the digital output status (8 bits).

Parameters#

new_statusint

New status.

update_displacements(direction: DisplacementSensorDirection, new_displacements: list[float]) None#

Update the displacement sensor data.

This function assumes the mirror’s movement is usually in a specific direction.

Parameters#

directionenum DisplacementSensorDirection

Direction of the displacement sensors.

new_displacementslist [float]

New displacements in millimeter. The order should begin from sensor 1 to sensor n defined in the specific direction.

update_force_balance(value_new: list[float]) None#

Update the force balance status.

Parameters#

value_newlist

New (fx, fy, fz, mx, my, mz) component values. Unit is Newton or Newton * meter that depends on the component is force or moment.

update_force_error_tangent(force_error_tangent: ForceErrorTangent) None#

Update the tangential force error that monitors the supporting force of mirror.

Parameters#

force_error_tangentForceErrorTangent

Tangential force error.

update_forces_axial(actuator_force: ActuatorForceAxial) None#

Update the axial actuator forces.

Parameters#

actuator_forceActuatorForceAxial

Axial actuator force.

Raises#

ValueError

When the input is the same object of self.forces_axial.

update_forces_tangent(actuator_force: ActuatorForceTangent) None#

Update the tangent actuator forces.

Parameters#

actuator_forceActuatorForceTangent

Tangent actuator force.

Raises#

ValueError

When the input is the same object of self.forces_tangent.

update_hard_points(axial: list[int], tangent: list[int]) None#

Update the hard points.

Parameters#

axiallist

List of the hard points in axial direction.

tangentlist

List of the hard points in tangent direction.

Raises#

ValueError

Lengths of the inputs are not right.

update_inclinometer_angle(new_angle: float, new_angle_processed: float | None = None, is_internal: bool = True) None#

Update the angle of inclinometer.

Parameters#

new_anglefloat

New angle value in degree.

new_angle_processedfloat or None, optional

New processed angle value in degree.

is_internalbool

Is the internal inclinometer or not. If False, the new_angle comes from the telescope mount assembly (TMA). (the default is True)

update_net_force_moment_total(value_new: list[float], is_force: bool = True) None#

Update the total net force or moment.

Parameters#

value_newlist

New (x, y, z) component values. Unit is Newton or Newton * meter based on ‘is_force’.

is_forcebool, optional

Is the force data or not. If not, the moment data is applied. (the default is True)

update_position(x: float, y: float, z: float, rx: float, ry: float, rz: float, is_ims: bool = False) None#

Update the position of rigid body.

Parameters#

xfloat

Position x in um.

yfloat

Position y in um.

zfloat

Position z in um.

rxfloat

Rotation x in arcsec.

ryfloat

Rotation y in arcsec.

rzfloat

Rotation z in arcsec.

is_imsbool, optional

Is based on the independent measurement system (IMS) or not. (the default is False)

update_power_calibrated(power_type: PowerType, new_voltage: float, new_current: float) None#

Update the calibrated power data.

Parameters#

power_typeenum MTM2.PowerType

Power type.

new_voltagefloat

New voltage value in volt.

new_currentfloat

New current value in ampere.

Raises#

ValueError

Not supported power type.

update_power_raw(power_type: PowerType, new_voltage: float, new_current: float) None#

Update the raw power data.

Parameters#

power_typeenum MTM2.PowerType

Power type.

new_voltagefloat

New voltage value in volt.

new_currentfloat

New current value in ampere.

Raises#

ValueError

Not supported power type.

update_temperature(temperature_group: TemperatureGroup, new_temperatures: list[float]) None#

Update the temperature data.

This function assumes the temperature’s fluctuation is usually restricted to a small region (group) in the most of time.

Parameters#

temperature_groupenum TemperatureGroup

Temperature group.

new_temperatureslist [float]

New temperatures in degree. The order should begin from sensor 1 to sensor n defined in the specific temperature group.