License, Copyright, and Trademark
The content contained in this repository is the intellectual property of Snap One, LLC, (formerly known as Wirepath Home Systems, LLC), and use without a valid license from Snap One is strictly prohibited. The user of this repository shall keep all content contained herein confidential and shall protect this content in whole or in part from disclosure to any and all third parties except as specifically authorized in writing by Snap One.
License and Intellectual Property Disclaimer
The content in this repository is provided in connection with Snap One products. No license, express or implied, by estoppal or otherwise, to any intellectual property rights is granted by this document or in this repository. Except as provided in Snap Oneʼs terms and conditions for the license of such products, Snap One and its affiliates assume no liability whatsoever and disclaim any express or implied warranty, relating to the sale and/or use of Snap One products including liability or warranties relating to fitness for a particular purpose, merchantability, or infringement of any patent, copyright or other intellectual property right. Snap One products are not intended for use in medical, lifesaving, or life sustaining applications.
Information regarding third-party products is provided solely for educational purposes. Snap One is not responsible for the performance or support of third-party products and does not make any representations or warranties whatsoever regarding the quality, reliability, functionality or compatibility of these products. The reader is advised that third parties can have intellectual property rights that can be relevant to this repository and the technologies discussed herein, and is advised to seek the advice of competent legal counsel regarding the intellectual property rights of third parties, without obligation of Snap One.
Snap One retains the right make changes to this repository or related product specifications and descriptions in this repository, at any time, without notice. Snap One makes no warranty for the use of this repository and assumes no responsibility for any errors that can appear in the repository nor does it make a commitment to update the content contained herein.
Copyright
Copyright 2024 Snap One, LLC. All rights reserved.
The above copyright notice applies to all content in this repository unless otherwise stated explicitly herein that a third-party’s copyright applies.
No part of this publication may be reproduced, photocopied, stored on a retrieval system, or transmitted without the express written consent of the publisher.
Trademarks
Snap One and Snap One Logo, Control4 and the Control4 logo, and DriverWorks are trademarks or registered trademarks of Snap One, LLC. Other product and company names mentioned in this repository may be the trademarks or registered trademarks of their respective owners.
Derivative Works
To the extent that you create any “Derivative Work” (meaning any work that is based upon one or more preexisting versions of the work provided to you in this repository, such as an enhancement or modification, revision, translation, abridgement, condensation, expansion, collection, compilation or any other form in which such preexisting works may be recast, modified, transformed or adapted, explicitly including without limitation, any updates or changes to Snap One, LLC’s software code or intellectual property) such Derivative Work shall be owned by Snap One, LLC and all right, title and interest in and to each such Derivative Work shall automatically vest in Snap One, LLC. To the extent any Derivative Work does not automatically vest in Snap One, LLC by operation of law, you hereby assign such Derivative Work to Snap One, LLC with full title guarantee. Snap One, LLC shall have no obligation to grant you any right in any such Derivative Work.
Contact Us
Snap One, LLC 11734 S. Election Road Salt Lake City, UT 84020 USA
Introduction
This documentation includes content that details the functions that make up the Relay Control Proxy which is supported in the DriverWorks Software Development Kit.
Proxies (Commands)
A proxy driver is an interface to the Control4 system for a set of devices that share common functionality. For instance, most relays have common controls such as OPEN, CLOSE and TOGGLE. The relay proxy allows for a common user interface to control all relays. The Control4 system (Director) sends information to and receives information from the proxy drivers. The proxy drivers send information to and receives information from the protocol drivers. Remember, your DriverWorks driver interacts with the proxy driver which then interacts with the system. As a driver developer you will be relying on this proxy to provide status (notification) to the Control4 system for the device you are controlling. You will also receive commands from the system that you will act on to control the device. These commands and notifications are at the heart of what you will be implementing in your driver. Essentially your driver is becoming the go-between from the Control4 system and your device with the proxy driver giving structure to the commands and notifications which you will be implementing. Your driver can facilitate communications with multiple types of proxies for a single device. As an example, a Security System driver will utilize both the Security proxy and the Contacts proxy. These additional proxies are configured in the <connections> section of the .c4z.
Protocol (Notifications)
Two similar devices may have the same functionality but utilize a very different command set. A protocol driver provides the device-specific information needed to communicate with the Control4 system. In the case of DriverWorks, the DriverWorks driver is the protocol driver. When combined with the device-specific.c4Z file it provides the custom code necessary to implement the 2-way device driver. In the case of DriverWorks, the DriverWorks driver is the protocol driver. When combined with the device-specific.c4Z file it provides the custom code necessary to implement the 2-way device driver.
What’s New
What’s New in 3.4.2
There were no modifications to the Relay Proxy in conjunction with O.S. Release 3.4.2.
What’s New in 3.4.1
There were no modifications to the Relay Proxy in conjunction with O.S. Release 3.4.1.
What’s New in 3.4.0
There were no modifications to the Relay Proxy in conjunction with O.S. Release 3.4.0.
What’s New in 3.3.2
There were no modifications to the Relay Proxy in conjunction with O.S. Release 3.3.2.
What’s New in 3.3.1
There were no modifications to the Relay Proxy in conjunction with O.S. Release 3.3.1.
What’s New in 3.3.0
There were no modifications to the Relay Proxy in conjunction with O.S. Release 3.3.0.
What’s New in 3.2.3
There were no modifications to the Relay Proxy in conjunction with O.S. Release 3.2.3.
What’s New in 3.2.2
There were no modifications to the Relay Proxy in conjunction with O.S. Release 3.2.2.
What’s New in 3.2.1
There were no modifications to the Relay Proxy in conjunction with O.S. Release 3.2.1.
What’s New in 3.2.0
There were no modifications to the Relay Proxy in conjunction with O.S. Release 3.2.0.
What was New in 3.1.2
There were no modifications to the Relay Proxy in conjunction with O.S. Release 3.1.2.
What was New in 3.1.0
There were no modifications to the Relay Proxy in conjunction with O.S. Release 3.1.0.
What was New in O.S.3
There were no modifications to the Relay Proxy in conjunction with O.S. Release 3.0.0.
Relay Overview
NON-PROXY DEVICE: RELAY OVERVIEW
This area of the Proxy and Protocol Guide contains information regarding commands and notifications for a developing a Relay driver. Together, these provide an interface for controlling the Relay. Generic commands such as On, Off, etc. are supported for controlling the Relay while feedback is received through the notifications to update the Control4 User Interface.
Relay Commands
CLOSE
Close relay.
Signature
CLOSE ()
Parameters
None
Returns
None
OPEN
OPEN relay.
Signature
OPEN ()
Parameters
None
Returns
None
TOGGLE
TOGGLE relay.
Signature
TOGGLE ()
Parameters
None
Returns
None
TRIGGER
TRIGGER relay.
Signature
TRIGGER ()
Parameter | Type | Description |
---|---|---|
TIME | INT | Milliseconds |
Returns
None
Relay Notifications
CLOSED
Relay has closed.
Signature
CLOSED ()
Parameters
None
Returns
None
OPENED
Relay has opened.
Signature
OPENED ()
Parameters
None
Returns
None
STATE_CLOSED
Relay remains in the closed state. Does not indicate a change in state.
Signature
STATE_CLOSED ()
Parameters
None
Returns
None
Usage Note
Send STATE_CLOSED
when the device initializes rather than CLOSED
. The driver will ignore the STATE_CLOSED
from the standpoint of events since it is not a state change but just a notification of the current state.
STATE_OPENED
Relay remains in the open state. Does not indicate a change in state.
Signature
STATE_OPENED ()
Parameters
None
Returns
None
Usage Note
Send STATE_OPENED
when the device initializes rather than OPENED
. The driver will ignore the STATE_OPENED
from the standpoint of events since it is not a state change but just a notification of the current state.