adopt frappy_psi and frappy changes from wip

Change-Id: I4e6732e755398d88b73007fb53b758039c5d4483
This commit is contained in:
2024-01-29 10:56:58 +01:00
parent 3eb5f90ce6
commit a429852c80
15 changed files with 597 additions and 12 deletions

View File

@@ -28,9 +28,9 @@ from frappy_psi.magfield import Magfield, SimpleMagfield, Status
from frappy_psi.mercury import MercuryChannel, off_on, Mapped
from frappy.states import Retry
Action = Enum(hold=0, run_to_set=1, run_to_zero=2, clamped=3)
Action = Enum(hold=0, run_to_set=1, run_to_zero=2, clamped=3, not_found=4)
hold_rtoz_rtos_clmp = Mapped(HOLD=Action.hold, RTOS=Action.run_to_set,
RTOZ=Action.run_to_zero, CLMP=Action.clamped)
RTOZ=Action.run_to_zero, CLMP=Action.clamped, NOT_FOUND=Action.not_found)
CURRENT_CHECK_SIZE = 2
@@ -161,6 +161,7 @@ class Field(SimpleField, Magfield):
if self.switch_heater == self.switch_heater.on:
self.__persistent_field = current
self.forced_persistent_field = False
self._field_mismatch = False
return current
pf = self.query('DEV::PSU:SIG:PFLD')
if self.__persistent_field is None: