From 576723c650eed11199ba76049c10aaf7a9319f5a Mon Sep 17 00:00:00 2001 From: Markus Zolliker Date: Mon, 27 Oct 2025 11:59:00 +0100 Subject: [PATCH] frappy_psi.picontrol: add PIctrl Change-Id: If212712b691ecabec1ff70d7040eb4e23924c01e --- frappy_psi/picontrol.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/frappy_psi/picontrol.py b/frappy_psi/picontrol.py index ef018de2..6c9316e1 100644 --- a/frappy_psi/picontrol.py +++ b/frappy_psi/picontrol.py @@ -62,8 +62,8 @@ import time import math from frappy.core import Readable, Writable, Parameter, Attached, IDLE, Property from frappy.lib import clamp, merge_status -from frappy.datatypes import LimitsType, EnumType, BoolType, FloatRange -from frappy.ctrlby import HasOutputModule +from frappy.datatypes import LimitsType, EnumType, FloatRange +from frappy.ctrlby import HasOutputModule, WrapControlledBy from frappy_psi.convergence import HasConvergence @@ -162,7 +162,6 @@ class PImixin(HasOutputModule, Writable): if not self.control_active: self.activate_control() -# unchecked! class PI(HasConvergence, PImixin): input_module = Attached(Readable, 'the input module') @@ -186,3 +185,7 @@ class PI2(PI): if not self.control_active: self.output.write_target(target) super().write_target(target) + + +class PIctrl(WrapControlledBy, PI): + """a pi controller which is controlled by another loop"""