mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-04-16 16:56:04 +00:00
new mode "function"
git-svn-id: https://svn.fhem.de/fhem/trunk@3079 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
558cdb32a2
commit
aa50f1bb5d
@ -1,5 +1,7 @@
|
||||
# Add changes at the top of the list. Keep it in ASCII
|
||||
- SVN
|
||||
- feature: PRESENCE: new mode "function" to use own perl functions for
|
||||
presence checks
|
||||
- bugfix: fixing not-working FHEM restart, when a PRESENCE check is running
|
||||
- bugfix: fixing memory overflow when "list" a PRESENCE definition
|
||||
- bugfix: fixing dead PRESENCE definitions in case of timeouts
|
||||
|
@ -876,6 +876,7 @@ PRESENCE_ProcessAbortedScan($)
|
||||
<li><b>lan-ping</b> - A presence check of a device via network ping in your LAN/WLAN</li>
|
||||
<li><b>fritzbox</b> - A presence check by requesting the device state from the FritzBox internals (only available when running FHEM on a FritzBox!)</li>
|
||||
<li><b>local-bluetooth</b> - A presence check by searching directly for a given bluetooth device nearby</li>
|
||||
<li><b>function</b> - A presence check by using your own perl function which returns a presence status</li>
|
||||
<li><b>lan-bluetooth</b> - A presence check of a bluetooth device via LAN network by connecting to a presenced or collectord instance</li>
|
||||
</ul>
|
||||
<br><br>
|
||||
@ -896,6 +897,11 @@ PRESENCE_ProcessAbortedScan($)
|
||||
<br>
|
||||
Checks for a bluetooth device and reports its presence state. For this mode the shell command "hcitool" is required (provided with a <a href="http://www.bluez.org" target="_new">bluez</a> installation under Debian via APT), as well
|
||||
as a functional bluetooth device directly attached to your machine.<br><br>
|
||||
<b>Mode: function</b><br><br>
|
||||
<code>define <name> PRESENCE function {...} [ <check-interval> [ <present-check-interval> ] ]</code><br>
|
||||
<br>
|
||||
Checks for a presence state via perl-code. You can use a self-written perl function to obtain the presence state of a specific device (e.g. via SNMP check).<br><br>
|
||||
The function must return 0 (absent) or 1 (present).<br><br>
|
||||
<b>Mode: lan-bluetooth</b><br><br>
|
||||
Checks for a bluetooth device with the help of presenced or collectord. They can be installed where-ever you like, just must be accessible via network.
|
||||
The given device will be checked for presence status.<br>
|
||||
@ -1000,7 +1006,7 @@ Options:
|
||||
<a name="PRESENCEset"></a>
|
||||
<b>Set</b>
|
||||
<ul>
|
||||
<li><b>statusRequest</b> - (Only for local-bluetooth, lan-ping and fritzbox) - Schedules an immediatly check.</li>
|
||||
<li><b>statusRequest</b> - (Only for mode local-bluetooth, lan-ping, function and fritzbox) - Schedules an immediatly check.</li>
|
||||
</ul>
|
||||
<br>
|
||||
|
||||
@ -1069,6 +1075,7 @@ Options:
|
||||
<li><b>lan-ping</b> - Eine Erkennung auf Basis von Ping-Tests im lokalen LAN/WLAN</li>
|
||||
<li><b>fritzbox</b> - Eine Erkennung aufgrund der internen Abfrage des Status auf der FritzBox (nur möglich, wenn FHEM auf einer FritzBox läuft)</li>
|
||||
<li><b>local-bluetooth</b> - Eine Erkennung auf Basis von Bluetooth-Abfragen durch den FHEM Server. Das Gerät muss dabei in Empfangsreichweite sein, aber nicht sichtbar sein</li>
|
||||
<li><b>function</b> - Eine Erkennung mithilfe einer selbst geschriebenen Perl-Funktion, welche den Anwesenheitsstatus ermittelt.</li>
|
||||
<li><b>lan-bluetooth</b> - Eine Erkennung durch Bluetooth-Abfragen via Netzwerk (LAN/WLAN) in ein oder mehreren Räumen</li>
|
||||
</ul>
|
||||
<br><br>
|
||||
@ -1080,16 +1087,21 @@ Options:
|
||||
Prüft ob ein Gerät über Netzwerk (üblicherweise WLAN) auf Ping-Anfragen reagiert und setzt entsprechend den Anwesenheitsstatus.<br>
|
||||
<br>
|
||||
<b>Modus: fritzbox</b><br><br>
|
||||
<code>define <name> PRESENCE fritzbox <device-name> [ <Interval> [ <Anwesend-Interval> ] ]</code><br>
|
||||
<code>define <name> PRESENCE fritzbox <Gerätename> [ <Interval> [ <Anwesend-Interval> ] ]</code><br>
|
||||
<br>
|
||||
Prüft ob ein Gerät welches per WLAN mit der FritzBox verbunden ist, erreichbar durch Abfrage des Status mit dem Befehl ctlmgr_ctl.
|
||||
Der Gerätename (Parameter: <device-name>) muss dem Namen entsprechen, welcher im Menüpunkt "Heimnetz" auf der FritzBox-Oberfläche angezeigt wird.<br>
|
||||
Der Gerätename (Parameter: <Gerätename>) muss dem Namen entsprechen, welcher im Menüpunkt "Heimnetz" auf der FritzBox-Oberfläche angezeigt wird.<br>
|
||||
<br>
|
||||
<b>Modus: local-bluetooth</b><br><br>
|
||||
<code>define <name> PRESENCE local-bluetooth <Bluetooth-Adresse> [ <Interval> [ <Anwesend-Interval> ] ]</code><br>
|
||||
<br>
|
||||
Prüft ob ein Bluetooth-Gerät abgefragt werden kann und meldet dies als Anwesenheit. Für diesen Modus wird der Shell-Befehl "hcitool" benötigt
|
||||
(wird durch das Paket <a href="http://www.bluez.org" target="_new">bluez</a> bereitgestellt), sowie ein funktionierender Bluetooth-Empfänger (intern oder als USB-Stick)<br><br>
|
||||
<b>Modus: function</b><br><br>
|
||||
<code>define <name> PRESENCE function {...} [ <Interval> [ <Anwesend-Interval> ] ]</code><br>
|
||||
<br>
|
||||
Prüft den Anwesenheitsstatus mithilfe einer selbst geschriebenen Perl-Funktion (z.B. SNMP Abfrage).<br><br>
|
||||
Diese Funktion muss 0 (Abwesend) oder 1 (Anwesend) zurückgeben.<br><br>
|
||||
<b>Modus: lan-bluetooth</b><br><br>
|
||||
Prüft ein Bluetooth-Gerät auf Anwesenheit über Netzwerk mit Hilfe von presenced oder collectord. Diese können auf jeder Maschine installiert werden,
|
||||
welche eine Standard-Perl-Umgebung bereitstellt und über Netzwerk erreichbar ist.
|
||||
@ -1197,7 +1209,7 @@ Options:
|
||||
<b>Set</b>
|
||||
<ul>
|
||||
|
||||
<li><b>statusRequest</b> - (Nu für local-bluetooth, lan-ping and fritzbox) - Startet einen sofortigen Check.</li>
|
||||
<li><b>statusRequest</b> - (Nur für Modus local-bluetooth, lan-ping, function und fritzbox) - Startet einen sofortigen Check.</li>
|
||||
</ul>
|
||||
<br>
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user