turtle wrote:Your work (below) is greatly appreciated, this is the functionality that I am looking for. Can you provide sample code showing how you programmed the device and are triggering on the raw data?
turtle,
I went ahead and associated the Zen17 as usual and assigned it to an indigo zwave device. It shows up as a root device with two binary switch endpoints/devices.
As for configuring the Zen17 device, I set the following parameters. These settings decouple the S1/2 inputs from their respective relays, and set them to report status as open/closed.
p2 => 10 (set S1 to on/off report)
p3 => 10 (set S2 to on/off report)
p10 => 0 (relay 1 trigger disabled)
p11 => 0 (relay 2 trigger disabled)
No need to re-associate the Zen17 or change the device assignment.
The relay outputs can be controlled as normal through the indigo device instance. However, you cannot use or trust the device state reported for the relays as the current indigo device implementation updates the relay device states when receiving either relay status updates or S1/2 input status updates. This means that if you set a relay to on, if the corresponding S input is subsequently reported as off the reported relay on state condition will be set to off even though it does not actually change the relay output state.
To correctly monitor the states of the relays and S1/2 inputs, I created triggers for on and off of each endpoint/device. These triggers execute on zwave command received using the patterns I indicated above. The triggers are used to update a variable which represents the respective endpoint/device state. The variables can then be used wherever the device state representation is needed, including other triggers, control pages, etc.
For example, I have a variable defined as MainWaterValveState. This variable is set to true when a Relay 1 State On status command trigger is executed. The variable is set to false when a Relay 1 State Off command trigger is executed. Whenever indigo sends the command to change the relay output, the Zen17 reports the status of the relay, which in turn is used to update the variable.
There is no corresponding indigo device associated with the S1/2 input in this configuration, so a variable implemented as in the previous example becomes your state indication of the S1/2 input. Once again, this variable is used for other triggers and status reporting on control pages.
I do need to reiterate that you cannot use the indigo reported device state for the relays when the Zen17 is configured in this way. This includes both the device indicated in the home window and status update messages in the log which can be a little confusing. You will need to create a use a custom control page that shows the true state of your assigned variables.
Hope this is helpful.