Leons lost commit

This commit is contained in:
2021-11-03 09:06:43 +01:00
parent dbc750be7d
commit ba05d67a81
3 changed files with 13 additions and 2 deletions
+11
View File
@@ -80,6 +80,17 @@ class HelmholtzCageDevice:
# The axes talks to the HW objects (Arduino, PSU) referenced in this object
self.axes.append(Axis(i, self))
# --- Preliminary PSU type info ---
# Required post-initialization but before hardware has been connected
psu_type_string = config_handling.read_from_config("Supplies", "supply_model",
config_handling.CONFIG_OBJECT)
if psu_type_string == "ps2000b":
self.psu_type = PSUDevicePS2000B
elif psu_type_string == "ql355tp":
self.psu_type = PSUDeviceQL355TP
else:
raise Exception("Invalid psu model:\n{}".format(self.psu_type))
# --- HW COMMUNICATION THREAD ---
self._cmd_exec_thread = Thread(target=self._cmd_exec_thread_method)
self._cmd_exec_thread.start()