From 5cfc6c8d0efb534c32fe6ba30c52aedbbc53e607 Mon Sep 17 00:00:00 2001 From: LeonGaultier Date: Tue, 7 Jul 2020 08:54:34 +0000 Subject: [PATCH] 73_AutoShuttersControl: add condition in Fn EventProcessingGeneral to differentiate ASC device and other sensor device in NOTIFYDEV git-svn-id: https://svn.fhem.de/fhem/trunk@22366 2b470e98-0d58-463d-a4d8-8e2adae1ed80 --- fhem/CHANGED | 2 ++ fhem/FHEM/73_AutoShuttersControl.pm | 2 +- fhem/lib/FHEM/Automation/ShuttersControl.pm | 20 ++++++++++++-------- 3 files changed, 15 insertions(+), 9 deletions(-) diff --git a/fhem/CHANGED b/fhem/CHANGED index 4af3107e5..7da01c99c 100644 --- a/fhem/CHANGED +++ b/fhem/CHANGED @@ -1,5 +1,7 @@ # Add changes at the top of the list. Keep it in ASCII, and 80-char wide. # Do not insert empty lines here, update check depends on it. + - change: 73_AutoShuttersControl: add condition in Fn EventProcessingGeneral + to differentiate ASC device and other sensor device in NOTIFYDEV - change: 49_SSCam: new Zoom icons - bugfix: 72_XiaomiDevice: Vacuum segment names fix - feature: 51_MOBILEALERTS: Added Sensor MA 10238 diff --git a/fhem/FHEM/73_AutoShuttersControl.pm b/fhem/FHEM/73_AutoShuttersControl.pm index 667128616..58e3b1b8b 100644 --- a/fhem/FHEM/73_AutoShuttersControl.pm +++ b/fhem/FHEM/73_AutoShuttersControl.pm @@ -1253,7 +1253,7 @@ sub Initialize { ], "release_status": "testing", "license": "GPL_2", - "version": "v0.10.2", + "version": "v0.10.3", "author": [ "Marko Oldenburg " ], diff --git a/fhem/lib/FHEM/Automation/ShuttersControl.pm b/fhem/lib/FHEM/Automation/ShuttersControl.pm index 5dbad8bc6..ff35d9ec8 100644 --- a/fhem/lib/FHEM/Automation/ShuttersControl.pm +++ b/fhem/lib/FHEM/Automation/ShuttersControl.pm @@ -519,20 +519,24 @@ sub EventProcessingGeneral { while ( my ( $device, $deviceAttr ) = each %{ $hash->{monitoredDevs}{$devname} } ) { + if ( $devname eq $name ) { + EventProcessingResidents( $hash, $device, $events ) + if ( $deviceAttr eq 'ASC_residentsDev' ); + EventProcessingRain( $hash, $device, $events ) + if ( $deviceAttr eq 'ASC_rainSensor' ); + EventProcessingWind( $hash, $device, $events ) + if ( $deviceAttr eq 'ASC_windSensor' ); + EventProcessingTwilightDevice( $hash, $device, $events ) + if ( $deviceAttr eq 'ASC_twilightDevice' ); + } + EventProcessingWindowRec( $hash, $device, $events ) if ( $deviceAttr eq 'ASC_WindowRec' ) ; # ist es ein Fensterdevice wird die Funktion gestartet EventProcessingRoommate( $hash, $device, $events ) if ( $deviceAttr eq 'ASC_Roommate_Device' ) ; # ist es ein Bewohner Device wird diese Funktion gestartet - EventProcessingResidents( $hash, $device, $events ) - if ( $deviceAttr eq 'ASC_residentsDev' ); - EventProcessingRain( $hash, $device, $events ) - if ( $deviceAttr eq 'ASC_rainSensor' ); - EventProcessingWind( $hash, $device, $events ) - if ( $deviceAttr eq 'ASC_windSensor' ); - EventProcessingTwilightDevice( $hash, $device, $events ) - if ( $deviceAttr eq 'ASC_twilightDevice' ); + EventProcessingExternalTriggerDevice( $hash, $device, $events ) if ( $deviceAttr eq 'ASC_ExternalTrigger' );