diff --git a/src/mlpro/bf/control/controllers/pid_controller.py b/src/mlpro/bf/control/controllers/pid_controller.py index 7176c6a2a..b8a980e34 100644 --- a/src/mlpro/bf/control/controllers/pid_controller.py +++ b/src/mlpro/bf/control/controllers/pid_controller.py @@ -149,7 +149,7 @@ def _compute_output(self, p_ctrl_error: ControlError, p_ctrl_var: ActionElement) """ #get control error - control_error_siso = p_ctrl_error._get_values()[0] + control_error_siso = p_ctrl_error.values[0] #time delta dt = 0 diff --git a/test/howtos/oa/control/PT/howto_oa_control_PT_001_pid_control_PT1.py b/test/howtos/oa/control/PT/howto_oa_control_PT_001_pid_control_PT1.py index 65baaa3fd..8cefb25eb 100644 --- a/test/howtos/oa/control/PT/howto_oa_control_PT_001_pid_control_PT1.py +++ b/test/howtos/oa/control/PT/howto_oa_control_PT_001_pid_control_PT1.py @@ -116,6 +116,7 @@ def _compute_reward(self, p_state_old: ControlledVariable = None, p_state_new: C T = 5 T_l = 0.1 cycle_limit = int(3*T/T_l)*10 +cycle_limit = 500 if __name__ == '__main__': # 2.1 Parameters for demo mode cycle_limit = cycle_limit