From: Othmar Gsenger Date: Thu, 16 Feb 2012 18:19:03 +0000 (+0000) Subject: added fernbedieung weiss X-Git-Url: https://git.realraum.at/?a=commitdiff_plain;h=5ccd4dd424319aa11a5688fc5cb208e0c5ba5c14;p=svn42.git added fernbedieung weiss --- diff --git a/rf433rcv/pc/realraum_codes.pl b/rf433rcv/pc/realraum_codes.pl index 774d6df..3b03b14 100755 --- a/rf433rcv/pc/realraum_codes.pl +++ b/rf433rcv/pc/realraum_codes.pl @@ -4,8 +4,8 @@ use strict; my %remotes = ( schwarz => [\&schwarz, "01110101a1b1c1000000dddd"] , - weiss => \&weiss, - pollin => \&pollin, + weiss => [\&weiss,"0c0d01010b0001010001010a"], + pollin => [\&pollin,"010101010100010101010001"], ); &main(); @@ -38,7 +38,23 @@ sub schwarz sub weiss { - + my ($switch,$taste,$on) = @_ or die "parameters {a|b|c|d} {1|2} {0|1}"; + my $data = { + a=> ($on?'1':'0'), + b=> ($taste==1?'0':'1'), + c=>0, + d=>0, + }; + if($switch eq 'b') + { + $data->{c}=1; + } elsif ($switch eq 'c') { + $data->{d}=1; + } elsif ($switch eq 'd') { + $data->{c}=1; + $data->{d}=1; + } + return $data; } sub pollin