ph_upblink PowerHome formula function
Description
Control a set of linked UPB devices.
Syntax
ph_upblink ( id, cmd, arg1, arg2 )
Argument |
Description |
id |
String. The ID of the UPB link to control. |
cmd |
Integer. The UPB command to send to the linked devices. |
arg1 |
Integer. Argument 1 for the command. |
arg2 |
Integer. Argument 2 for the command. |
Return value
Integer. Returns a 0 if successful. Returns - 100 if the ID cannot be found.
-1 is returned if the controller is not available, -2 is returned if the
controller does not support UPB.
Usage
Use this funciton to send UPB commands to a group of linked devices. Valid
commands are 32 for Activate Link (arg1 and arg2 are ignored), 33 for
Deactivate Link (arg1 and arg2 are ignored), 34 for Goto (arg1 is level,
arg2 is ramp), 35 for Fade Start (arg1 is level, arg2 is ramp), 36 for
Fade Stop (arg1 and arg2 ignored), 37 for Blink (arg2 is blink rate),
38 for Indicate (arg1 is level, arg2 is ramp). You
can also use the enumerated values uactlink, udeactlink, ugoto, ufadestart,
ufadestop, ublink, and uindicate.