From e9950671679c6a064a0674d7a51f0178f287a94e Mon Sep 17 00:00:00 2001 From: jpawlowski Date: Sat, 6 Sep 2014 12:31:40 +0000 Subject: [PATCH] ENIGMA2: new attribute lightMode to limit load for old/slow devices git-svn-id: https://svn.fhem.de/fhem/trunk/fhem@6506 2b470e98-0d58-463d-a4d8-8e2adae1ed80 --- FHEM/70_ENIGMA2.pm | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/FHEM/70_ENIGMA2.pm b/FHEM/70_ENIGMA2.pm index 28b17c295..372cedbf4 100644 --- a/FHEM/70_ENIGMA2.pm +++ b/FHEM/70_ENIGMA2.pm @@ -24,7 +24,7 @@ # along with fhem. If not, see . # # -# Version: 1.3.5 +# Version: 1.3.6 # # Major Version History: # - 1.3.0 - 2013-12-21 @@ -78,7 +78,7 @@ sub ENIGMA2_Initialize($) { $hash->{UndefFn} = "ENIGMA2_Undefine"; $hash->{AttrList} = -"https:0,1 http-method:GET,POST disable:0,1 bouquet-tv bouquet-radio timeout remotecontrol:standard,advanced,keyboard " +"https:0,1 http-method:GET,POST disable:0,1 bouquet-tv bouquet-radio timeout remotecontrol:standard,advanced,keyboard lightMode:0,1 " . $readingFnAttributes; $data{RC_layout}{ENIGMA2_DreamMultimedia_DM500_DM800_SVG} = @@ -1100,7 +1100,8 @@ sub ENIGMA2_ReceiveCommand($$$) { $state = "off"; # Keep updating timer information during standby - ENIGMA2_SendCommand( $hash, "timerlist" ); + ENIGMA2_SendCommand( $hash, "timerlist" ) + if ( !AttrVal( $name, "lightMode", 0 ) ); } else { $state = "on"; @@ -1120,9 +1121,12 @@ sub ENIGMA2_ReceiveCommand($$$) { # get current states ENIGMA2_SendCommand( $hash, "getcurrent" ); - ENIGMA2_SendCommand( $hash, "timerlist" ); - ENIGMA2_SendCommand( $hash, "vol" ); - ENIGMA2_SendCommand( $hash, "signal" ); + ENIGMA2_SendCommand( $hash, "timerlist" ) + if ( !AttrVal( $name, "lightMode", 0 ) ); + ENIGMA2_SendCommand( $hash, "vol" ) + if ( !AttrVal( $name, "lightMode", 0 ) ); + ENIGMA2_SendCommand( $hash, "signal" ) + if ( !AttrVal( $name, "lightMode", 0 ) ); } } elsif ( defined( $hash->{helper}{AVAILABLE} ) @@ -2764,6 +2768,9 @@ sub ENIGMA2_GetRemotecontrolCommand($) {
  • https - Access box via secure HTTP (true/false)
  • +
  • + lightMode - reduces regular queries (resulting in less functionality), e.g. for low performance devices. (true/false) +
  • remotecontrol - Explicitly set specific remote control unit format. This will only be considered for set-command remoteControl as of now.