feat(omny): seed the 3 known CryoCon channels in SimOMNYTemperatures
CI for csaxs_bec / test (push) Successful in 3m56s

Chan A "Cryo sample" 90K, Chan B "Cryo head" 82K, Chan C "Sample backup"
90K, all closed-loop (reading == setpoint). Channel D has no known real
use yet and is left unseeded.
This commit is contained in:
x01dc committed 2026-09-01 19:20:12 +02:00
1 parent 7aedac148c
commit 5e8fda761f
1 file changed
+21 -2
+21 -2
View File
@@ -334,12 +334,19 @@ _TEMP_CHANNELS = {
47: ("Park_Cryo_L", "K", 140, 100.0, 73.2),
}
# CryoCon channels ("CRYO" bank, cryo_temperature1-4 -> A-D). Closed-loop controlled,
# so the simulated reading is put at the real setpoint. Channel D has no known real
# use yet -- left unseeded (shows as "0"/0.00; the CRYO branch of show_all() has no
# name-based hiding, unlike the TEMP bank).
# controller number (1=A, 2=B, 3=C, 4=D): (name, reading/setpoint in K)
_CRYO_CHANNELS = {1: ("Cryo sample", 90.0), 2: ("Cryo head", 82.0), 3: ("Sample backup", 90.0)}
class SimOMNYTemperatures(OMNYTemperatures):
"""OMNYTemperatures with all EPICS PVs replaced by in-memory mock PVs, seeded
with realistic per-channel names/units/readings/setpoints for the 29 real "TEMP"
channels (see _TEMP_CHANNELS above). The 4 "CRYO" channels are not seeded yet --
pending the cryocon controller reference.
channels (see _TEMP_CHANNELS above) and the 3 known "CRYO" channels (see
_CRYO_CHANNELS above).
"""
def __new__(cls, *args, **kwargs):
@@ -361,6 +368,18 @@ class SimOMNYTemperatures(OMNYTemperatures):
getattr(
temperatures.temperature_alarmstate, f"temperature_alarmstate{channel}"
).put(0)
for controller_nr, (name, reading) in _CRYO_CHANNELS.items():
getattr(
temperatures.cryo_temperature_name, f"cryo_temperature_name{controller_nr}"
).put(name)
getattr(temperatures.cryo_temperature, f"cryo_temperature{controller_nr}").put(
reading
)
getattr(
temperatures.cryo_temperature_setpoint,
f"cryo_temperature_setpoint{controller_nr}",
).put(reading)
temperatures.cryo_temperature_closed_loop.put(1)
temperatures.temperature_update_time.put(now)
temperatures.cryo_temperature_update_time.put(now)
return temperatures