Attached patch fixes some errors and missing attributes in the commandref.
Also these readings should be translated to english (but could break dependencies for these readings in existing installations):
--- 98_RandomTimer.pm (saved version)
+++ (current document)
@@ -323,8 +323,8 @@
RandomTimer_stopZeitErmitteln ($hash, $now);
readingsBeginUpdate($hash);
- readingsBulkUpdate ($hash, "Startzeit", FmtDateTime($hash->{helper}{startTime}));
- readingsBulkUpdate ($hash, "Stoppzeit", FmtDateTime($hash->{helper}{stopTime}));
+ readingsBulkUpdate ($hash, "StartTime", FmtDateTime($hash->{helper}{startTime}));
+ readingsBulkUpdate ($hash, "StopTime", FmtDateTime($hash->{helper}{stopTime}));
readingsEndUpdate ($hash, defined($hash->{LOCAL} ? 0 : 1));
}
Thx for the cref patch.
Most of the cref stuff has been changed (not the [], indicating optional arguments), and also the reading names. The original code with the german reading names has just been disabled, so in case anyone needs it for transitional purpose it can easily be enabled additionally to the new ones.
Thanks but <timeToSwitch> is a required parameter (see line 80)
Thx, will update that also :) .
This patch adds a reading LastCommand, which stores the last executed device command.
It's currently only logged to system log (with verbose 4).
--- - 2019-08-02 13:20:56.690576395 +0200
+++ /srv/fhem/FHEM/98_RandomTimer.pm 2019-08-02 10:36:06.298376369 +0200
@@ -173,6 +173,7 @@
}
$command =~ s/@/$hash->{DEVICE}/g;
$command = SemicolonEscape($command);
+ readingsSingleUpdate($hash, 'LastCommand', $command, 1);
Log3 $hash, 4, "[".$hash->{NAME}. "]"." command: $command";
my $ret = AnalyzeCommandChain(undef, $command);
Thx for the proposal :) .
Just commited it to svn.