medling
Hi,
I have an max thermostat basic, that works, but I want to use an other temperature sensor for it.
So i decided to use my oregon temperature sensor (slaapkamertemp)
Slaapkamertemp
2020-06-06 19:54:19 humidity 36.00
2020-06-06 19:54:19 temperature 19.40
2020-06-06 19:54:19 temperatuur 19.4
the max thermostat basic is MAX_130261
This is in
##############################################
# $Id: myUtilsTemplate.pm 21509 2020-03-25 11:20:51Z rudolfkoenig $
#
# Save this file as 99_myUtils.pm, and create your own functions in the new
# file. They are then available in every Perl expression.
package main;
use strict;
use warnings;
sub
myUtils_Initialize($$)
{
my ($hash) = @_;
}
# Enter you functions below _this_ line.
sub MaxFakeWallThermostat($$)
{
my ($heizung, $aktTemp) = @_;
my $CULMAX = $defs{$heizung}{LASTInputDev};
my $desiredTemp = ReadingsVal($heizung, "desiredTemperature", undef);
my $windowOpenTemp = ReadingsVal($heizung, "windowOpenTemperature", undef);
my $lastTemp = ReadingsVal($heizung, "LastExtTemperature", 0);
my $lastSet = ReadingsTimestamp($heizung, "LastExtTemperature", 0);
if($desiredTemp && $windowOpenTemp &&
$desiredTemp != $windowOpenTemp &&
(time()-time_str2num($lastSet) >= 600 || abs($aktTemp-$lastTemp)>=0.2 )) {
Log 3, "set $CULMAX fakeWT $heizung $desiredTemp $aktTemp";
readingsSingleUpdate($defs{$heizung}, "LastExtTemperature", $aktTemp, 0);
fhem("set $CULMAX fakeWT $heizung $desiredTemp $aktTemp");
}
}
and did a notify
define SendExtTemp notify Slaapkamertemp:temperatuur.* {\
MaxFakeWallThermostat("MAX_130261", $EVTPART1);;\
}
I ony get an error
2020.06.06 22:06:17 3: CM_Parse, unhandled message WakeUp from MAX_130261 to MAX_111111, groupid : 0 , payload : 03 - ignoring !
2020.06.06 22:06:17 3: CULMAX, target device 111111 has no name !