98_monitoring.pm: Document changes by Bety-User (Forum #125662)

git-svn-id: https://svn.fhem.de/fhem/trunk@25646 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
rudolfkoenig 2022-02-07 09:05:56 +00:00
parent a0586a5875
commit 80dd969ecd

View File

@ -566,20 +566,22 @@ sub monitoring_setInactive($) {
1; 1;
__END__
# commandref ################################################################## # commandref ##################################################################
=pod =pod
=item helper =item helper
=encoding utf8
=item summary monitors devices towards events and stores them in two lists =item summary monitors devices towards events and stores them in two lists
=item summary_DE überwacht Geräte auf Events und speichert diese in zwei Listen =item summary_DE überwacht Geräte auf Events und speichert diese in zwei Listen
=begin html =begin html
<a name="monitoring"></a> <a id="monitoring"></a>
<h3>monitoring</h3> <h3>monitoring</h3>
( en | <a href="commandref_DE.html#monitoring"><u>de</u></a> )
<div> <div>
<ul> <ul>
Each monitoring has a warning and an error list, which are stored Each <i>monitoring</i> has a <i>warning</i>- and an <i>error</i> list, which are stored
as readings. <br> as readings. <br>
When a defined add-event occurs, the device is set to the warning When a defined add-event occurs, the device is set to the warning
list after a predefined time.<br> list after a predefined time.<br>
@ -591,7 +593,7 @@ sub monitoring_setInactive($) {
formatted by two attributes.<br> formatted by two attributes.<br>
<br> <br>
The following applications are possible and are described The following applications are possible and are described
<a href="#monitoringexamples"><u>below</u></a>:<br> <a href="#monitoring-examples"><u>below</u></a>:<br>
<ul> <ul>
<li>opened windows</li> <li>opened windows</li>
<li>battery warnings</li> <li>battery warnings</li>
@ -606,14 +608,14 @@ sub monitoring_setInactive($) {
</li> </li>
</ul> </ul>
<br> <br>
The monitor does not send a message by itself, a notify or DOIF is The monitor does not send a message by itself, a <a href="#notify"><u>notify</u></a>
or <a href="#DOIF"><u>DOIF</u></a> is
necessary, which responds to the event "&lt;monitoring-name&gt; error necessary, which responds to the event "&lt;monitoring-name&gt; error
add: &lt;name&gt;" and then sends the return value of "get add: &lt;name&gt;" and then sends the return value of "get
&lt;monitoring-name&gt; default". &lt;monitoring-name&gt; default".
<br> <br>
<br> <a id="monitoring-define"></a>
<a name="monitoringdefine"></a> <h4>Define</h4>
<b>Define</b>
<ul> <ul>
<code> <code>
define &lt;name&gt; monitoring &lt;add-event&gt; [&lt;remove-event&gt;] define &lt;name&gt; monitoring &lt;add-event&gt; [&lt;remove-event&gt;]
@ -626,32 +628,31 @@ sub monitoring_setInactive($) {
both lists as it occurs and the timers for warning and error are both lists as it occurs and the timers for warning and error are
started.<br> started.<br>
</ul> </ul>
<br> <a id="monitoring-set"></a>
<a name="monitoringset"></a> <h4>Set</h4>
<b>Set</b>
<ul> <ul>
<li> <a id="monitoring-set-active"></a><li>
<code>active</code><br> <code>active</code><br>
Two things will happen:<br> Two things will happen:<br>
1. Restores pending timers, or sets the devices immediately to the 1. Restores pending timers, or sets the devices immediately to the
corresponding list if the time is in the past.<br> corresponding list if the time is in the past.<br>
2. Executes the commands specified under the "setActiveFunc" attribute. 2. Executes the commands specified under the "setActiveFunc" attribute.
</li> </li>
<li> <a id="monitoring-set-clear"></a><li>
<code>clear (warning|error|all)</code><br> <code>clear (warning|error|all)</code><br>
Removes all devices from the specified list and aborts timers for this Removes all devices from the specified list and aborts timers for this
list. With "all", all devices are removed from both lists and all list. With "all", all devices are removed from both lists and all
running timers are aborted. running timers are aborted.
</li> </li>
<li> <a id="monitoring-set-errorAdd"></a><li>
<code>errorAdd &lt;name&gt;</code><br> <code>errorAdd &lt;name&gt;</code><br>
Add &lt;name&gt; to the error list. Add &lt;name&gt; to the error list.
</li> </li>
<li> <a id="monitoring-set-errorRemove"></a><li>
<code>errorRemove &lt;name&gt;</code><br> <code>errorRemove &lt;name&gt;</code><br>
Removes &lt;name&gt; from the error list. Removes &lt;name&gt; from the error list.
</li> </li>
<li> <a id="monitoring-set-inactive"></a><li>
<code>inactive</code><br> <code>inactive</code><br>
Two things will happen:<br> Two things will happen:<br>
1. Executes the commands specified under the "setInactiveFunc" attribute.<br> 1. Executes the commands specified under the "setInactiveFunc" attribute.<br>
@ -659,45 +660,43 @@ sub monitoring_setInactive($) {
disable attribute: using set inactive the state is automatically saved disable attribute: using set inactive the state is automatically saved
to the statefile on shutdown, there is no explicit save necesary. to the statefile on shutdown, there is no explicit save necesary.
</li> </li>
<li> <a id="monitoring-set-warningAdd"></a><li>
<code>warningAdd &lt;name&gt;</code><br> <code>warningAdd &lt;name&gt;</code><br>
Add &lt;name&gt; to the warning list. Add &lt;name&gt; to the warning list.
</li> </li>
<li> <a id="monitoring-set-warningRemove"></a><li>
<code>warningRemove &lt;name&gt;</code><br> <code>warningRemove &lt;name&gt;</code><br>
Removes &lt;name&gt; from the warning list. Removes &lt;name&gt; from the warning list.
</li> </li>
</ul> </ul>
<br> <a id="monitoring-get"></a>
<a name="monitoringget"></a> <h4>Get</h4>
<b>Get</b>
<ul> <ul>
<li> <a id="monitoring-get-all"></a><li>
<code>all</code><br> <code>all</code><br>
Returns the error and warning list, separated by a blank line.<br> Returns the error and warning list, separated by a blank line.<br>
The formatting can be set with the attributes "errorReturn" and The formatting can be set with the attributes "errorReturn" and
"warningReturn". "warningReturn".
</li> </li>
<li> <a id="monitoring-get-default"></a><li>
<code>default</code><br> <code>default</code><br>
The "default" value can be set in the attribute "getDefault" and is The "default" value can be set in the attribute "getDefault" and is
intended to leave the configuration for the return value in the intended to leave the configuration for the return value in the
monitoring device. If nothing is specified "all" is used. monitoring device. If nothing is specified "all" is used.
</li> </li>
<li> <a id="monitoring-get-error"></a><li>
<code>error</code><br> <code>error</code><br>
Returns the error list.<br> Returns the error list.<br>
The formatting can be set with the attribute "errorReturn". The formatting can be set with the attribute "errorReturn".
</li> </li>
<li> <a id="monitoring-get-warning"></a><li>
<code>warning</code><br> <code>warning</code><br>
Returns the warning list.<br> Returns the warning list.<br>
The formatting can be set with the attribute "warningReturn". The formatting can be set with the attribute "warningReturn".
</li> </li>
</ul> </ul>
<br> <a id="monitoring-readings"></a>
<a name="monitoringreadings"></a> <h4>Readings</h4><br>
<b>Readings</b><br>
<ul> <ul>
<li> <li>
<code>allCount</code><br> <code>allCount</code><br>
@ -734,33 +733,32 @@ sub monitoring_setInactive($) {
Displays the amount of devices on the warning list. Displays the amount of devices on the warning list.
</li> </li>
</ul> </ul>
<br> <a id="monitoring-attr"></a>
<a name="monitoringattr"></a> <h4>Attributes</h4>
<b>Attribute</b>
<ul> <ul>
<li> <li>
<a href="#addStateEvent"> <a href="#addStateEvent">
<u><code>addStateEvent</code></u> <u><code>addStateEvent</code></u>
</a> </a>
</li> </li>
<li> <a id="monitoring-attr-blacklist"></a><li>
<code>blacklist</code><br> <code>blacklist</code><br>
Space-separated list of devspecs which will be ignored.<br> Space-separated list of devspecs which will be ignored.<br>
If the attribute is set all devices which are specified by the devspecs If the attribute is set all devices which are specified by the devspecs
are removed from both lists. are removed from both lists.
</li> </li>
<li> <a id="monitoring-attr-disable"></a><li>
<code>disable (1|0)</code><br> <code>disable (1|0)</code><br>
1: Executes the commands specified under the "setInactiveFunc" attribute 1: Executes the commands specified under the "setInactiveFunc" attribute
and disables the monitoring.<br> and disables the monitoring.<br>
        0: see "set active" 0: see "set active"
</li> </li>
<li> <li>
<a href="#disabledForIntervals"> <a href="#disabledForIntervals">
<u><code>disabledForIntervals HH:MM-HH:MM HH:MM-HH-MM ...</code></u> <u><code>disabledForIntervals HH:MM-HH:MM HH:MM-HH-MM ...</code></u>
</a> </a>
</li> </li>
<li> <a id="monitoring-attr-errorFuncAdd"></a><li>
<code>errorFuncAdd {&lt;perl code&gt;}</code><br> <code>errorFuncAdd {&lt;perl code&gt;}</code><br>
The following variables are available in this function: The following variables are available in this function:
<br> <br>
@ -792,7 +790,7 @@ sub monitoring_setInactive($) {
If the attribute is not set, it will be checked for If the attribute is not set, it will be checked for
<code>$addMatch</code>. <code>$addMatch</code>.
</li> </li>
<li> <a id="monitoring-attr-errorFuncAdded"></a><li>
<code>errorFuncAdded {&lt;perl code&gt;}</code><br> <code>errorFuncAdded {&lt;perl code&gt;}</code><br>
The following variables are available in this function: The following variables are available in this function:
<br> <br>
@ -808,7 +806,7 @@ sub monitoring_setInactive($) {
</ul> </ul>
This function will be executed when a device is added to the error list. This function will be executed when a device is added to the error list.
</li> </li>
<li> <a id="monitoring-attr-errorFuncRemove"></a><li>
<code>errorFuncRemove {&lt;perl code&gt;}</code><br> <code>errorFuncRemove {&lt;perl code&gt;}</code><br>
This function provides the same variables as for "errorFuncAdd".<br> This function provides the same variables as for "errorFuncAdd".<br>
If the function returns a 1, the device is removed from the error list If the function returns a 1, the device is removed from the error list
@ -818,11 +816,11 @@ sub monitoring_setInactive($) {
<code>&lt;remove-event&gt;</code> in the DEF, otherwise it will be <code>&lt;remove-event&gt;</code> in the DEF, otherwise it will be
checked for <code>errorFuncAdd</code>. checked for <code>errorFuncAdd</code>.
</li> </li>
<li> <a id="monitoring-attr-errorWait"></a><li>
<code>errorWait &lt;perl code&gt;</code><br> <code>errorWait &lt;perl code&gt;</code><br>
Wait until the device is set to the error list. Code returning waiting time (in seconds) until the device is set to the error list.
</li> </li>
<li> <a id="monitoring-attr-errorReturn"></a><li>
<code>errorReturn {&lt;perl code&gt;}</code><br> <code>errorReturn {&lt;perl code&gt;}</code><br>
The following variables are available in this attribute: The following variables are available in this attribute:
<ul> <ul>
@ -842,41 +840,46 @@ sub monitoring_setInactive($) {
With this attribute the output created with "get &lt;name&gt; error" With this attribute the output created with "get &lt;name&gt; error"
can be formatted. can be formatted.
</li> </li>
<li> <a id="monitoring-attr-getDefault"></a><li>
<code>getDefault (all|error|warning)</code><br> <code>getDefault (all|error|warning)</code><br>
This attribute can be used to specify which list(s) are / are returned This attribute can be used to specify which list(s) are / are returned
by "get &lt;name&gt; default". If the attribute is not set, "all" will by "get &lt;name&gt; default". If the attribute is not set, "all" will
be used. be used.
</li> </li>
<li> <a id="monitoring-attr-setActiveFunc"></a><li>
<code>setActiveFunc &lt;Anweisung&gt;</code><br> <code>setActiveFunc &lt;statement&gt;</code><br>
The statement is one of the FHEM command types and is executed when you The statement is one of the FHEM command types and is executed when you
define the monitoring or "set active".<br> define the monitoring or "set active".<br>
For a battery message <code>"trigger battery=low battery: low"</code> For a battery message <code>"trigger battery=low battery: low"</code>
can be useful. can be useful.
</li> </li>
<li> <a id="monitoring-attr-setInactiveFunc"></a><li>
<code>setInactiveFunc &lt;statement&gt;</code><br>
The statement is one of the FHEM command types and is executed when you
define the monitoring or "set inactive".
</li>
<a id="monitoring-attr-warningFuncAdd"></a><li>
<code>warningFuncAdd {&lt;perl code&gt;}</code><br> <code>warningFuncAdd {&lt;perl code&gt;}</code><br>
Like errorFuncAdd, just for the warning list. Like errorFuncAdd, just for the warning list.
</li> </li>
<li> <a id="monitoring-attr-warningFuncAdded"></a><li>
<code>warningFuncAdd {&lt;perl code&gt;}</code><br> <code>warningFuncAdded {&lt;perl code&gt;}</code><br>
Like errorFuncAdded, just for the warning list. Like errorFuncAdded, just for the warning list.
</li> </li>
<li> <a id="monitoring-attr-warningFuncRemove"></a><li>
<code>warningFuncRemove {&lt;perl code&gt;}</code><br> <code>warningFuncRemove {&lt;perl code&gt;}</code><br>
Like errorFuncRemove, just for the warning list. Like errorFuncRemove, just for the warning list.
</li> </li>
<li> <a id="monitoring-attr-warningWait"></a><li>
<code>warningWait &lt;perl code&gt;</code><br> <code>warningWait &lt;perl code&gt;</code><br>
Like errorWait, just for the warning list. Like errorWait, just for the warning list.
</li> </li>
<li> <a id="monitoring-attr-warningReturn"></a><li>
<code>warningReturn {&lt;perl code&gt;}</code><br> <code>warningReturn {&lt;perl code&gt;}</code><br>
Like errorReturn, just for the warning list. Like errorReturn, just for the warning list.
</li> </li>
<li> <a id="monitoring-attr-whitelist"></a><li>
<code>whitelist {&lt;perl code&gt;}</code><br> <code>whitelist {&lt;devspec list&gt;}</code><br>
Space-separated list of devspecs which are allowed.<br> Space-separated list of devspecs which are allowed.<br>
If the attribute is set all devices which are not specified by the If the attribute is set all devices which are not specified by the
devspecs are removed from both lists. devspecs are removed from both lists.
@ -887,9 +890,8 @@ sub monitoring_setInactive($) {
</a> </a>
</li> </li>
</ul> </ul>
<br> <a id="monitoring-examples"></a>
<a name="monitoringexamples"></a> <h4>Examples</h4>
<b>Examples</b>
<ul> <ul>
<a href="https://wiki.fhem.de/wiki/Import_von_Code_Snippets"> <a href="https://wiki.fhem.de/wiki/Import_von_Code_Snippets">
<u>The following sample codes can be imported via "Raw definition".</u> <u>The following sample codes can be imported via "Raw definition".</u>
@ -1073,24 +1075,23 @@ attr BeamerFilter_monitoring warningFuncRemove {return}</pre>
=begin html_DE =begin html_DE
<a name="monitoring"></a> <a id="monitoring"></a>
<h3>monitoring</h3> <h3>monitoring</h3>
( <a href="commandref.html#monitoring"><u>en</u></a> | de )
<div> <div>
<ul> <ul>
Jedes monitoring verf&uuml;gt &uuml;ber eine warning- und eine error-Liste, Jedes <i>monitoring</i> verfügt über eine <i>warning</i>- und eine <i>error</i>-Liste,
welche als Readings gespeichert werden.<br> welche als Readings gespeichert werden.<br>
Beim auftreten eines definierten add-events wird das Ger&auml;t nach einer Beim Auftreten eines definierten add-events wird das Ger&auml;t nach einer
vorgegeben Zeit auf die warning-Liste gesetzt.<br> vorgegeben Zeit auf die warning-Liste gesetzt.<br>
Nach einer weiteren vorgegeben Zeit wird das Ger&auml;t von der Nach einer weiteren vorgegeben Zeit wird das Ger&auml;t von der
warning-Liste gel&ouml;scht und auf die error-Liste gesetzt.<br> warning-Liste gel&ouml;scht und auf die error-Liste gesetzt.<br>
Beim auftreten eines definierten remove-events wird das Ger&auml;t von Beim Auftreten eines definierten remove-events wird das Ger&auml;t von
beiden Listen gel&ouml;scht und noch laufende Timer abgebrochen.<br> beiden Listen gel&ouml;scht und noch laufende Timer abgebrochen.<br>
Hiermit lassen sich auf einfache Weise Sammelmeldungen erstellen und durch Hiermit lassen sich auf einfache Weise Sammelmeldungen erstellen und durch
zwei Attribute formatiert ausgeben.<br> zwei Attribute formatiert ausgeben.<br>
<br> <br>
Folgende Anwendungen sind m&ouml;glich und werden Folgende Anwendungen sind m&ouml;glich und werden
<a href="#monitoringexamples"><u>unten</u></a> beschrieben:<br> <a href="#monitoring-examples"><u>unten</u></a> beschrieben:<br>
<ul> <ul>
<li>ge&ouml;ffnete Fenster</li> <li>ge&ouml;ffnete Fenster</li>
<li>Batterie Warnungen</li> <li>Batterie Warnungen</li>
@ -1105,14 +1106,13 @@ attr BeamerFilter_monitoring warningFuncRemove {return}</pre>
</li> </li>
</ul> </ul>
<br> <br>
Das monitor sendet selbst keine Benachrichtung, hierf&uuml;r ist ein notify Das monitor sendet selbst keine Benachrichtung, hierf&uuml;r ist ein <a href="#notify"><u>notify</u></a>
oder DOIF notwendig, welches auf das Event "&lt;monitoring-name&gt; error oder <a href="#DOIF"><u>DOIF</u></a> notwendig, welches auf das Event "&lt;monitoring-name&gt; error
add: &lt;name&gt;" reagiert und dann den R&uuml;ckgabewert von add: &lt;name&gt;" reagiert und dann den R&uuml;ckgabewert von
"get &lt;monitoring-name&gt; default" versendet. "get &lt;monitoring-name&gt; default" versendet.
<br> <br>
<br> <a id="monitoring-define"></a>
<a name="monitoringdefine"></a> <h4>Define</h4>
<b>Define</b>
<ul> <ul>
<code> <code>
define &lt;name&gt; monitoring &lt;add-event&gt; [&lt;remove-event&gt;] define &lt;name&gt; monitoring &lt;add-event&gt; [&lt;remove-event&gt;]
@ -1120,17 +1120,16 @@ attr BeamerFilter_monitoring warningFuncRemove {return}</pre>
<br> <br>
Die Syntax f&uuml;r &lt;add-event&gt; und &lt;remove-event&gt; ist die Die Syntax f&uuml;r &lt;add-event&gt; und &lt;remove-event&gt; ist die
gleiche wie f&uuml;r das Suchmuster von gleiche wie f&uuml;r das Suchmuster von
<a href="commandref_DE.html#notify"><u>notify</u></a> (Ger&auml;tename <a href="#notify"><u>notify</u></a> (Ger&auml;tename
oder Ger&auml;tename:Event).<br> oder Ger&auml;tename:Event).<br>
Ist nur ein &lt;add-event&gt; definiert wird beim auftreten das Ist nur ein &lt;add-event&gt; definiert wird beim auftreten das
Ger&auml;t von beiden Listen gel&ouml;scht und die Timer f&uuml;r warning Ger&auml;t von beiden Listen gel&ouml;scht und die Timer f&uuml;r warning
und error werden gestartet.<br> und error werden gestartet.<br>
</ul> </ul>
<br> <a id="monitoring-set"></a>
<a name="monitoringset"></a> <h4>Set</h4>
<b>Set</b>
<ul> <ul>
<li> <a id="monitoring-set-active"></a><li>
<code>active</code><br> <code>active</code><br>
Es passieren zwei Dinge:<br> Es passieren zwei Dinge:<br>
1. Stellt noch ausstehende Timer wieder her, bzw. setzt die Ger&auml;te 1. Stellt noch ausstehende Timer wieder her, bzw. setzt die Ger&auml;te
@ -1139,70 +1138,68 @@ attr BeamerFilter_monitoring warningFuncRemove {return}</pre>
2. F&uuml;hrt die unter dem Attribut "setActiveFunc" angegeben Befehle 2. F&uuml;hrt die unter dem Attribut "setActiveFunc" angegeben Befehle
aus. aus.
</li> </li>
<li> <a id="monitoring-set-clear"></a><li>
<code>clear (warning|error|all)</code><br> <code>clear (warning|error|all)</code><br>
Entfernt alle Ger&auml;te von der angegeben Liste und bricht f&uuml;r Entfernt alle Ger&auml;te von der angegeben Liste und bricht f&uuml;r
diese Liste laufende Timer ab. Bei "all" werden alle Ger&auml;te von diese Liste laufende Timer ab. Bei "all" werden alle Ger&auml;te von
beiden Listen entfernt und alle laufenden Timer abgebrochen. beiden Listen entfernt und alle laufenden Timer abgebrochen.
</li> </li>
<li> <a id="monitoring-set-errorAdd"></a><li>
<code>errorAdd &lt;name&gt;</code><br> <code>errorAdd &lt;name&gt;</code><br>
F&uuml;gt &lt;name&gt; zu der error-Liste hinzu. F&uuml;gt &lt;name&gt; zu der error-Liste hinzu.
</li> </li>
<li> <a id="monitoring-set-errorRemove"></a><li>
<code>errorRemove &lt;name&gt;</code><br> <code>errorRemove &lt;name&gt;</code><br>
Entfernt &lt;name&gt; von der error-Liste. Entfernt &lt;name&gt; von der error-Liste.
</li> </li>
<li> <a id="monitoring-set-inactive"></a><li>
<code>inactive</code><br> <code>inactive</code><br>
Deaktiviert das monitoring. Beachte den leichten semantischen Deaktiviert das monitoring. Beachte den leichten semantischen
Unterschied zum disable Attribut: "set inactive" wird bei einem Unterschied zum disable Attribut: "set inactive" wird bei einem
shutdown automatisch in fhem.state gespeichert, es ist kein save shutdown automatisch in fhem.state gespeichert, es ist kein save
notwendig. notwendig.
</li> </li>
<li> <a id="monitoring-set-warningAdd"></a><li>
<code>warningAdd &lt;name&gt;</code><br> <code>warningAdd &lt;name&gt;</code><br>
F&uuml;gt &lt;name&gt; zu der warning-Liste hinzu. F&uuml;gt &lt;name&gt; zu der warning-Liste hinzu.
</li> </li>
<li> <a id="monitoring-set-warningRemove"></a><li>
<code>warningRemove &lt;name&gt;</code><br> <code>warningRemove &lt;name&gt;</code><br>
Entfernt &lt;name&gt; von der warning-Liste. Entfernt &lt;name&gt; von der warning-Liste.
</li> </li>
</ul> </ul>
<br> <a id="monitoring-get"></a>
<a name="monitoringget"></a> <h4>Get</h4>
<b>Get</b>
<ul> <ul>
<li> <a id="monitoring-get-all"></a><li>
<code>all</code><br> <code>all</code><br>
Gibt, durch eine Leerzeile getrennt, die error- und warning-Liste Gibt, durch eine Leerzeile getrennt, die error- und warning-Liste
zur&uuml;ck.<br> zur&uuml;ck.<br>
Die Formatierung kann dabei mit den Attributen "errorReturn" und Die Formatierung kann dabei mit den Attributen "errorReturn" und
"warningReturn" eingestellt werden. "warningReturn" eingestellt werden.
</li> </li>
<li> <a id="monitoring-get-default"></a><li>
<code>default</code><br> <code>default</code><br>
Der "default" Wert kann in dem Attribut "getDefault" festgelegt werden Der "default" Wert kann in dem Attribut "getDefault" festgelegt werden
und ist dazu gedacht um die Konfiguration f&uuml;r den und ist dazu gedacht um die Konfiguration f&uuml;r den
R&uuml;ckgabewert im monitoring Ger&auml;t zu belassen. Wird nichts R&uuml;ckgabewert im monitoring Ger&auml;t zu belassen. Wird nichts
angegeben wird "all" verwendent. angegeben wird "all" verwendent.
</li> </li>
<li> <a id="monitoring-get-error"></a><li>
<code>error</code><br> <code>error</code><br>
Gibt die error-Liste zur&uuml;ck.<br> Gibt die error-Liste zur&uuml;ck.<br>
Die Formatierung kann dabei mit dem Attribut "errorReturn" eingestellt Die Formatierung kann dabei mit dem Attribut "errorReturn" eingestellt
werden. werden.
</li> </li>
<li> <a id="monitoring-get-warning"></a><li>
<code>warning</code><br> <code>warning</code><br>
Gibt die warning-Liste zur&uuml;ck.<br> Gibt die warning-Liste zur&uuml;ck.<br>
Die Formatierung kann dabei mit dem Attribut "warningReturn" Die Formatierung kann dabei mit dem Attribut "warningReturn"
eingestellt werden. eingestellt werden.
</li> </li>
</ul> </ul>
<br> <a id="monitoring-readings"></a>
<a name="monitoringreadings"></a> <h4>Readings</h4>
<b>Readings</b><br>
<ul> <ul>
<li> <li>
<code>allCount</code><br> <code>allCount</code><br>
@ -1241,22 +1238,21 @@ attr BeamerFilter_monitoring warningFuncRemove {return}</pre>
Zeigt die Anzahl der Geräte in der warning-Liste an. Zeigt die Anzahl der Geräte in der warning-Liste an.
</li> </li>
</ul> </ul>
<br> <a id="monitoring-attr"></a>
<a name="monitoringattr"></a> <h4>Attribute</h4>
<b>Attribute</b>
<ul> <ul>
<li> <li>
<a href="#addStateEvent"> <a href="#addStateEvent">
<u><code>addStateEvent</code></u> <u><code>addStateEvent</code></u>
</a> </a>
</li> </li>
<li> <a id="monitoring-attr-blacklist"></a><li>
<code>blacklist</code><br> <code>blacklist</code><br>
Durch Leerzeichen getrennte Liste von devspecs die ignoriert werden.<br> Durch Leerzeichen getrennte Liste von devspecs die ignoriert werden.<br>
Wenn das Attribut gesetzt wird werden alle Geräte die durch die Wenn das Attribut gesetzt wird werden alle Geräte die durch die
devspecs definiert sind von beiden Listen gelöscht. devspecs definiert sind von beiden Listen gelöscht.
</li> </li>
<li> <a id="monitoring-attr-disable"></a><li>
<code>disable (1|0)</code><br> <code>disable (1|0)</code><br>
1: Deaktiviert das monitoring.<br> 1: Deaktiviert das monitoring.<br>
0: siehe "set active" 0: siehe "set active"
@ -1266,7 +1262,7 @@ attr BeamerFilter_monitoring warningFuncRemove {return}</pre>
<u><code>disabledForIntervals HH:MM-HH:MM HH:MM-HH-MM ...</code></u> <u><code>disabledForIntervals HH:MM-HH:MM HH:MM-HH-MM ...</code></u>
</a> </a>
</li> </li>
<li> <a id="monitoring-attr-errorFuncAdd"></a><li>
<code>errorFuncAdd {&lt;perl code&gt;}</code><br> <code>errorFuncAdd {&lt;perl code&gt;}</code><br>
In dieser Funktion stehen die folgende Variablen zur Verf&uuml;gung: In dieser Funktion stehen die folgende Variablen zur Verf&uuml;gung:
<br> <br>
@ -1298,7 +1294,7 @@ attr BeamerFilter_monitoring warningFuncRemove {return}</pre>
Wenn das Attribut nicht gesetzt ist wird auf <code>$addMatch</code> Wenn das Attribut nicht gesetzt ist wird auf <code>$addMatch</code>
gepr&uuml;ft. gepr&uuml;ft.
</li> </li>
<li> <a id="monitoring-attr-errorFuncAdded"></a><li>
<code>errorFuncAdded {&lt;perl code&gt;}</code><br> <code>errorFuncAdded {&lt;perl code&gt;}</code><br>
In dieser Funktion stehen die folgende Variablen zur Verf&uuml;gung: In dieser Funktion stehen die folgende Variablen zur Verf&uuml;gung:
<br> <br>
@ -1314,7 +1310,7 @@ attr BeamerFilter_monitoring warningFuncRemove {return}</pre>
</ul> </ul>
Diese Funktion wird ausgeführt, wenn ein Gerät in die Fehlerliste aufgenommen wird. Diese Funktion wird ausgeführt, wenn ein Gerät in die Fehlerliste aufgenommen wird.
</li> </li>
<li> <a id="monitoring-attr-errorFuncRemove"></a><li>
<code>errorFuncRemove {&lt;perl code&gt;}</code><br> <code>errorFuncRemove {&lt;perl code&gt;}</code><br>
In dieser Funktion stehen die selben Variablen wie bei "errorFuncAdd" In dieser Funktion stehen die selben Variablen wie bei "errorFuncAdd"
zur Verf&uuml;gung.<br> zur Verf&uuml;gung.<br>
@ -1325,11 +1321,11 @@ attr BeamerFilter_monitoring warningFuncRemove {return}</pre>
gepr&uuml;ft und bei einer DEF ohne <code>&lt;remove-event&gt;</code> gepr&uuml;ft und bei einer DEF ohne <code>&lt;remove-event&gt;</code>
auf <code>errorFuncAdd</code>. auf <code>errorFuncAdd</code>.
</li> </li>
<li> <a id="monitoring-attr-errorWait"></a><li>
<code>errorWait &lt;perl code&gt;</code><br> <code>errorWait &lt;perl code&gt;</code><br>
Wartezeit bis das Ger&auml;t auf die error-Liste gesetzt wird. Wartezeit (Rückgabe in Sekunden) bis das Ger&auml;t auf die error-Liste gesetzt wird.
</li> </li>
<li> <a id="monitoring-attr-errorReturn"></a><li>
<code>errorReturn {&lt;perl code&gt;}</code><br> <code>errorReturn {&lt;perl code&gt;}</code><br>
In diesem Attribut stehen folgende Variablen zur Verf&uuml;gung: In diesem Attribut stehen folgende Variablen zur Verf&uuml;gung:
<ul> <ul>
@ -1349,41 +1345,48 @@ attr BeamerFilter_monitoring warningFuncRemove {return}</pre>
Mit diesem Attribut kann die Ausgabe die mit "get &lt;name&gt; error" Mit diesem Attribut kann die Ausgabe die mit "get &lt;name&gt; error"
erzeugt wird angepasst werden. erzeugt wird angepasst werden.
</li> </li>
<li> <a id="monitoring-attr-getDefault"></a><li>
<code>getDefault (all|error|warning)</code><br> <code>getDefault (all|error|warning)</code><br>
Mit diesem Attribut kann festgelegt werden welche Liste/n mit "get Mit diesem Attribut kann festgelegt werden welche Liste/n mit "get
&lt;name&gt; default" zur&uuml;ck gegeben wird/werden. Wenn das &lt;name&gt; default" zur&uuml;ck gegeben wird/werden. Wenn das
Attribut nicht gesetzt ist wird "all" verwendet. Attribut nicht gesetzt ist wird "all" verwendet.
</li> </li>
<li> <a id="monitoring-attr-setActiveFunc"></a><li>
<code>setActiveFunc &lt;Anweisung&gt;</code><br> <code>setActiveFunc &lt;Anweisung&gt;</code><br>
Die Anweisung ist einer der FHEM Die Anweisung ist einer der FHEM
<a href="#command"><u>Befehlstypen</u></a> und wird beim definieren des <a href="#command"><u>Befehlstypen</u></a> und wird beim Definieren des
monitoring oder bei "set active" ausgef&uuml;hrt.<br> monitoring oder bei "set active" ausgef&uuml;hrt.<br>
F&uuml;r eine Batterie Meldung kann <code>"trigger battery=low F&uuml;r eine Batterie Meldung kann <code>"trigger battery=low
battery:low"</code> sinnvoll sein. battery:low"</code> sinnvoll sein.
</li> </li>
<li> <a id="monitoring-attr-setInactiveFunc"></a><li>
<code>setInactiveFunc &lt;Anweisung&gt;</code><br>
Die Anweisung ist einer der FHEM
<a href="#command"><u>Befehlstypen</u></a> und wird beim Definieren des
monitoring oder bei "set inactive" ausgeführt.
</li>
<a id="monitoring-attr-warningFuncAdd"></a><li>
<code>warningFuncAdd {&lt;perl code&gt;}</code><br> <code>warningFuncAdd {&lt;perl code&gt;}</code><br>
Wie errorFuncAdd, nur f&uuml;r die warning-Liste. Wie errorFuncAdd, nur f&uuml;r die warning-Liste.
</li> </li>
<li> <a id="monitoring-attr-warningFuncAdded"></a><li>
<code>warningFuncAdded {&lt;perl code&gt;}</code><br> <code>warningFuncAdded {&lt;perl code&gt;}</code><br>
Wie errorFuncAdded, nur f&uuml;r die warning-Liste. Wie errorFuncAdded, nur f&uuml;r die warning-Liste.
</li> </li>
<li> <a id="monitoring-attr-warningFuncRemove"></a><li>
<code>warningFuncRemove {&lt;perl code&gt;}</code><br> <code>warningFuncRemove {&lt;perl code&gt;}</code><br>
Wie errorFuncRemove, nur f&uuml;r die warning-Liste. Wie errorFuncRemove, nur f&uuml;r die warning-Liste.
</li> </li>
<li> <a id="monitoring-attr-warningWait"></a><li>
<code>warningWait &lt;perl code&gt;</code><br> <code>warningWait &lt;perl code&gt;</code><br>
Wie errorWait, nur f&uuml;r die warning-Liste. Wie errorWait, nur f&uuml;r die warning-Liste.
</li> </li>
<li> <a id="monitoring-attr-warningReturn"></a><li>
<code>warningReturn {&lt;perl code&gt;}</code><br> <code>warningReturn {&lt;perl code&gt;}</code><br>
Wie errorReturn, nur f&uuml;r die warning-Liste. Wie errorReturn, nur f&uuml;r die warning-Liste.
</li> </li>
<li> <a id="monitoring-attr-whitelist"></a><li>
<code>whitelist {&lt;perl code&gt;}</code><br> <code>whitelist {&lt;perl code&gt;}</code><br>
Durch Leerzeichen getrennte Liste von devspecs die erlaubt sind Durch Leerzeichen getrennte Liste von devspecs die erlaubt sind
werden.<br> werden.<br>
@ -1396,9 +1399,8 @@ attr BeamerFilter_monitoring warningFuncRemove {return}</pre>
</a> </a>
</li> </li>
</ul> </ul>
<br> <a id="monitoring-examples"></a>
<a name="monitoringexamples"></a> <h4>Beispiele</h4>
<b>Beispiele</b>
<ul> <ul>
<a href="https://wiki.fhem.de/wiki/Import_von_Code_Snippets"> <a href="https://wiki.fhem.de/wiki/Import_von_Code_Snippets">
<u> <u>