Skip to content

Commit a8e93e1

Browse files
committed
heater/heater+ also send temperature, sometimes
1 parent 4b24e69 commit a8e93e1

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

lib/Max.pm

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -138,6 +138,8 @@ sub _process_L {
138138
$temp |= !!($setpoint & 0x80) << 8;
139139
$setpoint &= 0x7F;
140140

141+
$temp = $date if $temp == 0 and $date > 0 and $device->has_temperature;
142+
141143
$device->_set(
142144
mode => $flags & 0x0003,
143145
setpoint => $setpoint / 2,

lib/Max/Device.pm

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ sub flags_as_string {
6969

7070
sub is_cube { $_[0]->{type} == 0 }
7171
sub has_valve { $_[0]->{type} == 1 or $_[0]->{type} == 2 }
72-
sub has_temperature { $_[0]->{type} == 3 }
72+
sub has_temperature { $_[0]->{type} >= 1 and $_[0]->{type} <= 3 }
7373
sub has_setpoint { $_[0]->{type} >= 1 and $_[0]->{type} <= 3 }
7474

7575
sub room {

0 commit comments

Comments
 (0)