From a3760ff771d932870dda13f2319b01d10a6ffb47 Mon Sep 17 00:00:00 2001 From: justme-1968 Date: Sun, 20 Mar 2016 09:56:05 +0000 Subject: [PATCH] 31_HUEDevice.pm: clip xy values to 0..1. to avoid error messages (by ares). this is not sufficent to clip to possible color space. git-svn-id: https://svn.fhem.de/fhem/trunk/fhem@11095 2b470e98-0d58-463d-a4d8-8e2adae1ed80 --- FHEM/31_HUEDevice.pm | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/FHEM/31_HUEDevice.pm b/FHEM/31_HUEDevice.pm index 58eceb01d..d15946ed2 100644 --- a/FHEM/31_HUEDevice.pm +++ b/FHEM/31_HUEDevice.pm @@ -432,6 +432,11 @@ HUEDevice_SetParam($$@) $Y = 1 if( $Y > 1 ); + $x = 0 if( $x < 0); + $x = 1 if( $x > 1); + $y = 0 if( $y < 0); + $y = 1 if( $y > 1); + my $bri = maxNum($r,$g,$b); #my $bri = $Y;