X10 Language Extensions

The x10 class provides extensions to VBScript to allow direct integration with X10 devices and the xPLHal X10 device cache.

To send an X10 command

x10.Send(<device>, <function>, <brightness>)
<device> is a string containing the X10 device to be controlled, e.g. A1, F2, H3 etc.
<function> is a string containing the function to be executed.
Supported functions are:
ON
OFF
DIM
BRIGHT
ALL LIGHTS OFF
ALL LIGHTS ON
ALL UNITS OFF
<brightness> is an integer that specifies the level of the dim or bright command.
For commands other than dim and bright, this parameter is ignored and should be set to zero.

Load X10 Device and Attributes

x10.loaddevice(,,, , , , 

To set an individual x10 attribute

x10.attrib(,)=
e.g. x10.attrib("A1",X10_TIMEOUT)=5
This function is available, but should not be used except in exceptional/unusual circumstances

To get an individual x10 attribute

x10.attrib(,)
e.g. lightstate=x10.attrib("A1",X10_STATE)

The file ./scripts/headers/xplhal_x10.xpl contains all of the supported constants
Please refer to this file for available values

The state of the X10 device cache is maintained automatically by xPLHal. It tracks device state changes, including commands that effect multiple devices. However, the nature of x10 means the maintaining of these states is based purely on the interpretation of xpl messages. Testing to improve this functionality will be on-going.

The x10 cache is ONLY updated in response to xpl-trig messages (All x10 xpl app's should return an xpl-trig message, in response to an xpl-cmnd message, to confirm the message was received and actioned)
The DIM/BRIGHT function support is minimal at the moment, but will be improved.

To delete an X10 device

x10.DeleteDevice(<deviceName>)
This command deletes the specified X10 device from the database.