ph_getdigital PowerHome formula function
Description
Retrieves the value of an digital input / output defined in the Digital I/O screen.
Syntax
ph_getdigital ( id )
Argument |
Description |
id
|
The ID of the digital I/O as defined within the Digital I/O screen.
|
Return value
Integer. Returns the status of the digital I/O if successful (0 = off, 1 = on). Returns - 100 if the ID cannot be found. When this function is executed, the controller, unit, and point is looked up within the Digital I/O table and these values are then passed to the controller. If these values are entered improperly in the Digital I/O screen, then the following errors may be returned: - 1 is returned if the controller is not available, - 2 is returned if the controller does not support digital I/O, - 3 is returned if the unit is out of range, - 4 is returned if the point is out of range.
Usage
This function is similar to the ph_getotherdigital function except that the point MUST be defined within the Digital I/O screen.