mirror of
https://github.com/bec-project/ophyd_devices.git
synced 2025-06-11 05:47:14 +02:00
Signal type fix
This commit is contained in:
@ -20,3 +20,5 @@ from .devices.softpositioner import SoftPositioner
|
|||||||
from .utils.bec_device_base import BECDeviceBase
|
from .utils.bec_device_base import BECDeviceBase
|
||||||
from .utils.dynamic_pseudo import ComputedSignal
|
from .utils.dynamic_pseudo import ComputedSignal
|
||||||
from .utils.static_device_test import launch
|
from .utils.static_device_test import launch
|
||||||
|
|
||||||
|
from .devices.psi_motor import EpicsMotorMR, EpicsMotorEC
|
||||||
|
@ -50,9 +50,7 @@ class EpicsMotorMR(EpicsMotor):
|
|||||||
# Warn if EPIC motorRecord claims an error (it's not easy to reset)
|
# Warn if EPIC motorRecord claims an error (it's not easy to reset)
|
||||||
status = self.motor_status.get()
|
status = self.motor_status.get()
|
||||||
if status:
|
if status:
|
||||||
self.log.warning(
|
self.log.warning(f"EPICS MotorRecord is in alarm state {status}, ophyd will raise")
|
||||||
f"EPICS MotorRecord is in alarm state {status}, ophyd will raise"
|
|
||||||
)
|
|
||||||
# Warn if trying to move beyond an active limit
|
# Warn if trying to move beyond an active limit
|
||||||
# NOTE: VME limit switches active only in the direction of travel (or disconnected)
|
# NOTE: VME limit switches active only in the direction of travel (or disconnected)
|
||||||
# NOTE: SoftMotor limits are not propagated at all
|
# NOTE: SoftMotor limits are not propagated at all
|
||||||
@ -83,7 +81,7 @@ class EpicsMotorEC(EpicsMotorMR):
|
|||||||
USER_ACCESS = ["reset"]
|
USER_ACCESS = ["reset"]
|
||||||
motor_enable_readback = Component(EpicsSignalRO, "-EnaAct", auto_monitor=True, kind=Kind.normal)
|
motor_enable_readback = Component(EpicsSignalRO, "-EnaAct", auto_monitor=True, kind=Kind.normal)
|
||||||
motor_enable = Component(
|
motor_enable = Component(
|
||||||
EpicsSignalRO,
|
EpicsSignal,
|
||||||
"-EnaCmd-RB",
|
"-EnaCmd-RB",
|
||||||
write_pv="-EnaCmd",
|
write_pv="-EnaCmd",
|
||||||
put_complete=True,
|
put_complete=True,
|
||||||
@ -132,13 +130,12 @@ class EpicsMotorEC(EpicsMotorMR):
|
|||||||
|
|
||||||
Common error causes:
|
Common error causes:
|
||||||
-------------------------
|
-------------------------
|
||||||
- MAX_POSITION_LAG_EXCEEDED : The PID tuning is wrong, tolerance is too
|
- MAX_POSITION_LAG_EXCEEDED : The PID tuning is wrong, tolerance is too low, acceleration
|
||||||
low, acceleration is too high, scaling is off, or the motor
|
is too high, scaling is off, or the motor lacks torque.
|
||||||
lacks torque.
|
- MAX_VELOCITY_EXCEEDED : PID is wrong or the motor is sticking-slipping.
|
||||||
- MAX_VELOCITY_EXCEEDED : PID is wrong or the motor is sticking-slipping
|
- BOTH_LIMITS_ACTIVE : The motors are probably not connected.
|
||||||
- BOTH_LIMITS_ACTIVE : The motors are probably not connected
|
- HW_ERROR : Tricky one, usually the drive power supply is cut due to fuse or safety. You
|
||||||
- HW_ERROR : Tricky one, usually the drive power supply is cut due to
|
might need to push physical buttons.
|
||||||
fuse or safety, might need to push physical buttons.
|
|
||||||
"""
|
"""
|
||||||
# Reset the error
|
# Reset the error
|
||||||
self.error_reset.set(1, settle_time=0.2).wait()
|
self.error_reset.set(1, settle_time=0.2).wait()
|
||||||
|
Reference in New Issue
Block a user