secop_mlz: minor rework entangle client
Change-Id: Ie406b4220c22cdbf302a1fd36f2d7407d81a47fa Reviewed-on: https://forge.frm2.tum.de/review/c/sine2020/secop/playground/+/28951 Tested-by: Jenkins Automated Tests <pedersen+jenkins@frm2.tum.de> Reviewed-by: Markus Zolliker <markus.zolliker@psi.ch> Reviewed-by: Enrico Faulhaber <enrico.faulhaber@frm2.tum.de>
This commit is contained in:
parent
de5f17695c
commit
0df50bb0f9
@ -28,6 +28,9 @@ Here we support devices which fulfill the official
|
|||||||
MLZ TANGO interface for the respective device classes.
|
MLZ TANGO interface for the respective device classes.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
|
# pylint: disable=too-many-lines
|
||||||
|
|
||||||
|
|
||||||
import re
|
import re
|
||||||
import threading
|
import threading
|
||||||
from time import sleep
|
from time import sleep
|
||||||
@ -173,7 +176,7 @@ class PyTangoDevice(Module):
|
|||||||
tango_status_mapping = {
|
tango_status_mapping = {
|
||||||
PyTango.DevState.ON: Drivable.Status.IDLE,
|
PyTango.DevState.ON: Drivable.Status.IDLE,
|
||||||
PyTango.DevState.ALARM: Drivable.Status.WARN,
|
PyTango.DevState.ALARM: Drivable.Status.WARN,
|
||||||
PyTango.DevState.OFF: Drivable.Status.ERROR,
|
PyTango.DevState.OFF: Drivable.Status.DISABLED,
|
||||||
PyTango.DevState.FAULT: Drivable.Status.ERROR,
|
PyTango.DevState.FAULT: Drivable.Status.ERROR,
|
||||||
PyTango.DevState.MOVING: Drivable.Status.BUSY,
|
PyTango.DevState.MOVING: Drivable.Status.BUSY,
|
||||||
}
|
}
|
||||||
@ -504,6 +507,9 @@ class AnalogOutput(PyTangoDevice, Drivable):
|
|||||||
return stable and at_target
|
return stable and at_target
|
||||||
|
|
||||||
def read_status(self):
|
def read_status(self):
|
||||||
|
_st, _sts = super().read_status()
|
||||||
|
if _st == Readable.Status.DISABLED:
|
||||||
|
return _st, _sts
|
||||||
if self._isAtTarget():
|
if self._isAtTarget():
|
||||||
self._timeout = None
|
self._timeout = None
|
||||||
self._moving = False
|
self._moving = False
|
||||||
|
Loading…
x
Reference in New Issue
Block a user