CM11/HEYU History.
Ver 0.0
   ported from the Linux version of the Larry Campbell source to x10.

Ver 0.9
   Initial release.

Ver 1.0
   Added protocol.txt to tar file.
   Added version number that's visible when no arguments are given.
   Added clear flag to setclock.
   Changed info to show readable status bits.
   Added history file to tar file.

Ver 1.1  Internal

Ver 1.2
    Added UUCP style lock file for the tty device.
    
Ver 1.3  Internal

Ver 1.4
    Has a status command that works with RR501 remote RF receivers.

Ver 1.5
    The macro address should be  12 bits. (per section 5.4.3)
    Changed X10 to use version.h
    Changed status to display Iseconds, etc instead of the raw bytes.
    Added extra check4poll in status.c for when a status is waiting.
    Changed the xread to wait a FULL second using setitimer.

Ver 1.6
    Initial version that uses a relay daemon to allow monitor to
    run while turning lights on and off.  The 'stop' is used to 
    stop the daemon.

Ver 1.7
    Ver 1.6 could build a large history file.  This version moves the
    getinfo req to the daemon, thus satisfying the CM11 immediately.

Ver 1.8
    The monitor now handles transmitted as well as received bytes.
Ver 1.9
    I was concerned about two things:  The monitor took up too much
    CPU time, and the commands felt sluggish because of the timeouts
    waiting for characters to come in from the interface.

    The solution is to only do a read from the FIFO when it's changed
    since the last read, IE the file pointer has changed.

    The protocol.txt file was also updated to incorporate recent changes
    to the version available from www.x10.com.

    The relay daemon was not deleting the fifo when the daemon was killed.
    This worked OK until the file ended up owned by root :-(
    The file is now deleted upon SIGINT and SIGTERM.
Ver 1.10 - 1.12
    Aborted test versions that were never released.
Ver 1.13
    The default directories I chose were not standard in all Linux
    distributions, so I've changed them to use /var/tmp instead.

    The CM11A output messages for macros are now interpreted correctly.
Ver 1.14
    The default lock files for Red Hat were different,  causing the 
    daemon to malfunction.  I've changed the logging so that most
    errors log via the syslog functions.

    The daemon now uses a timer to ensure that the powerfail indicator
    is not part of the normal data stream.

    The RI (Ring Indicator) modem line is looked at to avoid trying to
    talk to the CM11 while it's talking.  Unfortunately, the CM11 does
    not have anyway to prevent the reverse.

    Changed x10.c, stop.c and relay.c so that a ps(1) command will show
    that the relay daemon is heyu_relay.

    It was kind of unkind to let unsuspecting people untar the archive into
    their current directory.  The file now untars to the directory heyu.dir

Ver 1.15
    Corrected the blank line handling for x10config (thanks to David Dee)

    Added the includes needed by the new redhat glibc, supplied by
    Michael Fulbright (msf@redhat.com)

Ver 1.16
    Corrected the error message that reports spool file failure.  Thanks to
    Paul Chamberlain for the report AND the fix.

    Corrected the condition that kept the 'stop' command from working
    in some cases.

ver 1.17
    Finally added code that would make the X10 retry commands multiple
    times (three, in fact) when the interface interrupts an RS232 command
    transmission due to a macro activation or powerline transmission.
    This has reduced failures to virtually 0.

Ver 1.18
    The program exits if it's in monitor mode and the spool file goes away.

    The program was (sometimes) core dumping if two instances of the program
    finished and 'info' at the same time (quit function).

    The lock file was moved to /var/lock in keeping with the FHS (filesystem
    hierarchy standard).  Thanks to Peter Kim for the pointer to the FHS.
    The define for LOCKDIR was moved up into x10.h

    The defines for nextstep 3.3 were added to the make file.

    Added help and version options.

Ver 1.19
    Added defines for Solaris 2.5

Ver 1.20
    Added patches submitted by erv@cne.dynip.com, jruschme@exit109.com and
    rdiamond@cisco.

    There should be better information in the system logs when the spool file
    or TTY can't be opened.

    It should handle signals a little cleaner

    The all off and all on were reversed.

    It should compile a little better with Redhat's configuration.

    The firmware version nibble was being misused.  This caused problems
    for the early adopters with beta versions of the CM11.  It now reports
    the firmware version.

Ver 1.21
    Cleaned up the errors that show when CC is invoked with -Wall.

    Ian! D. Allen reported a bug (introduced in 1.20) in xread that
    was causing monitor to report 'Poll received unknown value' after
    sending a command.

    Added code to lock the tty before writing.  This prevents programs from
    stepping on each other.

Ver 1.23
    Moved some error messages around.

    The configuration file defaults to /etc/x10.conf if all else fails.

    Added error checking code if the spool files can't be opened.

Ver 1.25
    Added preset dims from code donated by Gregory Gulik.

    Fixed an 'fclose' in tty.c that shouldn't have been there.

    Added stricter checking for lock directories.

Ver 1.28
    Added presets to the man page.

    Added timers and macros to the program and man page.

    Added a man page for the timer/macro schedules.

    Set up a sample .x10sched.conf file.

    Fixed a memory leak that was causing the monitor mode to grow
    by 1K with each event it saw.

    Added define for freebsd to makefile.

    Added the hidden command qerase to try to revive locked up CM11.  
    It's been tested once when teh CM11 locked up.  It worked that time.

    Added the Julian date to the 'info' printout.  The julian now matches the
    documentation.  In previous versions it was offset by 1.  This only 
    affected downloaded timers that are date range sensitive.

Ver 1.28a
    I found that I could cause a core dump by using a trigger with an
    undefined macro.  A call to find_macro() fixed it.

    This version was made public 45 minutes after version 1.28.  SIGH!

Ver 1.28b
    An array boundry was exceeded on macro labels, causing core dump.  The
    tr_count was also not initialized, causing false 'prom out of memory'
    errors.  Thanks to James Gurganus (james@gurganus.net) for reporting it.

Ver 1.28c
    Cleaned up the garbage that 'monitor' displayed when the power fail
    routine ran.

    Changed the format of the monitor output slightly to better tell the
    difference between a macro trigger and a timer.  This only shows if
    the flag NEWFORMAT is in the .x10config file.

    Added special units lightson, lightsoff, hail allon and alloff so you 
    can do heyu turn lightson and heyu hail

    Ready for beta???

Ver 1.28d
    I found that the CM11A does NOT like it when I initialize unused space to
    Zero.  It caused many spurious triggers.  I changed the initialization to
    all 1's and the macros and timers work great!

    Changed the day of the week to month/day in the monitor mode if 'newformat'
    is set.

    This version was released as a 'beta' for 1.29

Ver 1.28e
    Two weeks of beta without failures.  Thanks to brianc@palaver.net for
    finding a bug in the sched parser that improperly checked the macro 
    pointer.

    Changed the names for loading macros to 'upload' and the validate flag
    to 'check'.

    Updated the man pages for sched, x10config and heyu.
Ver 1.28f
    bug fix.  The status argument was always using the same unitcode. Thanks
    go to Mace Moneta (mmoneta@qsun.mt.att.com) for spotting this.
