X10 CM15A Driver

Modified on 2010/12/15 10:03 by Administrator — Categorized as: Driver

Image
This driver uses an X10 CM15A device connected to a USB port on the computer to control X10 devices and receive X10 commands.

Manufacturer: X10

Primary Communications Port: USB


Configuration Settings


Events

Light On/Off State Changed

Occurs when the light changes from on to off or off to on. Any level greater than zero is considered on.

Whenever Filter:


EventArgs:


Ready State Changed

The device's running and ready state changed.

Whenever Filter:

none

EventArgs:


Received Command

Occurs when a command is received.

Whenever Filter:


EventArgs:


Instance Properties

LightLevels

Gets the percent on level of the X10 nodes. 0-100

Accessibility : Read Only

Type: Array

LightOnOffs

Gets or sets the light to a fully on state or fully off.

Accessibility : Read Only

Type: Array

LightNames

Gets the names of the lights.

Accessibility : Read Only

Type: Array

DeviceDisplayName

The display name for this device.

Accessibility : Read Only

Type: String

DeviceStartTime

The date and time when this device was started.

Accessibility : Read Only

Type: DateTime

DeviceLifecycleStage

The current lifecycle stage of the device. The stages in order are: Pending Start, Starting, Running, Stopping

Accessibility : Read Only

Type: Number

DeviceIsRunningAndReady

Indicates if the device is ready for use, ie it is in the Running lifecycle stage and all properties are valid and all methods are ready to be used.

Accessibility : Read Only

Type: Boolean

Instance Methods

TurnOnPlc ( String, Number )

Turns on an X10 device.

Syntax

void TurnOnPlc( String houseCode, Number deviceCode )

Parameters

houseCode : The X10 house code of the device. (A-P)
deviceCode : The X10 unit code (1-16).

TurnOffPlc ( String, Number )

Turns off an X10 device.

Syntax

void TurnOffPlc( String houseCode, Number deviceCode )

Parameters

houseCode : The X10 house code of the device. (A-P)
deviceCode : The X10 unit code (1-16).

BrightenPlc ( String, Number, Number )

Brightens an X10 device.

Syntax

void BrightenPlc( String houseCode, Number deviceCode, Number percent )

Parameters

houseCode : The X10 house code of the device. (A-P)
deviceCode : The X10 unit code (1-16).
percent : The percent to brighten.

DimPlc ( String, Number, Number )

Dims the most recently referenced X10 device in the specified house code.

Syntax

void DimPlc( String houseCode, Number deviceCode, Number percent )

Parameters

houseCode : The X10 house code of the device. (A-P)
deviceCode : The X10 unit code (1-16).
percent : The percent to brighten.

AllLightsOnPlc ( String )

Turns on all X10 lights in the specified house code.

Syntax

void AllLightsOnPlc( String houseCode )

Parameters

houseCode : The X10 house code of the device. (A-P)

AllUnitsOffPlc ( String )

Turns off all X10 devices in the specified house code.

Syntax

void AllUnitsOffPlc( String houseCode )

Parameters

houseCode : The X10 house code of the device. (A-P)

ExtendedCommandPlc ( String, Number, String, String )

Send an extended X10 command via PLC.

Syntax

void ExtendedCommandPlc( String houseCode, Number deviceCode, String hexCommand, String hexValue )

Parameters

houseCode : The X10 house code of the device. (A-P)
deviceCode : The X10 unit code (1-16).
hexCommand : The percent to brighten.
hexValue : The percent to brighten.

TurnOnRF ( String, Number )

Turns on an X10 device.

Syntax

void TurnOnRF( String houseCode, Number deviceCode )

Parameters

houseCode : The X10 house code of the device. (A-P)
deviceCode : The X10 unit code (1-16).

TurnOffRF ( String, Number )

Turns off an X10 device.

Syntax

void TurnOffRF( String houseCode, Number deviceCode )

Parameters

houseCode : The X10 house code of the device. (A-P)
deviceCode : The X10 unit code (1-16).

BrightenRF ( String, Number, Number )

Brightens the most recently referenced X10 device in the specified house code.

Syntax

void BrightenRF( String houseCode, Number deviceCode, Number percent )

Parameters

houseCode : The X10 house code of the device. (A-P)
deviceCode : The X10 unit code (1-16).
percent : The percent to brighten.

DimRF ( String, Number, Number )

Dims the most recently referenced X10 device in the specified house code.

Syntax

void DimRF( String houseCode, Number deviceCode, Number percent )

Parameters

houseCode : The X10 house code of the device. (A-P)
deviceCode : The X10 unit code (1-16).
percent : The percent to brighten.

AllLightsOnRF ( String )

Turns on all X10 lights in the specified house code.

Syntax

void AllLightsOnRF( String houseCode )

Parameters

houseCode : The X10 house code of the device. (A-P)

AllLightsOffRF ( String )

Turns off all X10 lights in the specified house code.

Syntax

void AllLightsOffRF( String houseCode )

Parameters

houseCode : The X10 house code of the device. (A-P)

AllUnitsOffRF ( String )

Turns off all X10 devices in the specified house code.

Syntax

void AllUnitsOffRF( String houseCode )

Parameters

houseCode : The X10 house code of the device. (A-P)

TurnOnLight ( Number )

Turns on the specified light.

Syntax

void TurnOnLight( Number deviceID )

Parameters

deviceID : The id of the light (1-256).

TurnOffLight ( Number )

Turns off the specified light.

Syntax

void TurnOffLight( Number deviceID )

Parameters

deviceID : The id of the light (1-256).

SetLightLevel ( Number, Number )

Sets the specified light's level to the specified percent.

Syntax

void SetLightLevel( Number deviceID, Number percentOn )

Parameters

deviceID : The id of the device (1-256).
percentOn : The percent level to set the light to. Valid values: 0 to 100 where 0 is typically off and 100 is fully on.

TurnOnAllLights

Turns all lights on.

Syntax

void TurnOnAllLights( )

Parameters

none

TurnOffAllLights

Turns all lights off (via RF only).

Syntax

void TurnOffAllLights( )

Parameters

none

TurnOnLightByName ( String )

Turns on the specified light.

Syntax

void TurnOnLightByName( String name )

Parameters

name : The name of the light.

TurnOffLightByName ( String )

Turns off the specified light.

Syntax

void TurnOffLightByName( String name )

Parameters

name : The name of the light.

SetLightLevelByName ( String, Number )

Sets the specified light's % level to the specified percent.

Syntax

void SetLightLevelByName( String name, Number percentOn )

Parameters

name : The name of the light.
percentOn : The brightness percent level to set the device to. (0-100)

SetLightLevelForDuration ( Number, TimeSpan, Number, Number )

Sets a light's level for a duration of time and then sets the light to a subsequent level.

Syntax

void SetLightLevelForDuration( Number iD, unknown duration, Number initialPercentOn, Number finalPercentOn )

Parameters

iD : The id of the light.
duration : The amount of time to wait before setting the light level to the specified subsequent light level.
initialPercentOn : The percent level to set the light to.
finalPercentOn : The percent level to set the light to after the duration has passed.

TurnOnLightForDuration ( Number, TimeSpan )

Turns a light fully on for a duration of time and then turns the light off.

Syntax

void TurnOnLightForDuration( Number iD, unknown duration )

Parameters

iD : The id of the light.
duration : The amount of time to wait before turning off the light.

SetPropertyForDuration ( String, TimeSpan, Object, Object )

Sets a property for a duration of time and then sets the property to a subequent value asynchronously. This action returns after setting the first value and the timer and subsequent property set run in the background. Subsequent sets of the same property will reset the timer if the subsequent value has not yet been set. This is an advanced feature, be sure to set the property name correctly.

Syntax

void SetPropertyForDuration( String propertyName, unknown duration, Object initialValue, Object finalValue )

Parameters

propertyName : The name of the property to set.
duration : The amount of time to wait after setting the initial value to set the subsequent value.
initialValue : The value to set the property to initially.
finalValue : The value to set the property to after the duration of time has passed.

SetPropertyForDuration ( String, Number, TimeSpan, Object, Object )

Sets a property for a duration of time and then sets the property to a subequent value asynchronously. This action returns after setting the first value and the timer and subsequent property set run in the background. Subsequent sets of the same property will reset the timer if the subsequent value has not yet been set. This is an advanced feature, be sure to set the property name correctly.

Syntax

void SetPropertyForDuration( String propertyName, Number arrayIndex, unknown duration, Object initialValue, Object finalValue )

Parameters

propertyName : The name of the property to set.
arrayIndex : The property's array index to set.
duration : The amount of time to wait after setting the initial value to set the subsequent value.
initialValue : The value to set the property to initially.
finalValue : The value to set the property to after the duration of time has passed.