Table of Contents

DIN-RY CFLink Protocol

The following documentation is for the DIN-RYx-N devices CFLink protocol messages. This protocol can be used regardless of connection method to the DIN-RYx device either via USB, RS232 or RS485.

Control Port Configuration

This command is used to configure the communication properties for each control port on the unit.

> [F2]<ID>[F3]CCFXSPC[F4]<PORT>:<MODE>:<BAUD>:<DATABITS>:<PARITY>:<STOP>:<FLOW CONTROL>[F5][F5]

* <PORT> would be designated as:

* <MODE> would be designated as:

> [F2][20][F3]CCFXSPC[F4]P04:BUS:115200:8:N:1:0[F5][F5]

> [F2][20][F3]CCFXSPC[F4]P02:CFL:115200:8:N:1:0[F5][F5]

Query Port Configuration

This command is used to query and get the current port settings for each control port on the unit.

> [F2]<ID>[F3]QCFXSPC[F4]<PORT>[F5][F5]    \\ Query status of individual ports
> [F2]<ID>[F3]QCFXSPC[F4][F5][F5]          \\ Query status of all ports

Sending Command to Control External Devices

This command is used to send data to control the external device depending on the port used.

> [F2]<ID>[F3]TCFXSPW[F4]<PORT>:<DATA>[F5][F5]    

Relay Commands

On / Off / Toggle

The TRLYSET (Send) command is used to send a command to the relay channels.

Data

> [F2]<ID>[F3]TRLYSET[F4]<PORT>:<STATE>[F5][F5]

Reply

< [F2]<ID>[F3]RRLYCHA[F4]<PORT>:<STATE>[F5][F5] // The reply comes from only the port where the change event happens
< [F2]<ID>[F3]RRLYSTA[F4]<PORT>:<STATE>[F5][F5] // The reply comes from all the ports 

To minimize the data traffic on the communication bus, the RRLYCHA will only reflect the affected ports only. It will also be sent as unsolicited messages when buttons on the display panel are set. The RRLYSTA reply will have all port status, separated by pipes.

Dry Contacts

Status Read

Send

> [F2]<ID>[F3]QCFXSTA[F4]<PORT>[F5][F5] // query single port
> [F2]<ID>[F3]QCFXSTA[F4][F5][F5]       // query all ports

Reply

> [F2]<ID>[F3]RCFXSTA[F4]<PORT>:<STATE>[F5][F5]  // reply with 
> [F2]<ID>[F3]RCFXCHA[F4]<PORT>:<STATE>[F5][F5]  // auto reporting

When <PORT> is specified, reply will have status of only specified port. If <PORT> is omitted, reply will have all port states. RCFXCHA will be sent as unsolicited message when port changed.

Mode Configuration

Send

> [F2]<ID>[F3]CCFXDCP[F4]<Port>:<Mode>:<Double Tap Time>:<Hold Time>[F5][F5]
> [F2]<ID>[F3]CCFXDCP[F4]<Port>:<Mode>:<Timeout Time>:<Trigger State>[F5][F5]

Reply

> [F2]<ID>[F3]RCFXDCP[F4]<Port>:<Mode>:<Double Tap Time>:<Hold Time>[F5][F5]

In Normal mode, dry contacts work as currently - report state on change, on press and on release. <Double Tap Time> and <Hold Time> can be omitted from command when setting normal mode.

> [F2]<ID>[F3]RCFXCHA[F4]<PORT>:<STATE>[F5][F5] // <STATE> = 1 for press or 0 for release.

In Timer mode, dry contacts report on change as normal to start, but do not report any CHA or STA again until the timer goes out. Still report if manually requested via QCFXSTA regardless of timer.

Each time the port “trigger state” is reached, the timer will restart. Only once it times out (the time elapses with no state changes) will it begin to start sending state changes again.

When the timer times out, it will also send a special replyRCFXTUP for indicating the time is up with the port number as the data. For example:

> [F2]<ID>[F3]RCFXTUP[F4]<PORT>[F5][F5] // <PORT> = P01 or P02, etc.

An example on Timer:

A command is sent with Port 1 defined as timer mode with timer as 300s, trigger on close.

> [F2]<ID>[F3]CCFXDCP[F4]P01:T:3000:1[F5][F5] 

→ Port 1 closes: (timer = 0s)

> [F2]<ID>[F3]RCFXCHA[F4]P01:1[F5][F5] 

→ 10 secs later, Port 1 closes: (time = 10s) <no report, timer restarts>

→ 290 secs later from last event, Port 1 closes: (time = 300s) <no report, timer restarts>

→ 300 secs later from last event, and Port 1 is now open: (time = 600s)

> [F2]<ID>[F3]RCFXCHA[F4]P01:0[F5][F5] // reports state
> [F2]<ID>[F3]RCFXTUP[F4]P01[F5][F5] // timeout 

Another example:

Time from 0 Event Bus Traffic Timer
Before 0s inactive
0sMotion trigger on port 1\xF2<ID>\xF3RCFXCHA\xF4P01:1\xF5\xF5started (300s)
10sMotion trigger on port 1(port closes)<no report>re-started(300s)
15sPort 1 opens<no report>No effect
20sMotion trigger on port 1(port closes)<no report>re-started (300s)
25sPort 1 opens<no report>No effect
320sNo event\xF2<ID>\xF3RCFXCHA\xF4P01:0\xF5\xF5Timer completed
~320sNo event\xF2<ID>\xF3RCFXTUP\xF4P01\xF5\xF5Timer completed
350sMotion trigger on port 1 (port closes)\xF2<ID>\xF3RCFXCHA\xF4P01:1\xF5\xF5started (300s)
650sNo event\xF2<ID>\xF3RCFXSTA\xF4P01:1\xF5\xF5
~650sNo event\xF2<ID>\xF3RCFXTUP\xF4P01\xF5\xF5Timer completed
660sPort 1 opens<no report>No effect
670sMotion trigger on port 1 (port closes)\xF2<ID>\xF3RCFXCHA\xF4P01:1\xF5\xF5Timer “restarts” (300s)

In Advanced mode, dry contacts will have no reports on press or release. Instead, it reports physical “gestures” - single tap (press), double tap (press) or held on change (press and hold) based on timing configuration:

> [F2]<ID>[F3]RCFXCHA[F4]<PORT>:<STATE>[F5][F5] // <STATE> = S for Single Tap, D for Double Tap OR H for Hold

For example, let's configure a dry contact as Advanced mode P01:A:15:30 where Double Tap time = 1.5 seconds, Hold time = 3.0 seconds

A Single Tap is reported if the 1x press and 1x release is detected within the double tap time (1.5 seconds). A single tap will not be reported til after the double tap time has lapsed.

A Double Tap is reported if the 2x presses and 2x releases are detected within the double tap time (1.5 seconds).

A Hold is then reported if 1x press with no release is detected within the hold time (3 seconds).

Start is defined by the detection of the first press. End is defined when a report is made. All timings are PER PORT.

Therefore a report of an event should be either a S, D OR H. A “single” event CANNOT report multiple types of presses.

Valid time values are 000:100 where 100 = 10 seconds

> [F2]<ID>[F3]CCFXDCP[F4]<PORT_CONFIG>[F5][F5] \\ Send
> [F2]<ID>[F3]RCFXDCP[F4]<PORT_CONFIG>[F5][F5] \\ Reply

For Example:

> [F2]<ID>[F3]CCFXDCP[F4]P01:A:15:300|P02:N|P03:N[F5][F5] \\ Send
> [F2]<ID>[F3]RCFXDCP[F4]P01:A:15:300|P02:N|P03:N[F5][F5] \\ Reply

AC Load Status Read

> [F2]<ID>[F3]QCFXACS[F4]<PORT>:<STATE>[F5][F5] \\ Query AC Load Status
> [F2]<ID>[F3]RCFXACS[F4]<PORT>:<STATE>[F5][F5] \\ Reply

Conditional commands based on variable states

> [F2]<ID>[F3]TCFXCON[F4]<CONDITION>[F6]<ACTION>[F5][F5]  \\ Send
> [F2]<ID>[F3]RCFXCON[F4]<BOOLEAN>[F5][F5]                \\ Reply

Example of command syntax to send:

> [F2]<ID>[F3]TCFXCON[F4]<VARIABLE><OPERATOR><VALUE>[F6]<TARGET_ID>:<COMMAND>:<DATA>[F5][F5]  \\ Syntax
> [F2]<ID>[F3]TCFXCON[F4]01==1[F6]00:TRLYSET:M2|P02:1[F5][F5] 
> [F2]<ID>[F3]RCFXCON[F4]TRUE[F5][F5]                                                          \\ Reply                                 

Conditional ON and OFF based on AC Status read

> [F2]<ID>[F3]TRLYCON[F4]<CONDITION>|<ACTION>[F5][F5]  \\ Send
> [F2]<ID>[F3]RRLYCON[F4]<BOOLEAN>[F5][F5]             \\ Reply                                 

> [F2]<ID>[F3]TRLYCON[F4]S01:1|P01:1[F5][F5]  \\ If AC State 1 is ON, then Set Port 1 to L1

> [F2]<ID>[F3]TRLYCON[F4]S01:0|P01:2[F5][F5]  \\ If AC State 1 is OFF, then set relay port 1 to L2
> [F2]<ID>[F3]TRLYCON[F4]S01:0|P01:T[F5][F5]  \\ If AC State 1 is OFF, then toggle relay port 1, effectively turning ON circuit 1 when status reads OFF.
> [F2]<ID>[F3]TRLYCON[F4]S01:1|P02:T[F5][F5]  \\ If AC State 1 is ON, then toggle relay port 2.
> [F2]<ID>[F3]TRLYCON[F4]SZZ:1|PZZ:1[F5][F5]  \\ All ports.If AC State 1 is ON, then Set Port 1 to L1, If AC State 2 is ON, then Set Port 2 to L1, etc. until If AC State 8 is ON, then Set Port 8 to L1.

User Variable

You can use user variables to store strings or values that can be retrieved anytime for use later.

The CVARSET (Send) command is used to assign a value to the defined user variable.

Data

> [F2]<ID>[F3]CVARSET[F4]<VARIABLE_NAME>:<VALUE>[F5][F5]

Reply

< [F2]<ID>[F3]RVARSET[F4]<VARIABLE_NAME>:<VALUE>[F5][F5] 

There are two variable query commands available - QVARLST command is used to query all available variables and its respective values. QVARGET command is used to query a specific variable value.

Data

> [F2]<ID>[F3]QVARLST[F4][F5][F5] \\ Query value for all variables
> [F2]<ID>[F3]QVARGET[F4]<VARIABLE_NAME>[F5][F5] \\ Query value for specific variable

Reply

< [F2]<ID>[F3]RVARGET[F4]<VARIABLE_NAME>:<VALUE>[F5][F5]