solo_config/solo/configurations/hetept1/v0009/hetept_config_opheater_patch4.py

44 lines
1.3 KiB
Python
Raw Permalink Normal View History

HET/EPT patch 9.4: activate OP heaters Directly patch the parameters in the PPSS entry that triggeres the OP heater once per minute. Due to the nonlinearity of the regulator we can alway roughly assume we heat with DC=70%. We need to adjust the setpoint with a correspondig offset. This offset depends on the gain. The default gain is `shift=0`. The DC will be ADC-setpoint. A shift of 1, 2, or 3 will reduce the DC by a power of two, i.e., DC = (ADC - setpoint) >> shift This patch keeps shift=0. The target temperatures are HET/EPT1: -6.0°C HET/EPT2: -0.5°C Usage: (stephan)blaulicht:~/solo/solo_config$ ./solopath.py SOLOPATH> from solo.configurations.hetept1.v0009.hetept_config_opheater_patch4 import * … SOLOPATH> main() … SOLOPATH> msg=solo.solomsgclass.msg_print() SOLOPATH> patch1.send(msg) msg(0x000f, 3, 0x0000093500090004) Temp SPY: -6.0°C -3.2°C -8.8°C Temp SPY: -6.0°C -3.3°C -5.9°C Temp SPY: -6.0°C -3.2°C -6.0°C Temp SPY: -6.0°C -3.2°C -6.0°C Temp SPY: -6.0°C -3.2°C -6.0°C msg(0x268c, 3, 0x0000af1f0000c002) msg(0x268d, 3, 0x007270e009f99000) OP heater setpoint: -6 C = 2553 ADC msg(0x2697, 1, 0x00000000000000ff) msg(0x2696, 3, 0x0003e8010000413c) SOLOPATH> patch1.OH_SHIFT=1 SOLOPATH> patch1.send(msg) msg(0x000f, 3, 0x0000093500090004) Temp SPY: -6.0°C -0.2°C -11.8°C Temp SPY: -6.0°C -0.5°C -5.7°C Temp SPY: -6.0°C -0.5°C -6.0°C Temp SPY: -6.0°C -0.5°C -6.0°C Temp SPY: -6.0°C -0.5°C -6.0°C msg(0x268c, 3, 0x0000af1f0000c002) msg(0x268d, 3, 0x007270e019739000) OP heater setpoint: -6 C = 2419 ADC msg(0x2697, 1, 0x00000000000000ff) msg(0x2696, 3, 0x0003e8010000413c)
2022-01-21 12:49:28 +01:00
#! /usr/bin/python3
from solo.patch import patch
class hetept94(patch):
def assemble(self, T, **aa):
self.OH_C = T
if self.config is None:
raise ValueError("Please provide a config=")
self.scratch(subversion=4)
self.ppss_oh = self.config.ppss.find_flags("OPHEATER")[0]
HET/EPT patch 9.4: activate OP heaters Directly patch the parameters in the PPSS entry that triggeres the OP heater once per minute. Due to the nonlinearity of the regulator we can alway roughly assume we heat with DC=70%. We need to adjust the setpoint with a correspondig offset. This offset depends on the gain. The default gain is `shift=0`. The DC will be ADC-setpoint. A shift of 1, 2, or 3 will reduce the DC by a power of two, i.e., DC = (ADC - setpoint) >> shift This patch keeps shift=0. The target temperatures are HET/EPT1: -6.0°C HET/EPT2: -0.5°C Usage: (stephan)blaulicht:~/solo/solo_config$ ./solopath.py SOLOPATH> from solo.configurations.hetept1.v0009.hetept_config_opheater_patch4 import * … SOLOPATH> main() … SOLOPATH> msg=solo.solomsgclass.msg_print() SOLOPATH> patch1.send(msg) msg(0x000f, 3, 0x0000093500090004) Temp SPY: -6.0°C -3.2°C -8.8°C Temp SPY: -6.0°C -3.3°C -5.9°C Temp SPY: -6.0°C -3.2°C -6.0°C Temp SPY: -6.0°C -3.2°C -6.0°C Temp SPY: -6.0°C -3.2°C -6.0°C msg(0x268c, 3, 0x0000af1f0000c002) msg(0x268d, 3, 0x007270e009f99000) OP heater setpoint: -6 C = 2553 ADC msg(0x2697, 1, 0x00000000000000ff) msg(0x2696, 3, 0x0003e8010000413c) SOLOPATH> patch1.OH_SHIFT=1 SOLOPATH> patch1.send(msg) msg(0x000f, 3, 0x0000093500090004) Temp SPY: -6.0°C -0.2°C -11.8°C Temp SPY: -6.0°C -0.5°C -5.7°C Temp SPY: -6.0°C -0.5°C -6.0°C Temp SPY: -6.0°C -0.5°C -6.0°C Temp SPY: -6.0°C -0.5°C -6.0°C msg(0x268c, 3, 0x0000af1f0000c002) msg(0x268d, 3, 0x007270e019739000) OP heater setpoint: -6 C = 2419 ADC msg(0x2697, 1, 0x00000000000000ff) msg(0x2696, 3, 0x0003e8010000413c)
2022-01-21 12:49:28 +01:00
OH_DC_ESTIMATE = 60
HET/EPT patch 9.4: activate OP heaters Directly patch the parameters in the PPSS entry that triggeres the OP heater once per minute. Due to the nonlinearity of the regulator we can alway roughly assume we heat with DC=70%. We need to adjust the setpoint with a correspondig offset. This offset depends on the gain. The default gain is `shift=0`. The DC will be ADC-setpoint. A shift of 1, 2, or 3 will reduce the DC by a power of two, i.e., DC = (ADC - setpoint) >> shift This patch keeps shift=0. The target temperatures are HET/EPT1: -6.0°C HET/EPT2: -0.5°C Usage: (stephan)blaulicht:~/solo/solo_config$ ./solopath.py SOLOPATH> from solo.configurations.hetept1.v0009.hetept_config_opheater_patch4 import * … SOLOPATH> main() … SOLOPATH> msg=solo.solomsgclass.msg_print() SOLOPATH> patch1.send(msg) msg(0x000f, 3, 0x0000093500090004) Temp SPY: -6.0°C -3.2°C -8.8°C Temp SPY: -6.0°C -3.3°C -5.9°C Temp SPY: -6.0°C -3.2°C -6.0°C Temp SPY: -6.0°C -3.2°C -6.0°C Temp SPY: -6.0°C -3.2°C -6.0°C msg(0x268c, 3, 0x0000af1f0000c002) msg(0x268d, 3, 0x007270e009f99000) OP heater setpoint: -6 C = 2553 ADC msg(0x2697, 1, 0x00000000000000ff) msg(0x2696, 3, 0x0003e8010000413c) SOLOPATH> patch1.OH_SHIFT=1 SOLOPATH> patch1.send(msg) msg(0x000f, 3, 0x0000093500090004) Temp SPY: -6.0°C -0.2°C -11.8°C Temp SPY: -6.0°C -0.5°C -5.7°C Temp SPY: -6.0°C -0.5°C -6.0°C Temp SPY: -6.0°C -0.5°C -6.0°C Temp SPY: -6.0°C -0.5°C -6.0°C msg(0x268c, 3, 0x0000af1f0000c002) msg(0x268d, 3, 0x007270e019739000) OP heater setpoint: -6 C = 2419 ADC msg(0x2697, 1, 0x00000000000000ff) msg(0x2696, 3, 0x0003e8010000413c)
2022-01-21 12:49:28 +01:00
OH_SHIFT = 0
OH_DCMAX = 70
HET/EPT patch 9.4: activate OP heaters Directly patch the parameters in the PPSS entry that triggeres the OP heater once per minute. Due to the nonlinearity of the regulator we can alway roughly assume we heat with DC=70%. We need to adjust the setpoint with a correspondig offset. This offset depends on the gain. The default gain is `shift=0`. The DC will be ADC-setpoint. A shift of 1, 2, or 3 will reduce the DC by a power of two, i.e., DC = (ADC - setpoint) >> shift This patch keeps shift=0. The target temperatures are HET/EPT1: -6.0°C HET/EPT2: -0.5°C Usage: (stephan)blaulicht:~/solo/solo_config$ ./solopath.py SOLOPATH> from solo.configurations.hetept1.v0009.hetept_config_opheater_patch4 import * … SOLOPATH> main() … SOLOPATH> msg=solo.solomsgclass.msg_print() SOLOPATH> patch1.send(msg) msg(0x000f, 3, 0x0000093500090004) Temp SPY: -6.0°C -3.2°C -8.8°C Temp SPY: -6.0°C -3.3°C -5.9°C Temp SPY: -6.0°C -3.2°C -6.0°C Temp SPY: -6.0°C -3.2°C -6.0°C Temp SPY: -6.0°C -3.2°C -6.0°C msg(0x268c, 3, 0x0000af1f0000c002) msg(0x268d, 3, 0x007270e009f99000) OP heater setpoint: -6 C = 2553 ADC msg(0x2697, 1, 0x00000000000000ff) msg(0x2696, 3, 0x0003e8010000413c) SOLOPATH> patch1.OH_SHIFT=1 SOLOPATH> patch1.send(msg) msg(0x000f, 3, 0x0000093500090004) Temp SPY: -6.0°C -0.2°C -11.8°C Temp SPY: -6.0°C -0.5°C -5.7°C Temp SPY: -6.0°C -0.5°C -6.0°C Temp SPY: -6.0°C -0.5°C -6.0°C Temp SPY: -6.0°C -0.5°C -6.0°C msg(0x268c, 3, 0x0000af1f0000c002) msg(0x268d, 3, 0x007270e019739000) OP heater setpoint: -6 C = 2419 ADC msg(0x2697, 1, 0x00000000000000ff) msg(0x2696, 3, 0x0003e8010000413c)
2022-01-21 12:49:28 +01:00
def send(self, msg):
self.send_scratch(msg)
self.config.ppss.set_opheater_setpoint(
msg = msg,
T = self.OH_C,
dcmax = self.OH_DCMAX *192//100,
dc_estimate=self.OH_DC_ESTIMATE *192//100,
shift = self.OH_SHIFT )
self.send_ping(msg)
def revert(self, msg):
self.ppss_oh(msg)
self.send_ping(msg)
HET/EPT patch 9.4: activate OP heaters Directly patch the parameters in the PPSS entry that triggeres the OP heater once per minute. Due to the nonlinearity of the regulator we can alway roughly assume we heat with DC=70%. We need to adjust the setpoint with a correspondig offset. This offset depends on the gain. The default gain is `shift=0`. The DC will be ADC-setpoint. A shift of 1, 2, or 3 will reduce the DC by a power of two, i.e., DC = (ADC - setpoint) >> shift This patch keeps shift=0. The target temperatures are HET/EPT1: -6.0°C HET/EPT2: -0.5°C Usage: (stephan)blaulicht:~/solo/solo_config$ ./solopath.py SOLOPATH> from solo.configurations.hetept1.v0009.hetept_config_opheater_patch4 import * … SOLOPATH> main() … SOLOPATH> msg=solo.solomsgclass.msg_print() SOLOPATH> patch1.send(msg) msg(0x000f, 3, 0x0000093500090004) Temp SPY: -6.0°C -3.2°C -8.8°C Temp SPY: -6.0°C -3.3°C -5.9°C Temp SPY: -6.0°C -3.2°C -6.0°C Temp SPY: -6.0°C -3.2°C -6.0°C Temp SPY: -6.0°C -3.2°C -6.0°C msg(0x268c, 3, 0x0000af1f0000c002) msg(0x268d, 3, 0x007270e009f99000) OP heater setpoint: -6 C = 2553 ADC msg(0x2697, 1, 0x00000000000000ff) msg(0x2696, 3, 0x0003e8010000413c) SOLOPATH> patch1.OH_SHIFT=1 SOLOPATH> patch1.send(msg) msg(0x000f, 3, 0x0000093500090004) Temp SPY: -6.0°C -0.2°C -11.8°C Temp SPY: -6.0°C -0.5°C -5.7°C Temp SPY: -6.0°C -0.5°C -6.0°C Temp SPY: -6.0°C -0.5°C -6.0°C Temp SPY: -6.0°C -0.5°C -6.0°C msg(0x268c, 3, 0x0000af1f0000c002) msg(0x268d, 3, 0x007270e019739000) OP heater setpoint: -6 C = 2419 ADC msg(0x2697, 1, 0x00000000000000ff) msg(0x2696, 3, 0x0003e8010000413c)
2022-01-21 12:49:28 +01:00
def main(self, fmts=["xml", "msg"]):
for fmt in fmts:
fn = "hetept%s_v0009_patch4.%s" % (self.config.unit[-1], fmt)
self.emit(f=fn, fmt=fmt)
fn = "hetept%s_v0009_revert4.%s" % (self.config.unit[-1], fmt)
self.emit(f=fn, fmt=fmt, revert=True)
HET/EPT patch 9.4: activate OP heaters Directly patch the parameters in the PPSS entry that triggeres the OP heater once per minute. Due to the nonlinearity of the regulator we can alway roughly assume we heat with DC=70%. We need to adjust the setpoint with a correspondig offset. This offset depends on the gain. The default gain is `shift=0`. The DC will be ADC-setpoint. A shift of 1, 2, or 3 will reduce the DC by a power of two, i.e., DC = (ADC - setpoint) >> shift This patch keeps shift=0. The target temperatures are HET/EPT1: -6.0°C HET/EPT2: -0.5°C Usage: (stephan)blaulicht:~/solo/solo_config$ ./solopath.py SOLOPATH> from solo.configurations.hetept1.v0009.hetept_config_opheater_patch4 import * … SOLOPATH> main() … SOLOPATH> msg=solo.solomsgclass.msg_print() SOLOPATH> patch1.send(msg) msg(0x000f, 3, 0x0000093500090004) Temp SPY: -6.0°C -3.2°C -8.8°C Temp SPY: -6.0°C -3.3°C -5.9°C Temp SPY: -6.0°C -3.2°C -6.0°C Temp SPY: -6.0°C -3.2°C -6.0°C Temp SPY: -6.0°C -3.2°C -6.0°C msg(0x268c, 3, 0x0000af1f0000c002) msg(0x268d, 3, 0x007270e009f99000) OP heater setpoint: -6 C = 2553 ADC msg(0x2697, 1, 0x00000000000000ff) msg(0x2696, 3, 0x0003e8010000413c) SOLOPATH> patch1.OH_SHIFT=1 SOLOPATH> patch1.send(msg) msg(0x000f, 3, 0x0000093500090004) Temp SPY: -6.0°C -0.2°C -11.8°C Temp SPY: -6.0°C -0.5°C -5.7°C Temp SPY: -6.0°C -0.5°C -6.0°C Temp SPY: -6.0°C -0.5°C -6.0°C Temp SPY: -6.0°C -0.5°C -6.0°C msg(0x268c, 3, 0x0000af1f0000c002) msg(0x268d, 3, 0x007270e019739000) OP heater setpoint: -6 C = 2419 ADC msg(0x2697, 1, 0x00000000000000ff) msg(0x2696, 3, 0x0003e8010000413c)
2022-01-21 12:49:28 +01:00
import solo.hetept.config
patch1 = hetept94(name="fm1", T=-6.0, config=solo.hetept.config.fm1(config_page=0x10000, patch=3))
patch2 = hetept94(name="fm2", T=-1.0, config=solo.hetept.config.fm2(config_page=0x10000, patch=3))
HET/EPT patch 9.4: activate OP heaters Directly patch the parameters in the PPSS entry that triggeres the OP heater once per minute. Due to the nonlinearity of the regulator we can alway roughly assume we heat with DC=70%. We need to adjust the setpoint with a correspondig offset. This offset depends on the gain. The default gain is `shift=0`. The DC will be ADC-setpoint. A shift of 1, 2, or 3 will reduce the DC by a power of two, i.e., DC = (ADC - setpoint) >> shift This patch keeps shift=0. The target temperatures are HET/EPT1: -6.0°C HET/EPT2: -0.5°C Usage: (stephan)blaulicht:~/solo/solo_config$ ./solopath.py SOLOPATH> from solo.configurations.hetept1.v0009.hetept_config_opheater_patch4 import * … SOLOPATH> main() … SOLOPATH> msg=solo.solomsgclass.msg_print() SOLOPATH> patch1.send(msg) msg(0x000f, 3, 0x0000093500090004) Temp SPY: -6.0°C -3.2°C -8.8°C Temp SPY: -6.0°C -3.3°C -5.9°C Temp SPY: -6.0°C -3.2°C -6.0°C Temp SPY: -6.0°C -3.2°C -6.0°C Temp SPY: -6.0°C -3.2°C -6.0°C msg(0x268c, 3, 0x0000af1f0000c002) msg(0x268d, 3, 0x007270e009f99000) OP heater setpoint: -6 C = 2553 ADC msg(0x2697, 1, 0x00000000000000ff) msg(0x2696, 3, 0x0003e8010000413c) SOLOPATH> patch1.OH_SHIFT=1 SOLOPATH> patch1.send(msg) msg(0x000f, 3, 0x0000093500090004) Temp SPY: -6.0°C -0.2°C -11.8°C Temp SPY: -6.0°C -0.5°C -5.7°C Temp SPY: -6.0°C -0.5°C -6.0°C Temp SPY: -6.0°C -0.5°C -6.0°C Temp SPY: -6.0°C -0.5°C -6.0°C msg(0x268c, 3, 0x0000af1f0000c002) msg(0x268d, 3, 0x007270e019739000) OP heater setpoint: -6 C = 2419 ADC msg(0x2697, 1, 0x00000000000000ff) msg(0x2696, 3, 0x0003e8010000413c)
2022-01-21 12:49:28 +01:00
def main():
patch1.main()
patch2.main()