Page 1 of 1

RTI Relay Protocol

Posted: Sat May 26, 2018 11:34 am
by Barf
On RemoteCentral I stubled upon this post, see also this. It is a protocol for controlling an "RTI RCM-4 Relay module". There are Pronto Hex codes at the end of the post. There seems to be 4 relays, each having an on- and an off-command.

It is a pure biphase 75-bit code. I have not seen that one before. Using IrpTransmogrifier, I managed to "crack the code", and came up with the Irp-form

Code: Select all

{40.244k,398,msb}<1,-1|-1,1>(1,A:31,F:1,F:8,D:23,D:8,0:4,-19.5m)*{A=2145419392}[F:0..1,D:0..255]
For this, I set F = 0 for the off-command and F=1 for the corresponding on-command. The parameter D = 8 for relay 1, D = 4 for relay 2, D = 2 for relay 3, and D = 1 for relay 4.
(It is possible to use a more natural parametrization, e.g. D = 1 << (4 - N) (for N the relay number), but IrScrutinizer presently does not accept it (as opposed to IrpTransmogrifier), and IrpTransmogrifier can use the first but not the second for decoding.

Posted: Mon May 28, 2018 7:57 pm
by The Robman
When we write bi-phase executors, we are forced to treat 0 as the reversed pair, but in this case, I think the original intent was reversed, so:

-400 +400 = 1
+400 -400 = 0

Using that, I got the following binary:

Repeat: +400; 11 11111111 00000100 00000100 00000100 00000100 00000000 00000000 01000000 01000000 +400 -20000; Relay 1 On
Repeat: +400; 11 11111111 00000100 00000100 00000000 00000000 00000000 00000000 01000000 01000000 +400 -20000; Relay 1 Off
Repeat: +400; 11 11111111 00000100 00000100 00000100 00000100 00000000 00000000 00100000 00100000 +400 -20000; Relay 2 On
Repeat: +400; 11 11111111 00000100 00000100 00000000 00000000 00000000 00000000 00100000 00100000 +400 -20000; Relay 2 Off
Repeat: +400; 11 11111111 00000100 00000100 00000100 00000100 00000000 00000000 00010000 00010000 +400 -20000; Relay 3 On
Repeat: +400; 11 11111111 00000100 00000100 00000000 00000000 00000000 00000000 00010000 00010000 +400 -20000; Relay 3 Off
Repeat: +400; 11 11111111 00000100 00000100 00000100 00000100 00000000 00000000 00001000 00001000 +400 -20000; Relay 4 On
Repeat: +400; 11 11111111 00000100 00000100 00000000 00000000 00000000 00000000 00001000 00001000 +400 -20000; Relay 4 Off

You'll notice that each byte is repeated. The first two pairs are fixed. The next 2 pairs have a bit that implies ON and OFF. The next two are fixed and zero filled. The final two use the bit position to indicate which Relay is being controlled.

If someone has one of these that they want to control with a JP1 remote, it shouldn't be too hard to write an executor.

Here's an RMIR file for anyone wanting to see it for themselves:
http://www.hifi-remote.com/forums/dload ... e_id=25233