ionopimax: add SimpleVoltageInput for iono pi

+ add thermofischer cfg (better name needed)
This commit is contained in:
l_samenv
2025-07-10 11:20:22 +02:00
parent cdc2748818
commit cd3fdb6b62
2 changed files with 85 additions and 0 deletions

81
cfg/thermofischer_cfg.py Normal file
View File

@@ -0,0 +1,81 @@
Node('thermofischer.psi.ch',
'thermofischer_waterbath',
'tcp://5000',
)
Mod('wio_1',
'frappy_psi.thermofisher.ThermFishIO',
'connection for water bath',
uri='serial:///dev/ttyUSB0?baudrate=19200', # 3001 = Port 1, 3002 = Port 2 ...
)
Mod('wio_2',
'frappy_psi.thermofisher.ThermFishIO',
'connection for water bath',
uri='serial:///dev/ttyUSB1?baudrate=19200', # 3001 = Port 1, 3002 = Port 2 ...
)
Mod('wio_3',
'frappy_psi.thermofisher.ThermFishIO',
'connection for water bath',
uri='serial:///dev/ttyUSB2?baudrate=19200', # 3001 = Port 1, 3002 = Port 2 ...
)
Mod('Tbath_1',
'frappy_psi.thermofisher.TemperatureLoopA10',
'water_bath_1',
io='wio_1',
control_active=0,
target=25,
tolerance=0.1,
settling_time=20,
)
Mod('Tbath_2',
'frappy_psi.thermofisher.TemperatureLoopA10',
'water_bath_2',
io='wio_2',
control_active=0,
target=25,
tolerance=0.1,
settling_time=20,
)
Mod('Tbath_3',
'frappy_psi.thermofisher.TemperatureLoopA10',
'water_bath_3',
io='wio_3',
control_active=0,
target=25,
tolerance=0.1,
settling_time=20,
)
Mod('valve_1',
'frappy_psi.ionopimax.DigitalOutput',
'valve_for_fast_water_temperature_changing',
addr = 'o1',
target = 0,
)
Mod('valve_2',
'frappy_psi.ionopimax.DigitalOutput',
'valve_for_fast_water_temperature_changing',
addr = 'o2',
target = 0,
)
Mod('valve_3',
'frappy_psi.ionopimax.DigitalOutput',
'valve_for_fast_water_temperature_changing',
addr = 'o3',
target = 0,
)
Mod('temp_sensor_1',
'frappy_psi.ionopimax.SimpleVoltageInput',
'temperatur_sensor_sample',
rawrange = (0.0, 10.0),
valuerange = (-40.0, 150.0),
addr = 'ai1_mv',
)

View File

@@ -140,6 +140,10 @@ class VoltageInput(AnalogInput):
# change mode only if needed, as this disturbs the input for some time # change mode only if needed, as this disturbs the input for some time
self.write(f'{self.addr}_mode', 'U') self.write(f'{self.addr}_mode', 'U')
class SimpleVoltageInput(AnalogInput):
"""version for iono pi"""
scale = 1e-3
class LogVoltageInput(VoltageInput): class LogVoltageInput(VoltageInput):