NAME

ControlX10::CM17 - Perl extension for 'FireCracker' RF Transmitter

SYNOPSIS

use ControlX10::CM17;

  # $serial_port is an object created using Win32::SerialPort
  #     or Device::SerialPort depending on OS
  # my $serial_port = setup_serial_port('COM10', 4800);

&ControlX10::CM17::send($serial_port, 'A1J');
  # Turns device A1 On
&ControlX10::CM17::send($serial_port, 'A1K');
  # Turns device A1 Off
&ControlX10::CM17::send($serial_port, 'BO');
  # Turns All lights on house code B off

DESCRIPTION

The FireCracker (CM17A) is a send-only X10 controller that connects to a serial port and transmits commands via RF to X10 transceivers.

The FireCracker derives its power supply from either the RTS or DTR signals from the serial port. At least one of these signals must be high at all times to ensure that power is not lost from the FireCracker. The signals are pulsed to transmit a bit (DTR for '1' and RTS for '0'). The normal rx/tx read/write lines are not used by the device - but are passed through to allow another serial device to be connected (as long as it does not require hardware handshaking).

A 40-bit command packet consists of a constant 16 bit header, a constant 8 bit footer, and 16 data bits. The data is subdivided into a 5 bit address $house code (A-P) and an 11 bit $operation. There are "ON" commands for 16 units per $house code (1J, 2J...FJ, GJ) and similar "OFF" commands (1K, 2K...FK, GK). A send decodes a parameter string that combines $house$operation into a single instruction. In addition to $operation commands that act on individual units, there are some that apply to the entire $house code or to previous commands.

$operation	FUNCTION
    L		Brighten Last Light Programmed 14%
    M		Dim Last Light Programmed 14%
    N		All Lights Off
    O		All Lights On
    P		All Units Off

Starting with Version 0.6, a series of Brighten or Dim Commands may be combined into a single $operation by specifying a signed amount of change desired after the unit code. An "ON" command will be sent to select the unit followed by at least one Brighten/Dim. The value will round to the next larger magnitude if not a multiple of 14%.

&ControlX10::CM17::send($serial_port, 'A3-10');
    # outputs 'A3J','AM' - at least one dim

&ControlX10::CM17::send($serial_port, 'A3-42');
    # outputs 'A3J','AM','AM','AM' - even multiple of 14

&ControlX10::CM17::send($serial_port, 'AF-45');
    # outputs 'AFJ','AL','AL','AL','AL' - round up if remainer

EXPORTS

The send_cm17 method is exported by default. It is identical to &ControlX10::CM17::send(), and accepts the same parameters.

use ControlX10::CM17;
send_cm17($serial_port, 'A1J');

AUTHORS

Bruce Winter bruce@misterhouse.net http://misterhouse.net

CPAN packaging by Bill Birthisel wcbirthisel@alum.mit.edu http://members.aol.com/bbirthisel

MAILING LISTS

General information about the mailing lists is at:

http://lists.sourceforge.net/mailman/listinfo/misterhouse-users
http://lists.sourceforge.net/mailman/listinfo/misterhouse-announce

To post to this list, send your email to:

misterhouse-users@lists.sourceforge.net

If you ever want to unsubscribe or change your options (eg, switch to or from digest mode, change your password, etc.), visit your subscription page at:

http://lists.sourceforge.net/mailman/options/misterhouse-users/$user_id

SEE ALSO

mh can be download from http://misterhouse.net

You can subscribe to the mailing list at http://www.onelist.com/subscribe.cgi/misterhouse

You can view the mailing list archive at http://www.onelist.com/archives.cgi/misterhouse

perl(1).

Win32::SerialPort and Device::SerialPort

COPYRIGHT

Copyright (C) 2000 Bruce Winter. All rights reserved.

This module is free software; you can redistribute it and/or modify it under the same terms as Perl itself. 30 January 2000.