From ee4661544b72e15a95a35ac49798b8210f39adeb Mon Sep 17 00:00:00 2001 From: rudolfkoenig <> Date: Sat, 17 Dec 2011 09:06:05 +0000 Subject: [PATCH] HOWTO correction / updates / rewording git-svn-id: https://svn.fhem.de/fhem/trunk@1136 2b470e98-0d58-463d-a4d8-8e2adae1ed80 --- fhem/docs/HOWTO.html | 295 ++++++++++++++++++++++------------------ fhem/docs/fhem.html | 20 ++- fhem/docs/fritzbox.html | 9 +- 3 files changed, 174 insertions(+), 150 deletions(-) diff --git a/fhem/docs/HOWTO.html b/fhem/docs/HOWTO.html index e714efaf0..8027e80bf 100644 --- a/fhem/docs/HOWTO.html +++ b/fhem/docs/HOWTO.html @@ -14,24 +14,24 @@
"sudo cpan
+ If yes, you can install it e.g. with "sudo cpan
Device::SerialPort"
. There are also precompiled debian packages
(libdevice-serialport-perl), and this module is already installed on OSX
- 10.6. If you cannot install it, you then take a look at the directio
- option
+ 10.6. If you cannot install it, you then take a look at the @directio
+ option in the commandref.html as a last resort.
The default configuration will install fhem into /usr/bin,
/usr/share/fhem and /var/log/fhem and /etc/fhem.cfg, according to the
@@ -68,8 +68,8 @@
2008.06.15 16:17:03 0: Server started (version ...)
-
- Attaching the USB device for the PC (CUL / FHZ1x00PC / etc)
+
+ Attaching the USB device to the PC (CUL / FHZ1x00PC / etc)
Connect to fhem with an internet browser:
http://fhem-host:8083/fhem
@@ -111,8 +111,8 @@
-
- Configuring transmitter devices (sensors)
+
+ Configuring transmitter devices (i.e. sensors)
The sample configuration file installed via "make install-pgm2" has
configured an autocreate
@@ -122,9 +122,11 @@
appeared devices. You can use
rename to rename the automatically created device, e.g. type in the
input field of the web frontend:
+
rename FHT_1234 fht.kitchen
+
Note: if you rename the device itself, the attached FileLog
and weblink will be renamed automatically. The other way round (renaming
@@ -133,10 +135,11 @@
If you want to do the same manually:
Wait a while, until the transmitter sent some data. In the logfile
- (Browser window: "Unsorted -> Logs / Fhemlog / text) a line
+ (browser window: "Unsorted -> Logs / Fhemlog / text) a line
will appear:
- FS20 Unknown device <HOUSECODE>, Button <BTN> Code <CDE>, please define it
+ FS20 Unknown device <HOUSECODE>, Button <BTN> Code
+ <CDE>, please define it
Now define the fhem device:
@@ -153,16 +156,14 @@
Here is a complete list of FS20
models.
For other device types similar messages should appear.
- Note: Creating a fhem FHT or HomeMatic device automatically or
- manually does not imply that the CUL or the FHZ is paired with it. For
- this purpose you have to set the FHT to accept new devices
- (Prog:Cent:N/A), and send a command to it (e.g. set fht.kitchen
- desired-temp 20). If there is no signal for a while, then check this FAQ entry.
+ HomeMatic sensors do not need to be paired with fhem, on the other side
+ fhem will only autocreate such a device, when it receives a pairing
+ request. You still need to "set CUL hmPairForSec 600" to respond
+ to this request.
-
- Configuring FS20 receivers (actors)
+
+ Configuring receivers (actors)
Configure the FS20 device in
fhem first with:
@@ -180,70 +181,74 @@
Other systems (EnOcean/HomeMatic) require a more elaborate procedure, and
the corresponding USB device is to be set into a pairing mode first. See
the commandref entry for your device.
-
+
+ Creating a fhem FHT / HomeMatic / EnOcean device automatically or
+ manually does not imply that the CUL or the FHZ is paired with it.
+
+ - FHT:
+ Set the FHT to accept new devices (Prog:Cent:N/A), and send a command
+ to it (e.g. set fht.kitchen desired-temp 20). If there is no signal
+ for a while, then check this FAQ entry.
+
+ - HomeMatic:
+ first set the CUL/HMLAN into pairing mode with
+
+ set CUL hmPairForSec 600
+
+ and then push the learning button on the HomeMatic device. If pairing was
+ successful, you'll see "CommandAccepted: yes" in the details window of the
+ device.
+
+
- Timed commands / Notification
+ Timed commands (at) / Notification (notify,watchdog)
To execute commands at a given time / periodically, you have to define
- devices of the type at. See the definition
- here and the examples here. The last link
- only works if you are reading this HOWTO from your fhem Web.
+ devices of the type at. See the definition and the examples
+ here.
+
To execute commands if a device sent a message you have to define
devices of the type notify or
watchdog. In order to understand
- the fhem events better you can open a telnet session to your fhem
- telnet localhost 7072
+ the fhem events better you should open a telnet session to your fhem
+
+ telnet <fhemhost> 7072
+
- and type
- inform timer
+ and type
+
+ inform timer
+
- Now you will receive in this telnet session all events, just like the
- notifies/watchdogs do. You can even simulate events by using the
- trigger command:
- trigger lamp1 on
+ Now you will receive in this telnet session all events, e.g.
+
+ 2011-12-16 21:51:55 FS20 myPiri on-for-timer 120
+
+ so you can define an action like:
+
+ define lampNotify notify myPiri set myLamp on
+
+ or
+
+ define lampNotify notify myPiri:on.* set myLamp on
+
+ To test your notify you can simulate events by using the
+ trigger command:
+
+ trigger myPiri on-for-timer 120
+
- For a more complex automation you can either control fhem by an external
- program via telnet or HTTP, or (the usual way) do this via the fhem at
- and notify commands. at and notify takes either simple fhem commands,
- shell skripts or "perl oneliners" as argument. For details and tips on
- the perl oneliners read the Perl
- specials section in the commandref.html
-
-
- FHEMWEB (pgm2) look and feel
-
- It makes sense to group your devices into rooms by setting the room
- attribute. FHEMWEB puts devices without a room attribute into the
- "Unsorted" room. Devices in the room "hidden" will not be shown.
-
- You can also define a stripped down FHEMWEB instance, by defining the
- Menu entries to be hidden in the
- hiddenroom FHEMWEB attribute.
-
+ at, notify and watchdog take either simple fhem commands, shell scripts
+ or "perl oneliners" as argument. For details and tips on the perl
+ oneliners read the Perl specials
+ section in the commandref.html
- Set the title of the webpage by setting the title
attribute
- of the global device ("All together" -> global)
-
- Edit the colors / fonts by changing the style.css ("Edit files" ->
- style.css), or create you own style (see stylesheetPrefix , so it
- won't be overwritten by the next updatefhem command.
-
-
- Further FHEMWEB attributes:
- webname,
- plotmode,
- plotsize.
-
-
-
-
+
Logging data
To log messages into files, define devices of the type
FileLog definition.
- Don't forget to enable archiving with the nrarchive or archivecmd attributes.
-
+
Plotting logs
Autocreate will create weblinks (i.e. plots) for newly detected devices.
The following section describes how to do it manually, e.g. if you want
to plot data from different sensors together.
- To convert a FileLog into a plot (chart) in FHEMWEB, set the
- logtype attribute of the
- corresponding FileLog. Take a look at the available gnuplot files in the
- "Edit files" section, they contain the corresponding FileLog definition
- example.
+ The data for a plot always comes from a single FileLog, change its regexp
+ so that it will collect all events you want to plot. As the next step
+ set the logtype attribute of the
+ FileLog, this will define which .gplot files to use.
+ Take a look at the available gnuplot files in the "Edit files" section,
+ they contain the corresponding FileLog definition examples.
Note that the .gplot files are also used if you use SVG output and
not the gnuplot backend!
+ The gnuplot files must have #FileLog entries in order to be useable
+ with gnuplot-scroll or SVG (these lines are treated as comment by
+ gnuplot, but not by fhem!), as the filtering happens with the FileLog get
+ function, see the supplied gnuplot files or the column_spec paragraph here for the syntax.
+
+
Examples:
attr em1000log logtype power8:Power,text
attr fs20_log logtype fs20:Plot,text
attr hms100th_log logtype temp4hum6:Plot,text
- When displaying the plot, you can convert it into a
- weblink, which
- has its own attributes. If the weblink refers to the current
- logfile, then it will be stored as a CURRENT weblink, and it will always
- display the most recent log (you do not have to redefine it if the
- logfile changes due to year/month/date parameters in its name).
+ Display the plot by clicking on it, and create a weblink, which has its own attributes
+ (room, etc).
+ If the weblink refers to the current logfile, then it will be stored as a
+ CURRENT weblink, and it will always display the most recent log (you do
+ not have to redefine it if the logfile changes due to year/month/date
+ parameters in its name).
@@ -307,46 +321,46 @@
href="commandref.html#plotmode">plotmode attribute to gnuplot or
gnuplot-scroll.
- In order to look at historic data, you can either convert the
- archive entries to a weblink in "plotmode=gnuplot" mode, or use the
- "plotmode=gnuplot-scroll" or "plotmode=SVG" modes. gnuplot-scroll and SVG
- offer the possibility to zoom or scroll in the plot, see the arrow and
- magnifier icons at the top of the page.
+ In order to look at historic data, create another weblink and set its
+ fixedrange attribute, e.g.:
+
+ attr weblink_1 fixedrange 2006-01-01 2007-01-01
+
+
- Note: the gnuplot files must have #FileLog entries in order to be useable
- with gnuplot-scroll or SVG (these lines are treated as comment by
- gnuplot, but not by fhem!), as the filtering happens with the FileLog get
- function, see the supplied gnuplot files or the column_spec paragraph here for the syntax.
-
- The order of the #FileLog lines must match the corresponding 'awk'
- entries.
-
- I recommend using log files with year resolution, this is determined by
- its wildcard characters (year/month/week/day), look at the FileLog
- definition.
+ To display "foreign" (non fhem) files as a plot or just as plain text,
+ configure a fake logfile with the correct filename and an unused regexp,
+ e.g.
+ define messages FileLog /var/log/messages fakelog
+
-
- FHEMWEB tips
+
+
+
+ Security
- Click on the State link on the detail page to get a documentation of
- all its settable values, similarly clicking on "Attribute" will guide you
- to the documentation of its attributes.
-
+ - The telnet port cannot be secured with a password. Usually this is
+ not a problem, since this port is only accessible from the secure
+ home network. Deleting the last "global" attribute from the "attr
+ global port 7073 global" (changing it to "attr global port 7073")
+ will accept only local connections (i.e. telnet only from the fhem
+ server itself).
- There are two different ways to enable Password and HTTPS
-
- - Using the builtin features of FHEMWEB for basic html authentication and HTTPS. The perl modules needed for
- HTTPS are missing from the FritzBox distribution, I recommend a direct
- VPN connection here.
+ - One way of secure access from the outside is to use a VPN connection.
+ Connecting e.g. to a FritzBox by VPN works both for iOS and Android
+ devices.
+
+ - Securing FHEMWEB (method 1) by using the builtin features of FHEMWEB
+ for basic html authentication
+ and HTTPS. The perl modules
+ needed for HTTPS are missing from the FritzBox distribution, so this
+ is not an option here.
+
-
- - Using apache to implement this features, and redirect a certain prefix to
- each FHEMWEB instance.
+ - Securing FHEMWEB (method 2) by using apache to implement this
+ features, and redirect a certain prefix to each FHEMWEB instance.
Add the following lines to your httpd.conf:
<Proxy *>
AuthType Basic
@@ -375,13 +389,26 @@
- Start httpd with the startssl option (SSL or the like must be set in
one of your system files, look at /etc/init.d/httpd).
-
- To display "foreign" (non fhem) files as a plot or just as plain text,
- configure a fake logfile with the correct filename and an unused regexp,
- e.g.
- define messages FileLog /var/log/messages fakelog
+
+ FHEMWEB (pgm2) look and feel
+
+ It makes sense to group your devices into rooms by setting the room
+ attribute. FHEMWEB puts devices without a room attribute into the
+ "Unsorted" room. Devices in the room "hidden" will not be shown.
+
+ You can also define a stripped down FHEMWEB instance, by defining the
+ Menu entries to be hidden in the
+ hiddenroom FHEMWEB attribute.
+
+
+ Edit the colors / fonts by changing the style.css ("Edit files" ->
+ style.css), or create you own style (see stylesheetPrefix , so it
+ won't be overwritten by the next updatefhem command.
+
diff --git a/fhem/docs/fhem.html b/fhem/docs/fhem.html
index e15cc8565..4a2e849fe 100644
--- a/fhem/docs/fhem.html
+++ b/fhem/docs/fhem.html
@@ -36,31 +36,29 @@
Fhem is a GPL'd perl server for house automation. It is used to automate
some common tasks in the household like switching lamps / shutters /
- heating / etc. and to log events like temperature/humidity/power
+ heating / etc. and to log events like temperature / humidity / power
consumption.
The program runs as a server, you can control it via web-frontends,
telnet, command line program or TCP/IP directly.
In order to use fhem you'll need a 24/7 server (PC, MacMini, Fritz!Box,
- NAS, etc) with a perl interpreter and some hardware to access the
- devices, see the "Supported hardware" section below. Some of the fhem
- hardware-modules need special perl modules (e.g. Device::SerialPort) in
- order to work, see the corresponding section in the commandref.html.
-
+ NAS, etc) with a perl interpreter and some attached hardware like the
+ CUL, FHZ1300PC, etc. to access the actors and sensors. See the "Supported
+ hardware" section below.
Download
- Current Version: (as of =DATE=):
+ Last released version: (as of =DATE=):
fhem-=VERS=.tar.gz,
fhem-=VERS=.deb,
fhem-=VERS=-fb7390.image,
- fhem-=VERS=-fb7270.zip
+ fhem-=VERS=-fb7270.zip
- See the CHANGED file for current changes.
+ See the CHANGED file for the change history.
Nightly SVN version: a
@@ -224,7 +222,7 @@
Documentation
- fhem fuer
+ fhem für
Einsteiger (pdf, german)
HOWTO.html for a short
@@ -332,7 +330,7 @@
Fritz!Box
- See the detailed documentation here, and
- after installation connect to http://localhost:8083/fhem. Follow the HOWTO for adding devices.
diff --git a/fhem/docs/fritzbox.html b/fhem/docs/fritzbox.html
index fdf1562c9..fac6df0f6 100644
--- a/fhem/docs/fritzbox.html
+++ b/fhem/docs/fritzbox.html
@@ -48,7 +48,7 @@
and enabling autocreate. When installing it, you have to confirm with an
extra click that it does not have a valid AVM signature. It will reuse your
old logfiles and configuration, unlike the "original" AVM firmware.
- Autocreate is on, and there are NO CUL devices defined in the initial
+ Autocreate is on, and there are no CUL devices defined in the initial
configuration, you'll have to do this manually, e.g. by following the HOWTO
or the command reference.
@@ -56,11 +56,10 @@
Fritz!Box 7170/7270 (as of 2011-09-03)
- Thank to Eyk's work there is also a ZIP file for the Fritz!Box 7170 and 7270
- models. As the FB720/7170 has not enough internal storage to install fhem
- on it, you have to use an external USB Drive, and this package follows a
- different approach than the FB7390 image.To install it:
+ models. As the FB720/7170 has not enough internal storage to install fhem,
+ you have to use an external USB Drive:
- First unzip the .ZIP file in the root directory of the USB-disk/USB-stick.
- Attach the stick to the FB