forked from M-Labs/thermostat
$ch
This commit is contained in:
parent
977261e684
commit
d68ff0e182
@ -37,7 +37,7 @@
|
|||||||
null,
|
null,
|
||||||
[
|
[
|
||||||
"pwm",
|
"pwm",
|
||||||
"ch",
|
"$ch",
|
||||||
"pid"
|
"pid"
|
||||||
]
|
]
|
||||||
],
|
],
|
||||||
@ -58,7 +58,7 @@
|
|||||||
"compactHeight":false,
|
"compactHeight":false,
|
||||||
"param":[
|
"param":[
|
||||||
"pwm",
|
"pwm",
|
||||||
"ch",
|
"$ch",
|
||||||
"i_set"
|
"i_set"
|
||||||
],
|
],
|
||||||
"tip": "Set current through output",
|
"tip": "Set current through output",
|
||||||
@ -78,7 +78,7 @@
|
|||||||
"compactHeight":false,
|
"compactHeight":false,
|
||||||
"param":[
|
"param":[
|
||||||
"pid",
|
"pid",
|
||||||
"ch",
|
"$ch",
|
||||||
"target"
|
"target"
|
||||||
],
|
],
|
||||||
"tip": "Set target temperature",
|
"tip": "Set target temperature",
|
||||||
@ -106,7 +106,7 @@
|
|||||||
],
|
],
|
||||||
"param":[
|
"param":[
|
||||||
"pwm",
|
"pwm",
|
||||||
"ch",
|
"$ch",
|
||||||
"max_i_pos"
|
"max_i_pos"
|
||||||
],
|
],
|
||||||
"tip": "The maximum cooling (+ve) current through the output pins",
|
"tip": "The maximum cooling (+ve) current through the output pins",
|
||||||
@ -126,7 +126,7 @@
|
|||||||
],
|
],
|
||||||
"param":[
|
"param":[
|
||||||
"pwm",
|
"pwm",
|
||||||
"ch",
|
"$ch",
|
||||||
"max_i_neg"
|
"max_i_neg"
|
||||||
],
|
],
|
||||||
"tip": "The maximum heating (-ve) current through the output pins",
|
"tip": "The maximum heating (-ve) current through the output pins",
|
||||||
@ -146,7 +146,7 @@
|
|||||||
"compactHeight":false,
|
"compactHeight":false,
|
||||||
"param":[
|
"param":[
|
||||||
"pwm",
|
"pwm",
|
||||||
"ch",
|
"$ch",
|
||||||
"max_v"
|
"max_v"
|
||||||
],
|
],
|
||||||
"tip": "The maximum voltage across the output pins",
|
"tip": "The maximum voltage across the output pins",
|
||||||
@ -177,7 +177,7 @@
|
|||||||
"compactHeight":false,
|
"compactHeight":false,
|
||||||
"param":[
|
"param":[
|
||||||
"s-h",
|
"s-h",
|
||||||
"ch",
|
"$ch",
|
||||||
"t0"
|
"t0"
|
||||||
],
|
],
|
||||||
"tip": "The origin temperature for the B-Parameter equation",
|
"tip": "The origin temperature for the B-Parameter equation",
|
||||||
@ -193,7 +193,7 @@
|
|||||||
"compactHeight":false,
|
"compactHeight":false,
|
||||||
"param":[
|
"param":[
|
||||||
"s-h",
|
"s-h",
|
||||||
"ch",
|
"$ch",
|
||||||
"r0"
|
"r0"
|
||||||
],
|
],
|
||||||
"tip": "The origin resistance for the B-Parameter equation",
|
"tip": "The origin resistance for the B-Parameter equation",
|
||||||
@ -209,7 +209,7 @@
|
|||||||
"compactHeight":false,
|
"compactHeight":false,
|
||||||
"param":[
|
"param":[
|
||||||
"s-h",
|
"s-h",
|
||||||
"ch",
|
"$ch",
|
||||||
"b"
|
"b"
|
||||||
],
|
],
|
||||||
"tip": "The B-Parameter",
|
"tip": "The B-Parameter",
|
||||||
@ -222,7 +222,7 @@
|
|||||||
"value":16.67,
|
"value":16.67,
|
||||||
"param":[
|
"param":[
|
||||||
"postfilter",
|
"postfilter",
|
||||||
"ch",
|
"$ch",
|
||||||
"rate"
|
"rate"
|
||||||
],
|
],
|
||||||
"limits":{
|
"limits":{
|
||||||
@ -253,7 +253,7 @@
|
|||||||
"compactHeight":false,
|
"compactHeight":false,
|
||||||
"param":[
|
"param":[
|
||||||
"pid",
|
"pid",
|
||||||
"ch",
|
"$ch",
|
||||||
"kp"
|
"kp"
|
||||||
],
|
],
|
||||||
"tip": "Proportional gain",
|
"tip": "Proportional gain",
|
||||||
@ -268,7 +268,7 @@
|
|||||||
"compactHeight":false,
|
"compactHeight":false,
|
||||||
"param":[
|
"param":[
|
||||||
"pid",
|
"pid",
|
||||||
"ch",
|
"$ch",
|
||||||
"ki"
|
"ki"
|
||||||
],
|
],
|
||||||
"tip": "Integral gain",
|
"tip": "Integral gain",
|
||||||
@ -283,7 +283,7 @@
|
|||||||
"compactHeight":false,
|
"compactHeight":false,
|
||||||
"param":[
|
"param":[
|
||||||
"pid",
|
"pid",
|
||||||
"ch",
|
"$ch",
|
||||||
"kd"
|
"kd"
|
||||||
],
|
],
|
||||||
"tip": "Differential gain",
|
"tip": "Differential gain",
|
||||||
@ -309,7 +309,7 @@
|
|||||||
"compactHeight":false,
|
"compactHeight":false,
|
||||||
"param":[
|
"param":[
|
||||||
"pid",
|
"pid",
|
||||||
"ch",
|
"$ch",
|
||||||
"output_min"
|
"output_min"
|
||||||
],
|
],
|
||||||
"tip": "Minimum PID output",
|
"tip": "Minimum PID output",
|
||||||
@ -328,7 +328,7 @@
|
|||||||
"compactHeight":false,
|
"compactHeight":false,
|
||||||
"param":[
|
"param":[
|
||||||
"pid",
|
"pid",
|
||||||
"ch",
|
"$ch",
|
||||||
"output_max"
|
"output_max"
|
||||||
],
|
],
|
||||||
"tip": "Maximum PID output",
|
"tip": "Maximum PID output",
|
||||||
@ -353,7 +353,7 @@
|
|||||||
"compactHeight":false,
|
"compactHeight":false,
|
||||||
"pid_autotune":[
|
"pid_autotune":[
|
||||||
"target_temp",
|
"target_temp",
|
||||||
"ch"
|
"$ch"
|
||||||
],
|
],
|
||||||
"tip": "The target temperature to autotune for"
|
"tip": "The target temperature to autotune for"
|
||||||
},
|
},
|
||||||
@ -371,7 +371,7 @@
|
|||||||
],
|
],
|
||||||
"pid_autotune":[
|
"pid_autotune":[
|
||||||
"test_current",
|
"test_current",
|
||||||
"ch"
|
"$ch"
|
||||||
],
|
],
|
||||||
"tip": "The testing current when autotuning"
|
"tip": "The testing current when autotuning"
|
||||||
},
|
},
|
||||||
@ -386,7 +386,7 @@
|
|||||||
"compactHeight":false,
|
"compactHeight":false,
|
||||||
"pid_autotune":[
|
"pid_autotune":[
|
||||||
"temp_swing",
|
"temp_swing",
|
||||||
"ch"
|
"$ch"
|
||||||
],
|
],
|
||||||
"tip": "The temperature swing around the target"
|
"tip": "The temperature swing around the target"
|
||||||
},
|
},
|
||||||
@ -400,7 +400,7 @@
|
|||||||
"compactHeight":false,
|
"compactHeight":false,
|
||||||
"pid_autotune":[
|
"pid_autotune":[
|
||||||
"lookback",
|
"lookback",
|
||||||
"ch"
|
"$ch"
|
||||||
],
|
],
|
||||||
"tip": "Amount of time to lookback"
|
"tip": "Amount of time to lookback"
|
||||||
},
|
},
|
||||||
|
@ -271,7 +271,7 @@ class MainWindow(QtWidgets.QMainWindow):
|
|||||||
data /= 1000 # Given in mA
|
data /= 1000 # Given in mA
|
||||||
|
|
||||||
thermostat_param = inner_param.opts["param"]
|
thermostat_param = inner_param.opts["param"]
|
||||||
if thermostat_param[1] == "ch":
|
if thermostat_param[1] == "$ch":
|
||||||
thermostat_param[1] = ch
|
thermostat_param[1] = ch
|
||||||
|
|
||||||
if inner_param.name() == "rate" and data is None:
|
if inner_param.name() == "rate" and data is None:
|
||||||
@ -284,7 +284,7 @@ class MainWindow(QtWidgets.QMainWindow):
|
|||||||
|
|
||||||
if inner_param.opts.get("pid_autotune", None) is not None:
|
if inner_param.opts.get("pid_autotune", None) is not None:
|
||||||
auto_tuner_param = inner_param.opts["pid_autotune"][0]
|
auto_tuner_param = inner_param.opts["pid_autotune"][0]
|
||||||
if inner_param.opts["pid_autotune"][1] != "ch":
|
if inner_param.opts["pid_autotune"][1] != "$ch":
|
||||||
ch = inner_param.opts["pid_autotune"][1]
|
ch = inner_param.opts["pid_autotune"][1]
|
||||||
self.autotuners.set_params(auto_tuner_param, ch, data)
|
self.autotuners.set_params(auto_tuner_param, ch, data)
|
||||||
|
|
||||||
@ -293,7 +293,7 @@ class MainWindow(QtWidgets.QMainWindow):
|
|||||||
inner_param.reverse[0].index(data) # ListParameter.reverse = list of codename values
|
inner_param.reverse[0].index(data) # ListParameter.reverse = list of codename values
|
||||||
]
|
]
|
||||||
if activater is not None:
|
if activater is not None:
|
||||||
if activater[1] == "ch":
|
if activater[1] == "$ch":
|
||||||
activater[1] = ch
|
activater[1] = ch
|
||||||
await self.client.set_param(*activater)
|
await self.client.set_param(*activater)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user