2
0
mirror of https://github.com/fhem/fhem-mirror.git synced 2025-03-03 16:56:54 +00:00

CUL_HM: RGB support

git-svn-id: https://svn.fhem.de/fhem/trunk@10901 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
martinp876 2016-02-21 14:08:39 +00:00
parent cb6ff262c6
commit 8a5b9a65a2
2 changed files with 27 additions and 10 deletions

View File

@ -4437,12 +4437,17 @@ sub CUL_HM_Set($@) {#+++++++++++++++++ set command+++++++++++++++++++++++++++++
elsif($cmd eq "brightAuto") { ###############################################
my (undef,undef,$bright,$colProg,$min,$max,$duration,$ramp) = @a; #date prepared extention to entdate
return "please enter the duration in seconds"
if (!defined $duration || $duration !~ m/^[+-]?\d+(\.\d+)?$/);
my $tval = CUL_HM_encodeTime16($duration);# onTime 0.0..85825945.6, 0=forever
$ramp = CUL_HM_encodeTime16($ramp);
if (defined $duration && $duration !~ m/^[+-]?\d+(\.\d+)?$/);
return "at least bright and colorprogramm need to be set" if (!defined $colProg);
my $tval;
$tval = (!defined $duration) ? "" : CUL_HM_encodeTime16($duration);# onTime 0.0..85825945.6, 0=forever
$ramp = (!defined $ramp) ? "" : CUL_HM_encodeTime16($ramp) ;
$min = (!defined $min) ? "" : sprintf("%02X",$min) ;
$max = (!defined $max) ? "" : sprintf("%02X",$max) ;
CUL_HM_PushCmdStack($hash,'++'.$flag.'11'.$id.$dst.'81'.$chn.
sprintf("%02X%02X%02X%02X",$bright,$colProg,$min,$max).$ramp.$tval);
sprintf("%02X%02X",$bright,$colProg).$min.$max.$ramp.$tval);
}
elsif($cmd eq "playTone") { #################################################
my $msg;

View File

@ -460,16 +460,28 @@ sub HMinfo_peerCheck(@) { #####################################################
if ($pMd !~ m/HM-CC-RT-DN/ ||$pChn !~ m/(0[45])$/ ){
push @peeringStrange,$eName." pID: Model $pMd should be HM-CC-RT-DN ClimatTeam Channel";
}
elsif($chn eq "04"){
# compare templist template are identical and boost is same
my $rtCn = CUL_HM_id2Name(substr($pId,0,6)."04");
Log 1,"General $eName peered with $rtCn rt/rt";
}
}
elsif($chn eq "02" &&
($pChn ne "02" ||$pMd ne "HM-TC-IT-WM-W-EU" )){
push @peeringStrange,$eName." pID: Model $pMd should be HM-TC-IT-WM-W-EU Climate Channel";
elsif($chn eq "02"){
if($pChn ne "02" ||$pMd ne "HM-TC-IT-WM-W-EU" ){
push @peeringStrange,$eName." pID: Model $pMd should be HM-TC-IT-WM-W-EU Climate Channel";
}
}
}
elsif ($md eq "HM-TC-IT-WM-W-EU"){
if($chn eq "02" &&
($pChn ne "02" ||$pMd ne "HM-CC-RT-DN" )){
push @peeringStrange,$eName." pID: Model $pMd should be HM-TC-IT-WM-W-EU Climate Channel";
if($chn eq "02"){
if($pChn ne "02" ||$pMd ne "HM-CC-RT-DN" ){
push @peeringStrange,$eName." pID: Model $pMd should be HM-TC-IT-WM-W-EU Climate Channel";
}
else{
# compare templist template are identical and boost is same
my $rtCn = CUL_HM_id2Name(substr($pId,0,6)."04");
Log 1,"General $eName peered with $rtCn tc/rt";
}
}
}
}