mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-01-31 06:39:11 +00:00
- feature: new modules 00_CM11.pm and 20_X10.pm for integration of X10 devices in fhem
- feature: X10 support for pgm3 git-svn-id: https://svn.fhem.de/fhem/trunk@261 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
b3275db23a
commit
7f24599c6a
@ -435,3 +435,7 @@
|
|||||||
- feature: The strange stty settings in 00_FHEM.pm are optional
|
- feature: The strange stty settings in 00_FHEM.pm are optional
|
||||||
- bugfix: webpgm2 iPhone fix
|
- bugfix: webpgm2 iPhone fix
|
||||||
- feature: fullinit and reopen commands for FHZ added (Boris 2008-11-01)
|
- feature: fullinit and reopen commands for FHZ added (Boris 2008-11-01)
|
||||||
|
- bugfix: avoid access to undefined NotifyFn in hash in fhem.pl (Boris 2008-11-01)
|
||||||
|
- feature: new modules 00_CM11.pm and 20_X10.pm for integration of X10
|
||||||
|
devices in fhem (Boris 2008-11-02)
|
||||||
|
- feature: X10 support for pgm3 (Boris 2008-11-02)
|
||||||
|
@ -316,4 +316,9 @@ Fri Jul 25 18:14:26 MEST 2008
|
|||||||
|
|
||||||
- Boris Sat Nov 01 CET 2008
|
- Boris Sat Nov 01 CET 2008
|
||||||
- feature: new commands fullinit and reopen for FHZ, commandref.html update
|
- feature: new commands fullinit and reopen for FHZ, commandref.html update
|
||||||
|
- bugfix: avoid access to undefined NotifyFn in hash in fhem.pl
|
||||||
|
|
||||||
|
- Boris Sun Nov 02 CET 2008
|
||||||
|
- feature: new modules 00_CM11.pm and 20_X10.pm for integration of X10
|
||||||
|
devices in fhem
|
||||||
|
- feature: X10 support for pgm3
|
@ -106,7 +106,8 @@ DbLog_ParseEvent($$)
|
|||||||
($type eq "EMEM")) {
|
($type eq "EMEM")) {
|
||||||
}
|
}
|
||||||
# FS20
|
# FS20
|
||||||
elsif($type eq "FS20") {
|
elsif(($type eq "FS20") ||
|
||||||
|
($type eq "X10")) {
|
||||||
@parts= split(/ /,$value);
|
@parts= split(/ /,$value);
|
||||||
my $reading= $parts[0]; if(!defined($reading)) { $reading= ""; }
|
my $reading= $parts[0]; if(!defined($reading)) { $reading= ""; }
|
||||||
if($#parts>=1) {
|
if($#parts>=1) {
|
||||||
|
4
fhem/docs/X10/README
Normal file
4
fhem/docs/X10/README
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
protocol.txt is taken from the source tar ball of the programm heyu from
|
||||||
|
Daniel B. Suthers.
|
||||||
|
|
||||||
|
|
1024
fhem/docs/X10/protocol.txt
Normal file
1024
fhem/docs/X10/protocol.txt
Normal file
File diff suppressed because it is too large
Load Diff
@ -1040,6 +1040,69 @@ fs20usr</pre></li>
|
|||||||
<br>
|
<br>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
|
<a name="CM11"></a>
|
||||||
|
<h4>Type CM11</h4>
|
||||||
|
<ul>
|
||||||
|
<code>define <name> CM11 <serial-device></code>
|
||||||
|
<br><br>
|
||||||
|
CM11 is the X10 module to interface X10 devices with the PC.<br><br>
|
||||||
|
|
||||||
|
The current implementation can evaluate incoming data on the powerline of
|
||||||
|
any kind. It can send on, off, dimdown and dimup commands.
|
||||||
|
<br><br>
|
||||||
|
This statement specifies the serial port to communicate with the CM11.
|
||||||
|
The name of the serial-device depends on your distribution. If serial-device
|
||||||
|
is none, then no device will be opened, so youcan experiment without
|
||||||
|
hardware attached.<br>
|
||||||
|
|
||||||
|
If you experience problems (for verbose 4 you get a lot of "Bad CRC message"
|
||||||
|
in the log), then try to define your device as <br>
|
||||||
|
<code>define <name> FHZ <serial-device> strangetty</code><br>
|
||||||
|
<br>
|
||||||
|
|
||||||
|
Example:
|
||||||
|
<ul>
|
||||||
|
<code>define x10if CM11 /dev/ttyUSB3</code><br>
|
||||||
|
</ul>
|
||||||
|
<br>
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<a name="X10"></a>
|
||||||
|
<h4>Type X10</h4>
|
||||||
|
<ul>
|
||||||
|
<code>define <name> X10 <model> <housecode>
|
||||||
|
<unitcode></code>
|
||||||
|
<br><br>
|
||||||
|
|
||||||
|
Defines an X10 device via its model, housecode and unitcode.<br><br>
|
||||||
|
|
||||||
|
Notes:
|
||||||
|
<ul>
|
||||||
|
<li><code><model></code> is one of
|
||||||
|
<ul>
|
||||||
|
<li><code>lm12</code>: lamp module, dimmable</li>
|
||||||
|
<li><code>lm15</code>: lamp module, not dimmable</li>
|
||||||
|
<li><code>am12</code>: appliance module, not dimmable</li>
|
||||||
|
<li><code>tm12</code>: tranceiver module, not dimmable. Its
|
||||||
|
unitcode is 1.</li>
|
||||||
|
</ul>
|
||||||
|
Model determines whether a dim command is reasonable to be sent
|
||||||
|
or not.</li>
|
||||||
|
<li><code><housecode></code> ranges from A to P.</li>
|
||||||
|
<li><code><unitcode></code> ranges from 1 to 16.</li>
|
||||||
|
</ul>
|
||||||
|
<br>
|
||||||
|
|
||||||
|
Examples:
|
||||||
|
<ul>
|
||||||
|
<code>define lamp1 X10 lm12 N 10</code><br>
|
||||||
|
<code>define pump X10 am12 B 7</code><br>
|
||||||
|
<code>define lamp2 X10 lm15 N 11</code><br>
|
||||||
|
</ul>
|
||||||
|
</ul>
|
||||||
|
<br>
|
||||||
|
|
||||||
|
|
||||||
<a name="FileLog"></a>
|
<a name="FileLog"></a>
|
||||||
<h4>Type FileLog</h4>
|
<h4>Type FileLog</h4>
|
||||||
<ul>
|
<ul>
|
||||||
@ -1792,7 +1855,9 @@ Send buffer:<br/> 2007-10-19 00:31:24 desired-temp 22.5
|
|||||||
time
|
time
|
||||||
FHTcode
|
FHTcode
|
||||||
activefor
|
activefor
|
||||||
raw</pre>
|
raw
|
||||||
|
initfull
|
||||||
|
reopen</pre>
|
||||||
Notes:
|
Notes:
|
||||||
<ul>
|
<ul>
|
||||||
<li>use activefor if you have multiple FHZ devices, and you want to
|
<li>use activefor if you have multiple FHZ devices, and you want to
|
||||||
@ -1810,6 +1875,26 @@ Send buffer:<br/> 2007-10-19 00:31:24 desired-temp 22.5
|
|||||||
central FHT code, which is used by the FHT devices. After changing
|
central FHT code, which is used by the FHT devices. After changing
|
||||||
it, you <b>must</b> reprogram each FHT80b with: PROG (until Sond
|
it, you <b>must</b> reprogram each FHT80b with: PROG (until Sond
|
||||||
appears), then select CEnt, Prog, Select nA.</li>
|
appears), then select CEnt, Prog, Select nA.</li>
|
||||||
|
<li>If the FHT ceases to work for FHT devices whereas other devices
|
||||||
|
(e.g. HMS, KS300) continue to work, a<ul>
|
||||||
|
<code>set FHZ initfull</code></ul> command could help. Try<ul>
|
||||||
|
<code>set FHZ reopen</code></ul> if the FHZ
|
||||||
|
ceases to work completely. If all else fails, shutdown fhem, unplug
|
||||||
|
and replug the FHZ device. Problems with FHZ may also be related to
|
||||||
|
long USB cables or insufficient power on the USB - use a powered hub
|
||||||
|
to avoid such issues.</li>
|
||||||
|
<li><code>initfull</code> issues the initialization sequence for the FHZ
|
||||||
|
device:<br>
|
||||||
|
<pre>
|
||||||
|
get FHZ init2
|
||||||
|
get FHZ serial
|
||||||
|
set FHZ initHMS
|
||||||
|
set FHZ initFS20
|
||||||
|
set FHZ time
|
||||||
|
set FHZ raw 04 01010100010000</pre></li>
|
||||||
|
<li><code>reopen</code> closes and reopens the serial device port. This
|
||||||
|
implicitely initializes the FHZ and issues the
|
||||||
|
<code>initfull</code> command sequence.</li>
|
||||||
</ul>
|
</ul>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
@ -1873,7 +1958,8 @@ Send buffer:<br/> 2007-10-19 00:31:24 desired-temp 22.5
|
|||||||
the program automatically schedules a "setstate off" for the
|
the program automatically schedules a "setstate off" for the
|
||||||
specified time.</li>
|
specified time.</li>
|
||||||
<li>on-till requires an absolute time in the "at" format (HH:MM:SS, HH:MM
|
<li>on-till requires an absolute time in the "at" format (HH:MM:SS, HH:MM
|
||||||
or {<perl-code>}, where the perl-code returns a time specification).
|
or { <perl code> }, where the perl-code returns a time
|
||||||
|
specification).
|
||||||
If the current time is greater then the specified time, then the
|
If the current time is greater then the specified time, then the
|
||||||
command is ignored, else an "on" command is generated, and for the
|
command is ignored, else an "on" command is generated, and for the
|
||||||
given "till-time" an off command is scheduleld via the at command.
|
given "till-time" an off command is scheduleld via the at command.
|
||||||
@ -2084,7 +2170,7 @@ Send buffer:<br/> 2007-10-19 00:31:24 desired-temp 22.5
|
|||||||
<br><br>
|
<br><br>
|
||||||
Sets the state of all digital ports at once, value is 0..255.
|
Sets the state of all digital ports at once, value is 0..255.
|
||||||
<br><br>
|
<br><br>
|
||||||
<code>set <name> [io0..io7] 0|1</code>
|
<code>set <name> io0..io7 0|1</code>
|
||||||
<br><br>
|
<br><br>
|
||||||
Turns digital port 0..7 off or on.
|
Turns digital port 0..7 off or on.
|
||||||
<br><br>
|
<br><br>
|
||||||
@ -2099,6 +2185,57 @@ Send buffer:<br/> 2007-10-19 00:31:24 desired-temp 22.5
|
|||||||
<br><br>
|
<br><br>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
|
<a name="X10set"></a>
|
||||||
|
<h4>Type X10:</h4>
|
||||||
|
<ul>
|
||||||
|
<code>set <name> <value> [<argument>]</code>
|
||||||
|
<br><br>
|
||||||
|
where <code>value</code> is one of:<br>
|
||||||
|
<pre>
|
||||||
|
dimdown # requires argument, see the note
|
||||||
|
dimup # requires argument, see the note
|
||||||
|
off
|
||||||
|
on
|
||||||
|
on-till # Special, see the note
|
||||||
|
</pre>
|
||||||
|
Examples:
|
||||||
|
<ul>
|
||||||
|
<code>set lamp1 dimup 10</code><br>
|
||||||
|
<code>set lamp1,lamp2 off</code><br>
|
||||||
|
<code>set pump off</code><br>
|
||||||
|
<code>set lamp2 on-till 19:59</code><br>
|
||||||
|
</ul>
|
||||||
|
<br>
|
||||||
|
Notes:
|
||||||
|
<ul>
|
||||||
|
<li>Only switching and dimming are supported by now.</li>
|
||||||
|
<li>Dimming is valid only for a dimmable device as specified by
|
||||||
|
the <code>model</code> argument in its <code>define</code>
|
||||||
|
statement.
|
||||||
|
<li>An X10 device has 210 discrete brightness levels. If you use a
|
||||||
|
X10 sender, e.g. a remote control or a wall switch to dim, a
|
||||||
|
brightness step is 100%/210.</li>
|
||||||
|
<li><code>dimdown</code> and <code>dimup</code> take a number in the
|
||||||
|
range from 0 to 22 as argument. It is assumed that argument 1 is
|
||||||
|
a 1% brightness change (microdim) and arguments 2 to 22 are
|
||||||
|
10%..100% brightness changes. The meaning of argument 0 is
|
||||||
|
unclear.</li>
|
||||||
|
<li>This currently leads to some confusion in the logs as the
|
||||||
|
<code>dimdown</code> and <code>dimup</code> codes are logged with
|
||||||
|
different meaning of the arguments depending on whether the commands
|
||||||
|
were sent from the PC or from a remote control or a wall switch.</li>
|
||||||
|
<li><code>dimdown</code> and <code>dimup</code> from on and off states may
|
||||||
|
have unexpected results. This seems to be a feature of the X10
|
||||||
|
devices.</li>
|
||||||
|
<li><code>on-till</code> requires an absolute time in the "at" format
|
||||||
|
(HH:MM:SS, HH:MM) or { <perl code> }, where the perl code
|
||||||
|
returns a time specification).
|
||||||
|
If the current time is greater then the specified time, then the
|
||||||
|
command is ignored, else an "on" command is generated, and for the
|
||||||
|
given "till-time" an off command is scheduleld via the at command.
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
</ul>
|
||||||
<a name="FileLogset"></a>
|
<a name="FileLogset"></a>
|
||||||
<h4>Type FileLog:</h4>
|
<h4>Type FileLog:</h4>
|
||||||
<ul>
|
<ul>
|
||||||
|
@ -10,7 +10,7 @@
|
|||||||
|
|
||||||
|
|
||||||
<h1>FHEM</h1>
|
<h1>FHEM</h1>
|
||||||
GPL'd server to access devices like FHZ1000/FHZ1300,EM1010PC,WS300,SCIVT.
|
GPL'd server to access devices like FHZ1000/FHZ1300,EM1010PC,WS300,SCIVT,X10.
|
||||||
Formerly known as fhz1000.pl
|
Formerly known as fhz1000.pl
|
||||||
<br/><br/>
|
<br/><br/>
|
||||||
Current Version: (as of =DATE=) is <a
|
Current Version: (as of =DATE=) is <a
|
||||||
@ -22,7 +22,8 @@ href="#webfrontends"/>webfrontends</a> section for screenshots.
|
|||||||
<h2>Description</h2>
|
<h2>Description</h2>
|
||||||
<ul>
|
<ul>
|
||||||
This program makes the FHZ1000/FHZ1300/WS300 and other USB devices sold by ELV,
|
This program makes the FHZ1000/FHZ1300/WS300 and other USB devices sold by ELV,
|
||||||
Conrad and others useable with Linux. In fact, there is nothing Linux special
|
Conrad and others as well as X10 devices sold by Marmitek, Powerhouse and
|
||||||
|
others useable with Linux. In fact, there is nothing Linux special
|
||||||
in it, there are reports from OS X and Windows. You should be able to use it on
|
in it, there are reports from OS X and Windows. You should be able to use it on
|
||||||
other platforms as long as you can access the hardware as a serial device.<br>
|
other platforms as long as you can access the hardware as a serial device.<br>
|
||||||
The program runs as a server, you can control it via telnet, command line
|
The program runs as a server, you can control it via telnet, command line
|
||||||
@ -32,18 +33,26 @@ Currently implemented features:<br>
|
|||||||
<ul>
|
<ul>
|
||||||
<li>Via the FHZ module (with access to one or more FHZ1000/FHZ1300 device):
|
<li>Via the FHZ module (with access to one or more FHZ1000/FHZ1300 device):
|
||||||
<ul>
|
<ul>
|
||||||
<li>reading and sending FS20 events (on/off/dimming, timer commands)<br>
|
<li>reading and sending FS20 events (on/off/dimming, timer
|
||||||
<li>support of FS20 address features function group, local and global master
|
commands)</li>
|
||||||
|
<li>support of FS20 address features function group, local and global
|
||||||
|
master</li>
|
||||||
<li>reading and changing FHT80b parameters (temp, actuator, etc).<br>
|
<li>reading and changing FHT80b parameters (temp, actuator, etc).<br>
|
||||||
The FHT8b seems to work too. <b>Note:</b> the FHT8 wont work.<br>
|
The FHT8b seems to work too. Note: the FHT8 wont work.<br>
|
||||||
Internal software buffer to prevent lost commands.<br>
|
Internal software buffer to prevent lost commands.</li>
|
||||||
</li>
|
|
||||||
<li>reading HMS data (HMS100-T,-TF,-WD,-MG,-TFK,-CO,-FIT and RM100-2)</li>
|
<li>reading HMS data (HMS100-T,-TF,-WD,-MG,-TFK,-CO,-FIT and RM100-2)</li>
|
||||||
<li>reading KS300 data</li>
|
<li>reading KS300 data</li>
|
||||||
</ul>
|
</ul>
|
||||||
<b>Note:</b>The FHZ1350 WLAN is probably not working due to a prorietary
|
Note: The FHZ1350 WLAN is probably not working due to a prorietary
|
||||||
encryption.
|
encryption.
|
||||||
</li>
|
</li>
|
||||||
|
<li>Via the CM11 module (with access to a X10 computer interface):
|
||||||
|
<ul>
|
||||||
|
<li>reading all X10 events</li>
|
||||||
|
<li>sending X10 events (on/off/dimming)</li>
|
||||||
|
<li>on/off switching suppport</li>
|
||||||
|
</ul>
|
||||||
|
</li>
|
||||||
<li>reading WS300 data, and up to 9 attached devices</li>
|
<li>reading WS300 data, and up to 9 attached devices</li>
|
||||||
<li>reading EM1000WZ/EM1000EM/EM1000GZ data via an attached EM1010PC</li>
|
<li>reading EM1000WZ/EM1000EM/EM1000GZ data via an attached EM1010PC</li>
|
||||||
<li>reading attached SCIVT devices</li>
|
<li>reading attached SCIVT devices</li>
|
||||||
|
@ -334,7 +334,7 @@ xml_parser_free($xml_parser);
|
|||||||
if ($showroombuttons==1)
|
if ($showroombuttons==1)
|
||||||
for($i=0; $i < count($stack[0][children]); $i++)
|
for($i=0; $i < count($stack[0][children]); $i++)
|
||||||
{
|
{
|
||||||
if (substr($stack[0][children][$i][name],0,5)=='FS20_')
|
if ( (substr($stack[0][children][$i][name],0,5)=='FS20_') || (substr($stack[0][children][$i][name],0,4)=='X10_'))
|
||||||
{
|
{
|
||||||
for($j=0; $j < count($stack[0][children][$i][children]); $j++)
|
for($j=0; $j < count($stack[0][children][$i][children]); $j++)
|
||||||
{
|
{
|
||||||
@ -599,7 +599,7 @@ xml_parser_free($xml_parser);
|
|||||||
for($i=0; $i < count($stack[0][children]); $i++)
|
for($i=0; $i < count($stack[0][children]); $i++)
|
||||||
{
|
{
|
||||||
############################
|
############################
|
||||||
if (substr($stack[0][children][$i][name],0,5)=='FS20_')
|
if ((substr($stack[0][children][$i][name],0,5)=='FS20_')||(substr($stack[0][children][$i][name],0,4)=='X10_'))
|
||||||
{
|
{
|
||||||
$type=$stack[0][children][$i][name];
|
$type=$stack[0][children][$i][name];
|
||||||
echo "<tr><td $bg1 colspan=4><font $fontcolor1>";
|
echo "<tr><td $bg1 colspan=4><font $fontcolor1>";
|
||||||
|
Loading…
Reference in New Issue
Block a user