diff --git a/ADwinProII/labscript_devices_ADwin_modules.py b/ADwinProII/labscript_devices_ADwin_modules.py index dc98dab5dbafc69f3dc3ed69ea69789138d3f7a2..159a52a1c0c2e293a8793a81982ae17e82d47ad3 100644 --- a/ADwinProII/labscript_devices_ADwin_modules.py +++ b/ADwinProII/labscript_devices_ADwin_modules.py @@ -187,6 +187,15 @@ class ADwinAnalogOut(AnalogOut): super().add_instruction(time,instruction,units) self.limits = limits_temp + def expand_timeseries(self,all_times,flat_all_times_len): + # Overwrite Output.add_instruction without limit check, becasue the value can be off-limits when this is the target value of the PID + # TODO / WARNING: THIS IS QUITE HACKY AND COULD LEAD TO OFF-LIMIT VALUES NOT NOTICED + # (the actual limits are also checked in the ADwin, so the actual output should be always within limits!) + limits_temp = self.limits + self.limits = (-10,10) + super().expand_timeseries(all_times,flat_all_times_len) + self.limits = limits_temp + class ADwinAnalogIn(AnalogIn): """Analog Input for use with ADwin Pro II Input modules.""" description = 'ADwin Analog Input'