Page 32
MNVCSM84A_1729_EN
9 APPENDIX
9.1 Macro Protocol: description
The Macro protocol is characterized by messages consisting only of printable ASCII characters, delimited by
two terminator characters ‘
[
‘ and ‘
]
’. Within the message, upper and lower case letters are differentiated and
there are NEVER any space separators. The format of a typical message consists of a character string
‘[VA1PC1VidS1,12A]’ which can be interpreted as follows:
[
Start of message
VA1
Receiver of message
(1)
Video unit number 1
PC1
Sender of message
(1)
PC number 1
VidS
Command
Switch
1
First parameter
(2)
Monitor 1
,
Parameter separator
(2)
12
Second parameter
(2)
Camera 12
A
Checksum
]
End of message
(1)
Even though in this case the Receiver and Sender units have no address it is necessary to insert an
imaginary id. number.
(2)
Depending on the command, there are a maximum of 4 numeric parameters separated by a comma: to transmit
the number 123 it is necessary to send the three characters ‘1’ (ASCII 49), ‘2’ (ASCII 50) and ‘3’ (ASCII 51).
9.1.1 Checksum calculation procedures
Calculate the sum of the ASCII codes of all the message characters, excluding the terminators ‘[‘ and ‘]’
1) calculate the value of the sum (mod 26) (the remainder after division by 26, always a whole number between
0 and 25)
2) add 65 to the calculated modulus and find the corresponding character in the ASCII table: the result should
be an upper case letter of the alphabet from ‘A’ to ‘Z’.
The message will only be interpreted by the matrix if the checksum is correct.
9.1.2 Test program example
The following is a simple test program in BASIC, which can be used as the basis to create more complicated
control systems. The program uses the serial port COM1 with baudrate 9600.
OPEN "COM1:9600,N,8,1,BIN,RB1000,DS0,CS0,CD0,RS" FOR RANDOM AS #1
COM(1) ON
ON COM(1) GOSUB Reception
DO WHILE (1)
A$ = UCASE$(INKEY$)
‘ recognises a key being pressed down
SELECT CASE A$
CASE “1”: ‘ switch camera 1 to monitor 1
PRINT #1, “[VA1PC1VidS1,1C]”;
CASE “2”: ‘switch camera 2 to monitor 1
PRINT #1, “[VA1PC1VidS1,2D]”;
CASE “S”: ‘automatic switching sequence on monitor 1
PRINT #1, “[VA1PC1VidA1V]”;
CASE CHR(27):
‘ exit program with ESC
END
END SELECT
LOOP
Reception:
DO WHILE NOT(EOF(1))
B$ = INPUT$(1,1)
IF B$ = “[” THEN PRINT
PRINT B$;
LOOP
RETURN
Summary of Contents for SM164A
Page 1: ...OPERATING INSTRUCTIONS MANUALE D USO MANUEL D INSTRUCTIONS BEDIENUNGSANWEISUNG...
Page 3: ...S S M M 8 8 4 4 A A S S M M 1 1 6 6 4 4 A A OPERATING INSTRUCTIONS...
Page 4: ......
Page 38: ...Page 34 MNVCSM84A_1729_EN...
Page 39: ...S S M M 8 8 4 4 A A S S M M 1 1 6 6 4 4 A A MANUALE D USO...
Page 40: ......
Page 74: ...Pag 34 MNVCSM84A_1729_IT...
Page 75: ...S S M M 8 8 4 4 A A S S M M 1 1 6 6 4 4 A A MANUEL D INSTRUCTIONS...
Page 76: ......
Page 110: ...Page 34 MNVCSM84A_1729_FR...
Page 111: ...S S M M 8 8 4 4 A A S S M M 1 1 6 6 4 4 A A BEDIENUNGSANWEISUNG...
Page 112: ......
Page 146: ...Seite 34 MNVCSM84A_1729_DE...
Page 147: ...S S M M 8 8 4 4 A A S S M M 1 1 6 6 4 4 A A...
Page 148: ......
Page 150: ...2 MNVCSM84A_1729_RU 5 2 24 29 30 31 32 9 1 0DFUR 32 32 32 33 33 33...
Page 152: ...4 MNVCSM84A_1729_RU 1 4 SM84A SM164A x x x x x x x x x x x x 1 5 SM84A SM164A x WHQGHG x x x 7...
Page 154: ...6 MNVCSM84A_1729_RU 3 3 1 3 1 1 3 1 2 3 2 DTRX3 DTCOAX DTMRX1 SM164A PTH910P PTH910 DCTEL PC...
Page 164: ...16 MNVCSM84A_1729_RU 4 2 SM84A SM164A x x x x 50 4 2 1 x x x 24 4 2 2 x x...
Page 165: ...17 MNVCSM84A_1729_RU 4 2 3 x DCJ DCK x x x 4 2 4...
Page 167: ...19 MNVCSM84A_1729_RU 4 4 4 4 1 x x 4 4 1 1 260...
Page 168: ...20 MNVCSM84A_1729_RU 4 4 1 2 0 M2 5 9 8 4 4 1 3 0 M2 5 X FRD...
Page 173: ...25 MNVCSM84A_1729_RU 1 25 6 4 8 9 2 4 2 22 6 4 8 9 2 5 6 4 1 326 6 4 326 1...
Page 182: ...34 MNVCSM84A_1729_RU...
Page 183: ......