WeekDayTimer und FHEM 5.7

Begonnen von P.A.Trick, 11 November 2015, 20:05:20

Vorheriges Thema - Nächstes Thema

P.A.Trick

Ich habe bereits den Feature Level von FHEM auf 5.7 umgestellt und meine Konfiguration von @ und % bereinigt.
Dabei ist mir aufgefallen, dass mein Weekdaytimer nicht mehr funktioniert.
Das Ḿodul nutzt scheinbar noch @ und %. Ich würde mich freuen, wenn das Modul dahingehend korrigiert wird!

015.11.11 19:51:06.309 3: [wdt_sync_server] set wdt_sync_server enable
2015.11.11 19:52:00.006 5: [wdt_sync_server] list of window sensors found: 'wdt_sync_server'
2015.11.11 19:52:00.012 4: [wdt_sync_server] Update   - timer seems to be active today: 0123456|19:52|on
2015.11.11 19:52:00.024 4: [wdt_sync_server] device type dummy: recognized, setModifier:
2015.11.11 19:52:00.025 4: [wdt_sync_server] aktParam: newParam:on - is  not disabled
2015.11.11 19:52:00.026 4: [wdt_sync_server] command: set @  % executed
2015.11.11 19:52:00.050 3: Please define @ first


Hier noch mein List:

Internals:
   DEF        sync_server 0123456|19:52|on 0123456|18:00|off
   DEVICE     sync_server
   GlobalDaylistSpec
   LANGUAGE   de
   NAME       wdt_sync_server
   NR         1157
   Profil 0: Sonntag 18:00:00 off, 19:52:00 on
   Profil 1: Montag 18:00:00 off, 19:52:00 on
   Profil 2: Dienstag 18:00:00 off, 19:52:00 on
   Profil 3: Mittwoch 18:00:00 off, 19:52:00 on
   Profil 4: Donnerstag 18:00:00 off, 19:52:00 on
   Profil 5: Freitag 18:00:00 off, 19:52:00 on
   Profil 6: Samstag 18:00:00 off, 19:52:00 on
   STATE      on
   STILLDONETIME 0
   TYPE       WeekdayTimer
   Readings:
     2015-11-11 19:51:06   disabled        0
     2015-11-11 19:52:00   nextUpdate      2015-11-12 18:00:00
     2015-11-11 19:52:00   nextValue       off
     2015-11-11 19:52:00   state           on
   SWITCHINGTIMES:
     0123456|19:52|on
     0123456|18:00|off
   Timer:
     Wdt_sync_server_1:
       HASH       wdt_sync_server
       MODIFIER   1
       NAME       wdt_sync_server_1
     Wdt_sync_server_settimerofday:
       HASH       wdt_sync_server
       MODIFIER   SetTimerOfDay
       NAME       wdt_sync_server_SetTimerOfDay
   Daynumber:
     !$we       8
     $we        7
     di         2
     do         4
     fr         5
     mi         3
     mo         1
     sa         6
     so         0
   Helper:
     daysRegExp (so|mo|di|mi|do|fr|sa|\$we|\!\$we)
     daysRegExpMessage (so|mo|di|mi|do|fr|sa|$we|!$we)
     Switchingtime:
       0:
         18:00:00   off
         19:52:00   on
       1:
         18:00:00   off
         19:52:00   on
       2:
         18:00:00   off
         19:52:00   on
       3:
         18:00:00   off
         19:52:00   on
       4:
         18:00:00   off
         19:52:00   on
       5:
         18:00:00   off
         19:52:00   on
       6:
         18:00:00   off
         19:52:00   on
     Bm:
       Weekdaytimer_attr:
         cnt        1
         dmx        0
         mAr
         max        0
         tot        0
       Weekdaytimer_get:
         cnt        6
         dmx        0
         mAr
         max        0
         tot        0
       Weekdaytimer_set:
         cnt        20
         dmx        0
         mAr
         max        0
         tot        0
   Longdays:
     de:
       Sonntag
       Montag
       Dienstag
       Mittwoch
       Donnerstag
       Freitag
       Samstag
       Wochenende
       Werktags
     en:
       Sunday
       Monday
       Tuesday
       Wednesday
       Thursday
       Friday
       Saturday
       weekend
       weekdays
     fr:
       Dimanche
       Lundi
       Mardi
       Mercredi
       Jeudi
       Vendredi
       Samedi
       weekend
       jours de la semaine
   Profil:
     1:
       EPOCH      1447267920
       PARA       on
       TIME       19:52
       TAGE:
         0
         1
         2
         3
         4
         5
         6
     2:
       EPOCH      1447261200
       PARA       off
       TIME       18:00
       TAGE:
         0
         1
         2
         3
         4
         5
         6
   Profile_idx:
     0:
       18:00:00   2
       19:52:00   1
     1:
       18:00:00   2
       19:52:00   1
     2:
       18:00:00   2
       19:52:00   1
     3:
       18:00:00   2
       19:52:00   1
     4:
       18:00:00   2
       19:52:00   1
     5:
       18:00:00   2
       19:52:00   1
     6:
       18:00:00   2
       19:52:00   1
   Shortdays:
     de:
       so
       mo
       di
       mi
       do
       fr
       sa
       $we
       !$we
     en:
       su
       mo
       tu
       we
       th
       fr
       sa
       $we
       !$we
     fr:
       di
       lu
       ma
       me
       je
       ve
       sa
       $we
       !$we
Attributes:
   disable    0
   group      PC
   room       _Cron
   verbose    5 [/code

Vielen Dank im Voraus!
Cubietruck,RPI,QNAP Ts-419p+, FS20, FRITZ!DECT200, 7 MAX! Thermostate, 3 MAX! Fensterkontakte, Kodi, CUL V3.3, EM1000S, LW12, LD382, HUE, HM-CFG-USB-2, 1x HM-LC-SW1-FM, 2x HM-LC-SW2-FM, 2x HM-LC-Sw1PBU-FM, 3xHM-LC-Bl1PBU-FM,HM-SEC-RHS, 2xHM-SEC-SD,HM-WDS30-T-O, 3x HM-LC-Dim1TPBU-FM, RPI+AddOn

Dietmar63

Ich habe eine Version erstellt, die das Problem korrigiert. Kann ich dir das Modul zum Betatest zukommen lassen?
Gruß Dietmar
FB7390, CUL, 2 FHT, FS20
modules: 98_WOL.pm, 98_Heating_Control.pm,   98_WeekdayTimer.pm, 98_RandomTimer.pm, 59_Twilight.pm

P.A.Trick

Cubietruck,RPI,QNAP Ts-419p+, FS20, FRITZ!DECT200, 7 MAX! Thermostate, 3 MAX! Fensterkontakte, Kodi, CUL V3.3, EM1000S, LW12, LD382, HUE, HM-CFG-USB-2, 1x HM-LC-SW1-FM, 2x HM-LC-SW2-FM, 2x HM-LC-Sw1PBU-FM, 3xHM-LC-Bl1PBU-FM,HM-SEC-RHS, 2xHM-SEC-SD,HM-WDS30-T-O, 3x HM-LC-Dim1TPBU-FM, RPI+AddOn

P.A.Trick

Cubietruck,RPI,QNAP Ts-419p+, FS20, FRITZ!DECT200, 7 MAX! Thermostate, 3 MAX! Fensterkontakte, Kodi, CUL V3.3, EM1000S, LW12, LD382, HUE, HM-CFG-USB-2, 1x HM-LC-SW1-FM, 2x HM-LC-SW2-FM, 2x HM-LC-Sw1PBU-FM, 3xHM-LC-Bl1PBU-FM,HM-SEC-RHS, 2xHM-SEC-SD,HM-WDS30-T-O, 3x HM-LC-Dim1TPBU-FM, RPI+AddOn

Dietmar63

habe übersehen dass du geantwortet hattest.
ich bin mir im Moment etwas unsicher, wie es richtig wäre den Befehl zu gestalten.

Zur Zeit habe ich folgendes definiert:
$command = "set %NAME " . $setModifier . " %EVENT";
glaube aber dass folgendes richtig ist:
$command = "set $NAME " . $setModifier . " $EVENT";

Weiterhin möchte ich keinen Ärger mit denen, die selbst den Code mit
{fhem("set @ desired %")}

ergänzt haben.
 
Gruß Dietmar
FB7390, CUL, 2 FHT, FS20
modules: 98_WOL.pm, 98_Heating_Control.pm,   98_WeekdayTimer.pm, 98_RandomTimer.pm, 59_Twilight.pm

Dietmar63

habe es eingebaut und grob gecheckt - gebe aber frühestens morgen frei, weil ich noch etwas mehr machen musste und weiter testen will.
Gruß Dietmar
FB7390, CUL, 2 FHT, FS20
modules: 98_WOL.pm, 98_Heating_Control.pm,   98_WeekdayTimer.pm, 98_RandomTimer.pm, 59_Twilight.pm

P.A.Trick

Cubietruck,RPI,QNAP Ts-419p+, FS20, FRITZ!DECT200, 7 MAX! Thermostate, 3 MAX! Fensterkontakte, Kodi, CUL V3.3, EM1000S, LW12, LD382, HUE, HM-CFG-USB-2, 1x HM-LC-SW1-FM, 2x HM-LC-SW2-FM, 2x HM-LC-Sw1PBU-FM, 3xHM-LC-Bl1PBU-FM,HM-SEC-RHS, 2xHM-SEC-SD,HM-WDS30-T-O, 3x HM-LC-Dim1TPBU-FM, RPI+AddOn

Dietmar63

habe eine Version eingecheckt - bitte mal testen
Gruß Dietmar
FB7390, CUL, 2 FHT, FS20
modules: 98_WOL.pm, 98_Heating_Control.pm,   98_WeekdayTimer.pm, 98_RandomTimer.pm, 59_Twilight.pm

P.A.Trick

2015.11.17 19:19:00.007 5: [wdt_sync_server] list of window sensors found: 'wdt_sync_server'
2015.11.17 19:19:00.013 4: [wdt_sync_server] Update   - timer seems to be active today: 0123456|19:19|on
2015.11.17 19:19:00.025 4: [wdt_sync_server] device type dummy: recognized, setModifier:
2015.11.17 19:19:00.026 4: [wdt_sync_server] aktParam: newParam:on - is  not disabled
2015.11.17 19:19:00.028 4: [wdt_sync_server] command: set $NAME  $EVENT executed


Klappt vielen Dank!
Cubietruck,RPI,QNAP Ts-419p+, FS20, FRITZ!DECT200, 7 MAX! Thermostate, 3 MAX! Fensterkontakte, Kodi, CUL V3.3, EM1000S, LW12, LD382, HUE, HM-CFG-USB-2, 1x HM-LC-SW1-FM, 2x HM-LC-SW2-FM, 2x HM-LC-Sw1PBU-FM, 3xHM-LC-Bl1PBU-FM,HM-SEC-RHS, 2xHM-SEC-SD,HM-WDS30-T-O, 3x HM-LC-Dim1TPBU-FM, RPI+AddOn

det.

Hallo Dietmar,
Kann es sein, das
ToreAuf Mo-Fr|06:58|on Mo-Fr|06:59|off (!$we)

Nicht mehr funktioniert? Zumindest stand die Garage gestern (Feiertag) und heute (Urlaub) früh offen.
LG
det.

Dietmar63

Es wurden auf Jeden Fall Änderungen aktiv, die so etwas auslösen könnten.

!$we Sollte allerdings auch schon vorher Die Ausführung der Schaltung an Feiertagen (auch Urlaub) unterbunden haben

Setze mal verbose 5, dann kannst du im Log erkennen was passiert ist
Gruß Dietmar
FB7390, CUL, 2 FHT, FS20
modules: 98_WOL.pm, 98_Heating_Control.pm,   98_WeekdayTimer.pm, 98_RandomTimer.pm, 59_Twilight.pm

det.

Hallo Dietmar,
sorry, es funktioniert seit letztem Wochenende nicht mehr, (!$we) wird nicht ausgewertet.
noch mal die vollständige Definition:
define GARage WeekdayTimer ToreAuf  Mo-Fr|06:58|on  Mo-Fr|06:59|off  (!$we)
und die log Ausgaben auf verbose5 von letzter Nacht:
2015.11.20 00:00:05 4: [GARage] 07:08:51 17:12:14 Freitag
2015.11.20 00:00:05 4: [GARage] 06:58:00 on, 06:59:00 off (Profil 1: Montag)
2015.11.20 00:00:05 4: [GARage] 06:58:00 on, 06:59:00 off (Profil 2: Dienstag)
2015.11.20 00:00:05 4: [GARage] 06:58:00 on, 06:59:00 off (Profil 3: Mittwoch)
2015.11.20 00:00:05 4: [GARage] 06:58:00 on, 06:59:00 off (Profil 4: Donnerstag)
2015.11.20 00:00:05 4: [GARage] 06:58:00 on, 06:59:00 off (Profil 5: Freitag)
2015.11.20 00:00:05 4: [GARage] device type structure: recognized, setModifier:
2015.11.20 00:00:05 4: [GARage] setTimer - timer seems to be active today: 12345|06:58|on
2015.11.20 00:00:05 5: [GARage] setting  Timer: GARage_1 2015-11-20 06:58:00
2015.11.20 00:00:05 4: [GARage] setTimer - timer seems to be active today: 12345|06:59|off
2015.11.20 00:00:05 5: [GARage] setting  Timer: GARage_2 2015-11-20 06:59:00
2015.11.20 00:00:05 5: [GARage] removing Timer: GARage_SetTimerOfDay
2015.11.20 00:00:05 5: [GARage] setting  Timer: GARage_SetTimerOfDay 2015-11-21 00:00:05


2015.11.20 06:58:00 5: [GARage] list of window sensors found: 'GARage'
2015.11.20 06:58:00 4: [GARage] Update   - timer seems to be active today: 12345|06:58|on
2015.11.20 06:58:00 4: [GARage] device type structure: recognized, setModifier:
2015.11.20 06:58:00 4: [GARage] aktParam: newParam:on - is  not disabled
2015.11.20 06:58:00 4: [GARage] command: set $NAME  $EVENT executed
2015.11.20 06:59:00 5: [GARage] list of window sensors found: 'GARage'
2015.11.20 06:59:00 4: [GARage] Update   - timer seems to be active today: 12345|06:59|off
2015.11.20 06:59:00 4: [GARage] device type structure: recognized, setModifier:
2015.11.20 06:59:00 4: [GARage] aktParam: newParam:off - is  not disabled
2015.11.20 06:59:00 4: [GARage] command: set $NAME  $EVENT executed

und es ist heute ($we) wegen Urlaub
attr global holiday2we sachsen


LG
det.

Dietmar63

Gruß Dietmar
FB7390, CUL, 2 FHT, FS20
modules: 98_WOL.pm, 98_Heating_Control.pm,   98_WeekdayTimer.pm, 98_RandomTimer.pm, 59_Twilight.pm

Dietmar63

Zitat von: det. am 20 November 2015, 10:27:06
Hallo Dietmar,
sorry, es funktioniert seit letztem Wochenende nicht mehr, (!$we) wird nicht ausgewertet.
noch mal die vollständige Definition:
define GARage WeekdayTimer ToreAuf  Mo-Fr|06:58|on  Mo-Fr|06:59|off  (!$we)
und die log Ausgaben auf verbose5 von letzter Nacht:
2015.11.20 00:00:05 4: [GARage] 07:08:51 17:12:14 Freitag
2015.11.20 00:00:05 4: [GARage] 06:58:00 on, 06:59:00 off (Profil 1: Montag)
2015.11.20 00:00:05 4: [GARage] 06:58:00 on, 06:59:00 off (Profil 2: Dienstag)
2015.11.20 00:00:05 4: [GARage] 06:58:00 on, 06:59:00 off (Profil 3: Mittwoch)
2015.11.20 00:00:05 4: [GARage] 06:58:00 on, 06:59:00 off (Profil 4: Donnerstag)
2015.11.20 00:00:05 4: [GARage] 06:58:00 on, 06:59:00 off (Profil 5: Freitag)
2015.11.20 00:00:05 4: [GARage] device type structure: recognized, setModifier:
2015.11.20 00:00:05 4: [GARage] setTimer - timer seems to be active today: 12345|06:58|on
2015.11.20 00:00:05 5: [GARage] setting  Timer: GARage_1 2015-11-20 06:58:00
2015.11.20 00:00:05 4: [GARage] setTimer - timer seems to be active today: 12345|06:59|off
2015.11.20 00:00:05 5: [GARage] setting  Timer: GARage_2 2015-11-20 06:59:00
2015.11.20 00:00:05 5: [GARage] removing Timer: GARage_SetTimerOfDay
2015.11.20 00:00:05 5: [GARage] setting  Timer: GARage_SetTimerOfDay 2015-11-21 00:00:05


2015.11.20 06:58:00 5: [GARage] list of window sensors found: 'GARage'
2015.11.20 06:58:00 4: [GARage] Update   - timer seems to be active today: 12345|06:58|on
2015.11.20 06:58:00 4: [GARage] device type structure: recognized, setModifier:
2015.11.20 06:58:00 4: [GARage] aktParam: newParam:on - is  not disabled
2015.11.20 06:58:00 4: [GARage] command: set $NAME  $EVENT executed
2015.11.20 06:59:00 5: [GARage] list of window sensors found: 'GARage'
2015.11.20 06:59:00 4: [GARage] Update   - timer seems to be active today: 12345|06:59|off
2015.11.20 06:59:00 4: [GARage] device type structure: recognized, setModifier:
2015.11.20 06:59:00 4: [GARage] aktParam: newParam:off - is  not disabled
2015.11.20 06:59:00 4: [GARage] command: set $NAME  $EVENT executed

und es ist heute ($we) wegen Urlaub
attr global holiday2we sachsen

ich kann keinen Fehler feststellen, habe deine WD teilweise nachgestellt und zusätzichen output erzeugt. Ich gebe den WD nachher noch frei, :dann kannst du mal ein detailierteres Log erstellen, eventuell fällt dann auf was los ist.

define GARage                 WeekdayTimer Brunnen  Mo-Fr|20:16|on  Mo-Fr|20:17|off  ($we) ;


2015.11.23 20:17:00 3: ret---condition--------->0
2015.11.23 20:17:00 5: [GARage] condition: {my $days={};;map{$days->{$_}=1}(1,2,3,4,5);;;;( ($we) && (defined $days->{$wday}))}
2015.11.23 20:17:00 5: [GARage] list of window sensors found: 'GARage'
2015.11.23 20:16:00 3: ret---condition--------->0
2015.11.23 20:16:00 5: [GARage] condition: {my $days={};;map{$days->{$_}=1}(1,2,3,4,5);;;;( ($we) && (defined $days->{$wday}))}
2015.11.23 20:16:00 5: [GARage] list of window sensors found: 'GARage'
2015.11.23 20:15:22 5: [GARage] setting  Timer: GARage_2 2015-11-23 20:17:00
2015.11.23 20:15:22 4: [GARage] setTimer - timer seems to be NOT active today: 12345|20:17|off ($we)
2015.11.23 20:15:22 3: ret---condition--------->0
2015.11.23 20:15:22 5: [GARage] condition: {my $days={};;map{$days->{$_}=1}(1,2,3,4,5);;;;( ($we) && (defined $days->{$wday}))}
2015.11.23 20:15:22 5: [GARage] setting  Timer: GARage_1 2015-11-23 20:16:00
2015.11.23 20:15:22 4: [GARage] setTimer - timer seems to be NOT active today: 12345|20:16|on ($we)
2015.11.23 20:15:22 3: ret---condition--------->0
2015.11.23 20:15:22 5: [GARage] condition: {my $days={};;map{$days->{$_}=1}(1,2,3,4,5);;;;( ($we) && (defined $days->{$wday}))}
2015.11.23 20:15:22 4: [GARage] no switch in the yesterdays because of the devices type(Brunnen is not recognized as heating) - use attr switchInThePast
2015.11.23 20:15:22 4: [GARage] device type FS20: recognized, setModifier:
2015.11.23 20:15:22 5: [GARage] setting  Timer: GARage_SetTimerOfDay 2015-11-24 00:00:05
2015.11.23 20:15:22 5: [GARage] removing Timer: GARage_SetTimerOfDay
2015.11.23 20:15:22 4: [GARage] 20:16:00 on, 20:17:00 off (Profil 5: Freitag)
2015.11.23 20:15:22 4: [GARage] 20:16:00 on, 20:17:00 off (Profil 4: Donnerstag)
2015.11.23 20:15:22 4: [GARage] 20:16:00 on, 20:17:00 off (Profil 3: Mittwoch)
2015.11.23 20:15:22 4: [GARage] 20:16:00 on, 20:17:00 off (Profil 2: Dienstag)
2015.11.23 20:15:22 4: [GARage] 20:16:00 on, 20:17:00 off (Profil 1: Montag)
2015.11.23 20:15:22 4: [GARage] 07:16:24 16:56:13 Montag
2015.11.23 20:15:22 5: [GARage] removing Timer: GARage_2
2015.11.23 20:15:22 5: [GARage] removing Timer: GARage_1

Gruß Dietmar
FB7390, CUL, 2 FHT, FS20
modules: 98_WOL.pm, 98_Heating_Control.pm,   98_WeekdayTimer.pm, 98_RandomTimer.pm, 59_Twilight.pm

det.

Hallo Dietmar,
Danke, ich werde es weiter testen. Kann mir auch nicht erklären, warum das bis letztes Wochenende über die letzten Urlaubstage immer ging und danach am Urlaubstag und Feiertag die Garage aufstand. Kann es sein, das es nicht an Deinem Modul liegt, sondern die holiday2we Funktion seit 5.7 anders arbeitet, denn mit einem normalen Wochenende hab ich es ja nie getestet, da meine Definition Sa und So nicht beinhaltet?


LG
det.

Dietmar63

Schwer zu sagen. Bei einem Versionswechsel verändert sich immer ganz viel. Und @ und % stellen erhebliche Veränderungen dar. Ich gebe gleich die versprochene WD Version frei. Dann kannst du das Log untersuchen oder mir zur Verfügung stellen.
Gruß Dietmar
FB7390, CUL, 2 FHT, FS20
modules: 98_WOL.pm, 98_Heating_Control.pm,   98_WeekdayTimer.pm, 98_RandomTimer.pm, 59_Twilight.pm

det.

Hallo Dietmar,
gestern abend den heutigen Tag zum Feiertag erklärt und heute stand die Garage wie an normalen Wochentagen wieder offen.
2015.11.25 06:59:00 4: [GARage] aktParam: newParam:off - is not disabled
2015.11.25 06:59:00 4: [GARage] device type structure: recognized, setModifier:
2015.11.25 06:59:00 4: [GARage] Update - timer seems to be active today: 12345|06:59|off
2015.11.25 06:59:00 3: [GARage] result of condition:1
2015.11.25 06:59:00 5: [GARage] condition: {my $days={};;map{$days->{$_}=1}(1,2,3,4,5);;;;( (!$we) && (defined $days->{$wday}))}
2015.11.25 06:59:00 5: [GARage] list of window sensors found: 'GARage'
2015.11.25 06:58:00 4: [GARage] command: set $NAME $EVENT executed
2015.11.25 06:58:00 4: [GARage] aktParam: newParam:on - is not disabled
2015.11.25 06:58:00 4: [GARage] device type structure: recognized, setModifier:
2015.11.25 06:58:00 4: [GARage] Update - timer seems to be active today: 12345|06:58|on
2015.11.25 06:58:00 3: [GARage] result of condition:1
2015.11.25 06:58:00 5: [GARage] condition: {my $days={};;map{$days->{$_}=1}(1,2,3,4,5);;;;( (!$we) && (defined $days->{$wday}))}
2015.11.25 06:58:00 5: [GARage] list of window sensors found: 'GARage'

Ich tippe auf eine Fehlfunktion von die holiday2we. Hast Du einen Tip, wie ich das testen kann?
LG
det.

rudolfkoenig

{ $we } in der Eingabezeile tippen.

$we hat mit 5.7 generell nicht funktioniert, habe es gestern gefixt, nach einem update heute sollte das Problem behoben sein.

det.

Vielen Dank Rudolf! Dann sollte ja den kommenden Feiertagen nichts mehr im Wege stehen.
Ist wie im Leben - schnell wird ein Unschuldiger bezichtigt (sorry Dietmar) und muss dann beweisen, dass er zu den Guten gehört. Deine Module funktionieren prima, sowohl für die Heizungssteuerung als auch "zweckentfremdet". Danke!!!
LG
det.