forked from M-Labs/thermostat
Compare commits
2 Commits
085e3a5fd3
...
3eef7e9e37
Author | SHA1 | Date | |
---|---|---|---|
3eef7e9e37 | |||
ed9d067bee |
@ -229,6 +229,9 @@ class CtrlPanel(QObject):
|
||||
for pwm_params in pwm_data:
|
||||
channel = pwm_params["channel"]
|
||||
with QSignalBlocker(self.params[channel]):
|
||||
self.params[channel].child(
|
||||
"Output Config", "Polarity"
|
||||
).setValue(pwm_params["polarity"])
|
||||
self.params[channel].child(
|
||||
"Output Config", "Limits", "Max Voltage Difference"
|
||||
).setValue(pwm_params["max_v"]["value"])
|
||||
|
@ -18,6 +18,18 @@
|
||||
"expanded":true,
|
||||
"type":"group",
|
||||
"children":[
|
||||
{
|
||||
"name": "Polarity",
|
||||
"type": "list",
|
||||
"limits": {
|
||||
"Normal": "normal",
|
||||
"Reversed": "reversed"
|
||||
},
|
||||
"thermostat:set_param": {
|
||||
"topic": "pwm",
|
||||
"field": "polarity"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name":"Control Method",
|
||||
"type":"mutex",
|
||||
|
@ -124,7 +124,7 @@ class ThermostatSettingsMenu(QtWidgets.QMenu):
|
||||
self.actionAbout_Thermostat.triggered.connect(about_thermostat)
|
||||
self.addAction(self.actionAbout_Thermostat)
|
||||
|
||||
@pyqtSlot(dict)
|
||||
@pyqtSlot("QVariantMap")
|
||||
def fan_update(self, fan_settings):
|
||||
logging.debug(fan_settings)
|
||||
if fan_settings is None:
|
||||
@ -154,7 +154,7 @@ class ThermostatSettingsMenu(QtWidgets.QMenu):
|
||||
self.fan_pwm_warning.setPixmap(QtGui.QPixmap())
|
||||
self.fan_pwm_warning.setToolTip("")
|
||||
|
||||
@pyqtSlot(dict)
|
||||
@pyqtSlot("QVariantMap")
|
||||
def hw_rev(self, hw_rev):
|
||||
self.hw_rev_data = hw_rev
|
||||
self.fan_group.setEnabled(self.hw_rev_data["settings"]["fan_available"])
|
||||
|
Loading…
Reference in New Issue
Block a user