mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-04-08 13:24:56 +00:00
MAX: move removeDevice into factoryReset
git-svn-id: https://svn.fhem.de/fhem/trunk@2280 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
c35bbb865b
commit
44b72d75dc
@ -680,6 +680,7 @@ sub
|
|||||||
MAXLAN_RemoveDevice($$)
|
MAXLAN_RemoveDevice($$)
|
||||||
{
|
{
|
||||||
my ($hash,$addr) = @_;
|
my ($hash,$addr) = @_;
|
||||||
|
#This does a factoryReset on the Device
|
||||||
return MAXLAN_Write($hash,"t:1,1,".encode_base64(pack("H6",$addr),""), "A:");
|
return MAXLAN_Write($hash,"t:1,1,".encode_base64(pack("H6",$addr),""), "A:");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -197,14 +197,6 @@ MAX_Set($@)
|
|||||||
$comfort,$eco,$max,$min,$offset,$windowOpenTemp,$windowOpenTime);
|
$comfort,$eco,$max,$min,$offset,$windowOpenTemp,$windowOpenTime);
|
||||||
return ($hash->{IODev}{SendDeviceCmd})->($hash->{IODev},$payload);
|
return ($hash->{IODev}{SendDeviceCmd})->($hash->{IODev},$payload);
|
||||||
|
|
||||||
}elsif($setting eq "removeDevice") {
|
|
||||||
return "Cannot set without IODev" if(!defined($hash->{IODev}));
|
|
||||||
if(exists($hash->{IODev}{RemoveDevice})) {
|
|
||||||
return ($hash->{IODev}{RemoveDevice})->($hash->{IODev},$hash->{addr});
|
|
||||||
} else {
|
|
||||||
return "IODev does not need removeDevice";
|
|
||||||
}
|
|
||||||
|
|
||||||
} elsif($setting eq "displayActualTemperature" and $hash->{type} eq "WallMountedThermostat") {
|
} elsif($setting eq "displayActualTemperature" and $hash->{type} eq "WallMountedThermostat") {
|
||||||
return "Cannot set without IODev" if(!exists($hash->{IODev}));
|
return "Cannot set without IODev" if(!exists($hash->{IODev}));
|
||||||
return "Invalid arg" if($args[0] ne "0" and $args[0] ne "1");
|
return "Invalid arg" if($args[0] ne "0" and $args[0] ne "1");
|
||||||
@ -229,8 +221,14 @@ MAX_Set($@)
|
|||||||
return ($hash->{IODev}{SendDeviceCmd})->($hash->{IODev},$payload);
|
return ($hash->{IODev}{SendDeviceCmd})->($hash->{IODev},$payload);
|
||||||
|
|
||||||
} elsif($setting eq "factoryReset") {
|
} elsif($setting eq "factoryReset") {
|
||||||
my $payload = pack("CCCCCCH6C",0x00,0x00,0xF0,0x00,0x00,0x00,$hash->{addr}, 0);
|
if(exists($hash->{IODev}{RemoveDevice})) {
|
||||||
return ($hash->{IODev}{SendDeviceCmd})->($hash->{IODev},$payload);
|
#MAXLAN
|
||||||
|
return ($hash->{IODev}{RemoveDevice})->($hash->{IODev},$hash->{addr});
|
||||||
|
} else {
|
||||||
|
#CUL_MAXK
|
||||||
|
my $payload = pack("CCCCCCH6C",0x00,0x00,0xF0,0x00,0x00,0x00,$hash->{addr}, 0);
|
||||||
|
return ($hash->{IODev}{SendDeviceCmd})->($hash->{IODev},$payload);
|
||||||
|
}
|
||||||
|
|
||||||
} elsif($setting eq "wakeUp") {
|
} elsif($setting eq "wakeUp") {
|
||||||
my $payload = pack("CCCCCCH6CC",0x00,0x00,0xF1,0x00,0x00,0x00,$hash->{addr}, 0, 0x3F);
|
my $payload = pack("CCCCCCH6CC",0x00,0x00,0xF1,0x00,0x00,0x00,$hash->{addr}, 0, 0x3F);
|
||||||
@ -485,8 +483,6 @@ MAX_Parse($$)
|
|||||||
<li>groupid <id><br>
|
<li>groupid <id><br>
|
||||||
For devices of type HeatingThermostat only.
|
For devices of type HeatingThermostat only.
|
||||||
Writes the given group id the device's memory. It is usually not necessary to change this.</li>
|
Writes the given group id the device's memory. It is usually not necessary to change this.</li>
|
||||||
<li>removeDevice<br>
|
|
||||||
Removes the device from the cube, i.e. deletes the pairing.</li>
|
|
||||||
<li>ecoTemperature <value><br>
|
<li>ecoTemperature <value><br>
|
||||||
For devices of type HeatingThermostat only. Writes the given eco temperature to the device's memory. It can be activated by pressing the rightmost physical button on the device.</li>
|
For devices of type HeatingThermostat only. Writes the given eco temperature to the device's memory. It can be activated by pressing the rightmost physical button on the device.</li>
|
||||||
<li>comfortTemperature <value><br>
|
<li>comfortTemperature <value><br>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user