From ded30c3484a0c2080aa90b90c60aaa0aff0f18f4 Mon Sep 17 00:00:00 2001 From: Vincent Date: Tue, 20 Apr 2021 11:10:55 +0200 Subject: [PATCH] . --- .idea/workspace.xml | 33 ++++++++++----------------------- config/coffee.php | 16 ++++++++-------- scripts/lib/scenes.php | 10 ++++++++-- 3 files changed, 26 insertions(+), 33 deletions(-) diff --git a/.idea/workspace.xml b/.idea/workspace.xml index 6cb04e6..31199d3 100644 --- a/.idea/workspace.xml +++ b/.idea/workspace.xml @@ -2,22 +2,9 @@ - - - - - - - - - - - - - + - diff --git a/config/coffee.php b/config/coffee.php index ff5220e..6229f74 100644 --- a/config/coffee.php +++ b/config/coffee.php @@ -1,12 +1,12 @@ 'light','scene'=>'cuisine/toaster/toggle', 'label' => 'Grille pain'], + ['type' => 'light', 'scene' => 'cuisine/toaster/toggle', 'label' => 'Grille pain'], ['type' => 'separator', 'label' => 'Machine à café'], - ['type' => 'ifttt', 'event' => 'coffee_on', 'label' => 'Allumer'], - ['type' => 'ifttt', 'event' => 'coffee_off', 'label' => 'éteindre'], - ['type' => 'separator', 'label' => 'Cafés'], - ['type' => 'ifttt', 'event' => 'coffee_vincent', 'label' => 'Vincent'], - ['type' => 'ifttt', 'event' => 'coffee_jerome', 'label' => 'Jérôme'], - ['type' => 'ifttt', 'event' => 'coffee_expresso', 'label' => 'Expresso'], - ['type' => 'ifttt', 'event' => 'coffee_americano', 'label' => 'Americano'], + ['type' => 'light', 'scene' => 'cuisine/coffee/on', 'label' => 'Allumer'], + ['type' => 'light', 'scene' => 'cuisine/coffee/off', 'label' => 'éteindre'], +// ['type' => 'separator', 'label' => 'Cafés'], +// ['type' => 'ifttt', 'event' => 'coffee_vincent', 'label' => 'Vincent'], +// ['type' => 'ifttt', 'event' => 'coffee_jerome', 'label' => 'Jérôme'], +// ['type' => 'ifttt', 'event' => 'coffee_expresso', 'label' => 'Expresso'], +// ['type' => 'ifttt', 'event' => 'coffee_americano', 'label' => 'Americano'], ]; \ No newline at end of file diff --git a/scripts/lib/scenes.php b/scripts/lib/scenes.php index 0377826..142e790 100644 --- a/scripts/lib/scenes.php +++ b/scripts/lib/scenes.php @@ -34,8 +34,8 @@ $scenes = [ ['type' => 'scene', 'scene' => 'chambre/planetarium/off'], ['type' => 'function', 'function' => 'bedbrightness', 'args' => [255]], ['type' => 'phonetask', 'phone' => 'vincent', 'task' => 'Matin'], - ['type' => 'function', 'function' => 'coffee_on'], ['type' => 'scene', 'scene' => 'chambre/auto', 'delay' => 35], + ['type' => 'scene', 'scene' => 'cuisine/coffee/on'], ], 'chambre/deshumidificateur/on' => [ //['type' => 'domoticz', 'device' => $chambrefan, 'command' => true], @@ -631,7 +631,7 @@ $scenes = [ ['type' => 'scene', 'scene' => 'chambre/deshumidificateur/on'], ['type' => 'phonetask', 'phone' => 'vincent', 'task' => 'Stop All Sounds'], ['type' => 'scene', 'scene' => 'chambre/planetarium/off'], - ['type' => 'function', 'function' => 'coffee_off'], + ['type' => 'scene', 'scene' => 'cuisine/coffee/off'], ['type' => 'scene', 'scene' => 'home/hueoff'], ['type' => 'scene', 'scene' => 'salon/media/off'], ['type' => 'scene', 'scene' => 'salon/off', 'delay' => 2], @@ -754,6 +754,12 @@ $scenes = [ 'cuisine/toaster/off' => [ ['type' => 'domoticz', 'device' => '1453', 'command' => false, 'priority' => true], ], + 'cuisine/coffee/on' => [ + ['type' => 'function', 'function' => 'coffee_on'], + ], + 'cuisine/coffee/off' => [ + ['type' => 'function', 'function' => 'coffee_off'], + ], 'cour/auto' => [ ['type' => 'domoticz', 'device' => '678', 'command' => true], ['type' => 'function', 'function' => 'courAuto', 'args' => [true]], -- 2.39.5