aebb30af433d47e9579f374017d68720ebbd60c47f1a1a9fa3bbf28297715020e334204971538420
1
                     HEYU (version 1) Program overview
1
 
2
 
2
                   Installing Heyu on a Unix-like system.
3
This program operates an X10 module via a CM11A computer interface. It is
3
 
4
based on the program X10 by Larry Cambell as modified by Paul Fox. All but a
4
Heyu requires a reasonable compiler (GCC works well), the 'make' program,
5
few functions have been changed enough that they no longer interwork with
5
and the development header (.h) files.  Many OS distributions will either
6
the original. I think this justifies issuing the program as 'heyu' instead
6
install these by default or provide a visible option to include the
7
of 'x10'.
7
"development package" during OS installation.  But some of the newer OS's
8
 
8
do not, e.g., with Ubuntu Linux it's necessary to afterward execute the
9
The program name comes from the old joke about having a 3rd person in the
9
command 'apt-get install build-essential'. 
10
house. Ida No was the one frequently blamed when things went wrong. In my
10
 
11
house it was the frequently heard yells of "Heyu! Turn off the lights!"
11
Note: If you're upgrading from a previous version of Heyu, run 'heyu stop'
12
A poor joke, but I like it.
12
under that version before proceeding.
13
 
13
 
14
The program is strictly command line driven, and works well with crontab.
14
Quickstart:
15
Crontab can be used to schedule events. You can also upload timers and
15
    sh ./Configure.sh [option] (As a normal user)
16
macros to the CM11's memory.
16
    make                       (As a normal user)
17
 
17
    su                         (Become superuser)
18
The program comes complete with source code, sample config files, MAN pages
18
    make install            (As superuser)
19
an executable binary. The program has options to allow you to:
19
    exit                       (Revert to normal user)
20
 
20
    heyu info               (As a normal user, to test installation)
21
   * Get the date and time from the interface
21
 
22
   * Get information about current settings and module states
22
(The 'make install' requires that you have write permissions to
23
   * Turn an X10 module on or off
23
/usr/local/bin, man page, and other directories.)
24
   * Dim or brighten an X10 module
24
 
25
   * Monitor all data sent to or from the CM11A
25
Ubuntu Linux users should execute 'sudo make install' rather than
26
   * Get the status of intelligent X10 modules (rr501 for instance)
26
the three commands 'su', 'make install', and 'exit'.
27
   * Set the X10 clock from the computer's clock (time and date)
27
 
28
   * Zero out the macro and event memory of the X10
28
*** Kindly report any compile errors or warnings to the author.***
29
   * Upload macros and timers
29
 
30
   * preset the dim level of advanced two way devices
30
It can take 5-8 seconds to set up the heyu_relay daemon and initialize
31
 
31
the CM11A interface the first time Heyu is run, e.g., with 'heyu info'.
32
As of version 1.27, Heyu has the ability to send a schedule of events to the
32
 
33
CM11A. This enables timers and macros.
33
Running 'heyu help' will display the long list of Heyu commands.
34
 
34
These are further explained in the man page heyu(1).
35
The people at X10 have informed me that there is no way to download (to the
35
 
36
computer) the events stored in the CM11A. That being the case, I wrote
36
CUSTOMIZING
37
programs that will load the events and macros from local data files. This
37
-----------
38
will erase whatever has been stored there, but I guess that's the way it has
38
The Configure.sh script creates a Makefile by running 'uname -s' and then
39
to be.
39
passing known good options to Autoconf configure script.  The contents
40
 
40
of Makefile.in is then expanded to the Makefile.  Changes to the makefile
41
This should compile on any Linux system. It should also compile on any other
41
should be made in Configure.sh or Makefile.in.
42
BSDish or SYSV system. Just edit the #define in the make file. Make install
42
 
43
will try to install the man page and the program. The makefile has defines
43
If Configure.sh can not figure out what your system is, you can try
44
for these locations.
44
sh ./Configure.sh generic
45
 
45
    or
46
See the original README in Larry Campbell's program for some nice info on
46
sh ./Configure.sh sysv
47
the cp290 and the history of the program. See the original for some really
47
 
48
niffty uses using scheduling and macros.
48
If those don't work, we'll have to figure it out by hand. Please contact
49
 
49
the author so your discoveries can be integrated into the next release.
50
There are two demo programs included with heyu, monit and x10biff.
50
 
51
 
51
SERIAL PORTS
52
   * The monit program will turn off your monitor based on idle time. It's
52
------------
53
     the ultimate screen saver.
53
Many newer computers don't have built-in RS232 serial ports, only USB
54
   * The x10biff program will flash a light to let you know that you have
54
ports.  For these computers a USB-Serial adapter is required to connect
55
     E-mail.
55
the CM11A.  Before purchasing a USB-Serial adapter, verify that the driver
56
 
56
for your OS is available, either built-in to the OS, provided with the
57
Daniel B. Suthers, CCP, CSP
57
adapter on a companion disc, or downloadable from the adapter
58
12-31-1996
58
manufacturer's website.
59
Updated 12-12-1999
59
 
60
E-mail: dbs@tanj.com
60
If you have a choice, select an adapter with an FTDI chipset over one
61
uucp: pacbell!daver!dansst!dbs
61
with a Prolific chipset.  One dealer who specifies the chipset
 
 
62
and supported operating systems for each adapter model for sale is
 
 
63
ByteRunner (http://ww.byterunner.com).
 
 
64
 
 
 
65
Drivers for adapters with a Prolific PL2303 chipset can often be found
 
 
66
at http://www.prolific.com.tw/eng/downloads.asp?ID=31
 
 
67
 
 
 
68
For Linux, the serial device name for a USB-Serial adapter will normally
 
 
69
be /dev/ttyUSBx, where x = 0 for the first adapter plugged into the
 
 
70
USB port and higher numbers for subsequent adapters.
 
 
71
 
 
 
72
Note: The International 230V version of the CM11 sold in Europe and
 
 
73
elsewhere is now usually provided with a USB cable in addition to the
 
 
74
standard RS232 cable.  Many Linux users have experienced lockups and
 
 
75
other problem with this USB cable (based on a Prolific chipset) which
 
 
76
disappeared when they switched to a regular USB-Serial adapter.
 
 
77
 
 
 
78
OPTIONS
 
 
79
------- 
 
 
80
By default, Heyu allocates space for 32 common flags, 32 counters, and
 
 
81
32 user countdown timers.  The number of each of these can be increased
 
 
82
at compile time with switches -flags=NN, -counters=NN, and -timers=NN.
 
 
83
The specified NN must be in the range 1-1024 and will be rounded up to
 
 
84
the nearest multiple of 32, e.g.,
 
 
85
 
 
 
86
   sh ./Configure.sh -flags=64  -timers=75
 
 
87
 
 
 
88
will allocate space for 64 flags and 96 timers, the latter because
 
 
89
the specified 75 is rounded up to 96.  The number of counters will
 
 
90
remain 32.
 
 
91
  
 
 
92
By default, support for the X10 CM17A "Firecracker" device is compiled
 
 
93
into Heyu.  As there is no known version of this device available which
 
 
94
transmits at frequencies other than the 310 MHz used for transceivers
 
 
95
in North America, users outside this region may wish to compile without
 
 
96
CM17A support. Since the CM17A is both powered and actuated by the DTR
 
 
97
and RTS serial lines, support for this device might as well also be
 
 
98
omitted if your serial port hardware does not support these lines.
 
 
99
To do so, run the Configure.sh step mentioned above with the '-nocm17a'
 
 
100
switch, i.e.,
 
 
101
 
 
 
102
    sh ./Configure.sh -nocm17a
 
 
103
 
 
 
104
By default, support for Extended Type 0 (Shutter and Shade) commands
 
 
105
is compiled into Heyu.  As there is only one module known to support
 
 
106
these commands (the 230V, 50Hz Marmitek SW10 Shutter Motor Controller
 
 
107
sold in Europe), this support may be omitted by using Configure.sh with
 
 
108
the '-noext0' switch, i.e., 
 
 
109
 
 
 
110
   sh ./Configure.sh -noext0
 
 
111
 
 
 
112
By default, support for RFXSensors is compiled into Heyu. RFXSensors
 
 
113
require a WGL W800RF32 or RFXCOM X10 RF receiver as well as a RFXSensor
 
 
114
transmitter.  This support may be omitted by including the '-norfxs'
 
 
115
switch with Configure.sh, i.e.,
 
 
116
 
 
 
117
   sh ./Configure.sh -norfxs
 
 
118
 
 
 
119
By default, support for RFXMeters is compiled into Heyu. RFXMeters
 
 
120
requires a 433.92 MHz RFXCOM X10 RF receiver as well as the RFXMeter
 
 
121
transmitter.  This support may be omitted by including the '-norfxm' switch
 
 
122
with Configure.sh, i.e.,
 
 
123
 
 
 
124
   sh ./Configure.sh -norfxm
 
 
125
 
 
 
126
By default, support for the Digimax 210 remote thermostat is compiled
 
 
127
into Heyu. The Digimax requires a 433.92 MHz RFXCOM X10 RF receiver as
 
 
128
well as the Digimax transmitter.  This support may be omitted by
 
 
129
including the '-nodmx' switch with Configure.sh, i.e.,
 
 
130
 
 
 
131
   sh ./Configure.sh -nodmx
 
 
132
 
 
 
133
By default, support for Oregon RF sensors is compilied into Heyu.
 
 
134
Oregon sensor support requires a 433.92 MHz RFXCOM X10 RF receiver
 
 
135
as well as a supported model of Oregon sensor.  This support may be
 
 
136
omitted by including the '-noore' switch with Configure.sh, i.e.,
 
 
137
 
 
 
138
   sh ./Configure.sh -noore
 
 
139
 
 
 
140
By default, support for signals received from KaKu and HomeEasy
 
 
141
transmitters is compiled into Heyu.  KaKu/HomeEasy support requires a
 
 
142
433.92 MHz RFXCOM X10 RF receiver.  This support may be omitted
 
 
143
by including the '-nokaku' switch with Configure.sh, i.e.,
 
 
144
 
 
 
145
   sh ./Configure.sh -nokaku
 
 
146
 
 
 
147
By default, support for RFXLAN RF receiver (network version of RFXCOM)
 
 
148
is compiled into Heyu.  This support may be omitted by including the
 
 
149
'-norfxlan' switch with Configure.sh, i.e.,
 
 
150
 
 
 
151
   sh ./Configur.sh -norfxlan
 
 
152
 
 
 
153
 
 
 
154
Notes for Mac OS X:
 
 
155
-------------------
 
 
156
The heyu executable is installed in directory /usr/local/bin, which
 
 
157
is not on the Mac's default PATH.  You will have to add this directory
 
 
158
to your $PATH.  Similarly you may have to add the man page directory
 
 
159
/usr/local/man to your $MANPATH (or the /usr/share/misc/man.conf file
 
 
160
for newer versions of OS X which have deprecated $MANPATH).
 
 
161
 
 
 
162
Newer Macs don't have an actual RS232 serial port, only a USB port,
 
 
163
and a USB/Serial adapter is required.  The manufacturer's adapter
 
 
164
driver will usually add two or more different devices in /dev
 
 
165
(and often with "usbserial" as part of the name).  You'll have
 
 
166
to experiment to see which one works with Heyu by trying the
 
 
167
different names in the TTY directive in the heyu configuration
 
 
168
file.  The device name which also includes "cu" rather than "tty"
 
 
169
has been found to work on the (few) Macs tested thusfar.
 
 
170
 
 
 
171
 
 
 
172
Notes for AT&T SysV r4:
 
 
173
----------------------
 
 
174
The function uname(1) used to determine the system type for
 
 
175
Configure.sh does not distinguish this OS from other sysv systems.
 
 
176
Supply the system type parameter "attsvr4" to Configure.sh, i.e.,
 
 
177
run 'sh ./Configure.sh attsvr4'.
 
 
178
 
 
 
179
Notes for OpenSolaris:
 
 
180
---------------------
 
 
181
The directories in which the Heyu binary executable and man pages
 
 
182
are installed are set per the OpenSolaris system conventions to:
 
 
183
  BIN = /opt/heyu/bin
 
 
184
  MAN = /opt/heyu/man/man1
 
 
185
  MAN5 = /opt/heyu/man/man5
 
 
186
However for a virgin OS installation, none of these directories
 
 
187
are on the system's PATH/MANPATH and the user is responsible
 
 
188
for adding them to the PATH/MANPATH in order to have full use of
 
 
189
Heyu.
 
 
190
 
 
 
191
The user may alternatively rerun Configure.sh for "OpenSolaris_BSD",
 
 
192
i.e., 'sh ./Configure.sh opensolaris_bsd',
 
 
193
which will set the directories using the BSD convention under
 
 
194
the /usr/local tree, which however may be deleted when OpenSolaris
 
 
195
is upgraded.
 
 
196
 
 
 
197
Some older versions of OpenSolaris, in particular SXCE (Solaris
 
 
198
Express Community Edition), may encounter an error when running
 
 
199
'make install' like "test: argument expected".  If this occurs,
 
 
200
change the first line of file install.sh to read "#!/bin/ksh".
 
 
201
 
 
 
202
 
 
 
203