Harmony Hub schaltet EnerGenieLan Sockets zu spät nach Activity Auswahl

Begonnen von sTaN, 02 November 2018, 12:42:40

Vorheriges Thema - Nächstes Thema

sTaN

Hallo liebe Community,

ich hoffe ihr könnt mir erneut einen hilfreichen Tipp geben.

Problembeschreibung:

Ich verwende zum Einen eine FS20 Funksteckdose für einen Dreifachverteiler an dem mein LG TV, Denon AVR und Subwoofer hängt.
Diese Funksteckdose schaltet bei jeder Harmony Aktivität ein und 10 Sekunden nach der Activity PowerOff wieder aus.

Weiterhin verwende ich eine EnerGenieLAN (EG-PM2-LAN) Steckdosenleiste an denen weitere Mulitmedia Gerät hängen. An Socket 1 = Amazon Fire TV, Socket 2 = Apple TV, Socket 3 = Xbox One und Socket 4 = Nintendo Switch.
Diese einzelnen Sockets sollen natürlich nur bei der entsprechenden Aktivität geschaltet werden. Dies klappt auch alleridngs viel zu spät und ich weiß leider nicht warum.

Folgende Mulitmedia_Automatik verwende ich:

#Auf den Schaltvorgang des Harmony Hubs reagieren
define Multimedia_Automatik DOIF ([harmonyhub:currentActivity] eq "Musik Sonos" and [?DayNight] eq "dawn") (set Media on;;set Sonos_Wohnzimmer StartFavourite MDR JUMP;;set Sonos_Wohnzimmer Volume 75;;set TVBacklight on)\
DOELSEIF ([harmonyhub:currentActivity] eq "Musik Sonos" and [?DayNight] eq "dusk") (set Media on;;set TVLampen on;;set Sonos_Wohnzimmer StartFavourite MDR&20JUMP;;set Sonos_Wohnzimmer Volume 75;;set TVLampen on)\
DOELSEIF ([harmonyhub:currentActivity] eq "Xbox One spielen" and [?DayNight] eq "dawn") (set Media on;;set XboxOne on;;set TVBacklight on)\
DOELSEIF ([harmonyhub:currentActivity] eq "Xbox One spielen" and [?DayNight] eq "dusk") (set Media on;;set XboxOne on;;set TVLampen on)\
DOELSEIF ([harmonyhub:currentActivity] eq "Nintendo Switch spielen" and [?DayNight] eq "dawn") (set Media on;;set NintendoSwitch on;;set TVBacklight on)\
DOELSEIF ([harmonyhub:currentActivity] eq "Nintendo Switch spielen" and [?DayNight] eq "dusk") (set Media on;;set NintendoSwitch on;;set TVLampen on)\
DOELSEIF ([harmonyhub:currentActivity] eq "Netflix/Amazon" and [?DayNight] eq "dawn") (set Media on;;set FireTV on;;set TVBacklight on)\
DOELSEIF ([harmonyhub:currentActivity] eq "Netflix/Amazon" and [?DayNight] eq "dusk") (set Media on;;set FireTV on;;set TVLampen on)\
DOELSEIF ([harmonyhub:currentActivity] eq "Apple TV sehen" and [?DayNight] eq "dawn") (set Media on;;set AppleTV on;;set TVBacklight on)\
DOELSEIF ([harmonyhub:currentActivity] eq "Apple TV sehen" and [?DayNight] eq "dusk") (set Media on;;set AppleTV on;;set TVLampen on)\
DOELSEIF ([harmonyhub:currentActivity] eq "Fernsehen" and [?DayNight] eq "dawn") (set Media on;;set TVBacklight on)\
DOELSEIF ([harmonyhub:currentActivity] eq "Fernsehen" and [?DayNight] eq "dusk") (set Media on;;set TVLampen on)\
DOELSEIF ([harmonyhub:currentActivity] !~ "PowerOff" and [?DayNight] eq "dawn") (set Media on)\
DOELSEIF ([harmonyhub:currentActivity] !~ "PowerOff" and [?DayNight] eq "dusk") (set Media on)\
DOELSEIF ([harmonyhub:currentActivity] eq "PowerOff" and [?DayNight] eq "dawn") (set Media off;;set FireTV off;;set AppleTV off;;set XboxOne off;;set NintendoSwitch off;;set TVBacklight off)\
DOELSEIF ([harmonyhub:currentActivity] eq "PowerOff" and [?DayNight] eq "dusk") (set Media off;;set FireTV off;;set AppleTV off;;set XboxOne off;;set NintendoSwitch off;;set TVLampen off)
attr Multimedia_Automatik wait 0:0:0:0:0:0:0:0:0:0:0:0:0:0:10:10


Das Attribut wait macht mit meiner FS20 Steckdose auch genau was es soll, nämlich erst nach 10 Sekunden den Strom weg nehmen, sodass alle Geräte bis dahin heruntergefahren werden. Beim Start einer Activity schaltet die FS20 Steckdose auch sofort an aber eben nicht die einzelnen Sockets des EnergieLAN.

Hat jemand eine Idee, wie ich das Problem in den Griff bekommen kann?

Vielen Dank und Grüße
sTaN
Raspberry Pi 3
2 x CUL CC1101-USB-Lite 868MHz
FS20 Komponenten, Philips HUE, Alexa-Fhem, MAX! Geräte, homebridge, harmony, Unifi, FirtzBox, MQTT, Aurora, Denon, Sonos, TabletUI, CALENDAR, EGPM2LAN, Pushover

Markus M.

Wenn du auf "Musik Sonos" reagierst, ist es schon zu spät.
Das passiert nämlich erst, wenn die Harmony Szene komplett durch ist.
Vorher sollte im Reading allerdings noch ein Wert bei start/stop vorbeikommen, hier z.B. "starting Musik Sonos".
Wenn du auf den reagierst und in der Harmony Szene noch eine entsprechende Verzögerung einbaust, klappt es.
FHEM dev + HomeBridge + Lenovo Flex15 + HM-CFG-USB + RFXtrx433 + Fritz!Box 7590/7580/546E

HM Aktor/Sensor/Winmatic/Keymatic/Thermostat, HUE, Netatmo Weather/Security/Heating, Xiaomi AirPurifier/Vacuum, Withings Aura/BPM/Cardio/Go/Pulse/Thermo, VSX828, Harmony, Siro ERB15LE
https://paypal.me/mm0

sTaN

Oh man! So einfach kann es sein. Klar macht absolut Sinn. Und die FS20 Steckdose hat immer funktioniert, weil ich vor ca. 2 Jahren auf die Aktivity ungleich PowerOff geprüft habe, die natürlich immer greift.
Aber durch das Einsetzen der EnerGenie LAN pro Gerät macht das natürlich keinen Sinn mehr.
Hab es jetzt wie folgt geändert und es funktioniert auch:

([harmonyhub:currentActivity] eq "starting Musik Sonos" and [?DayNight] eq "dawn") (set Media on;set Sonos_Wohnzimmer StartFavourite MDR JUMP;set Sonos_Wohnzimmer Volume 75;set TVBacklight on)
DOELSEIF ([harmonyhub:currentActivity] eq "starting Musik Sonos" and [?DayNight] eq "dusk") (set Media on;set TVLampen on;set Sonos_Wohnzimmer StartFavourite MDR&20JUMP;set Sonos_Wohnzimmer Volume 75;set TVLampen on)
DOELSEIF ([harmonyhub:currentActivity] eq "starting Xbox One spielen" and [?DayNight] eq "dawn") (set Media on;set XboxOne on;set TVBacklight on)
DOELSEIF ([harmonyhub:currentActivity] eq "starting Xbox One spielen" and [?DayNight] eq "dusk") (set Media on;set XboxOne on;set TVLampen on)
DOELSEIF ([harmonyhub:currentActivity] eq "starting Nintendo Switch spielen" and [?DayNight] eq "dawn") (set Media on;set NintendoSwitch on;set TVBacklight on)
DOELSEIF ([harmonyhub:currentActivity] eq "starting Nintendo Switch spielen" and [?DayNight] eq "dusk") (set Media on;set NintendoSwitch on;set TVLampen on)
DOELSEIF ([harmonyhub:currentActivity] eq "starting Netflix/Amazon" and [?DayNight] eq "dawn") (set Media on;set FireTV on;set TVBacklight on)
DOELSEIF ([harmonyhub:currentActivity] eq "starting Netflix/Amazon" and [?DayNight] eq "dusk") (set Media on;set FireTV on;set TVLampen on)
DOELSEIF ([harmonyhub:currentActivity] eq "starting Apple TV sehen" and [?DayNight] eq "dawn") (set Media on;set AppleTV on;set TVBacklight on)
DOELSEIF ([harmonyhub:currentActivity] eq "starting Apple TV sehen" and [?DayNight] eq "dusk") (set Media on;set AppleTV on;set TVLampen on)
DOELSEIF ([harmonyhub:currentActivity] eq "starting Fernsehen" and [?DayNight] eq "dawn") (set Media on;set TVBacklight on)
DOELSEIF ([harmonyhub:currentActivity] eq "starting Fernsehen" and [?DayNight] eq "dusk") (set Media on;set TVLampen on)
DOELSEIF ([harmonyhub:currentActivity] eq "PowerOff" and [?DayNight] eq "dawn") (set Media off;set FireTV off;set AppleTV off;set XboxOne off;set NintendoSwitch off;set TVBacklight off)
DOELSEIF ([harmonyhub:currentActivity] eq "PowerOff" and [?DayNight] eq "dusk") (set Media off;set FireTV off;set AppleTV off;set XboxOne off;set NintendoSwitch off;set TVLampen off)


Allerdings noch eine kleine Frage. Ich versuche bei der Activity Musik Sonos einen Standard Radio Sender zu starten. Dies klappt aber vermutlich aufgrund dem Leerzeichen im Namen "MDR Jump" nicht. Wie ist hier die korrekte Syntax?

[harmonyhub:currentActivity] eq "starting Musik Sonos" and [?DayNight] eq "dawn") (set Media on;set Sonos_Wohnzimmer StartFavourite MDR JUMP;set Sonos_Wohnzimmer Volume 75;set TVBacklight on)

Ich hatte es mit MDR&20Jump probiert und ich meine das klappte in der Vergangenheit auch mal. Aber schon eine Weile nicht mehr:

[harmonyhub:currentActivity] eq "starting Musik Sonos" and [?DayNight] eq "dusk") (set Media on;set TVLampen on;set Sonos_Wohnzimmer StartFavourite MDR&20JUMP;set Sonos_Wohnzimmer Volume 75;set TVLampen on)

Gruß
sTaN
Raspberry Pi 3
2 x CUL CC1101-USB-Lite 868MHz
FS20 Komponenten, Philips HUE, Alexa-Fhem, MAX! Geräte, homebridge, harmony, Unifi, FirtzBox, MQTT, Aurora, Denon, Sonos, TabletUI, CALENDAR, EGPM2LAN, Pushover