Communication Protocol
Command code to read N words: 03H. The maximum value of N is 3.
For example, in order to read two words from controller 01 (address 01H) at starting data address 4700H, the command in ASCII mode is:
ASCII mode:
Starting data address
Number of data (counted by
LRC check:
LRC check is the added sum from "Address" to "Data content". For example, 01H + 03H + 47H + 00H + 00H + 02H = 4DH, then take the
complementary of 2, B3H.
Command code to write 1 word: 06H
For example, in order to write 1000 (03E8H) in controller 01 (comm. address 01H) at the starting data address 4701H, the command in ASCII mode
is:
ASCII mode:
Starting data address
Command message:
STX
ADR1
ADR0
CMD1
CMD0
word)
LRC CHK 1
LRC CHK 0
END 1
CR
END 0
Command message:
STX
ADR1
ADR0
CMD1
CMD0
Data content
LRC CHK 1
LRC CHK 0
CR
END 1
END 0
Response message:
':'
STX
'0'
ADR1
ADR0
'1'
'0'
CMD1
CMD0
'3'
'4'
Number of data
(count by byte)
'7'
'0'
'0'
Content of start address
4700H
'0'
'0'
'0'
'2'
Content of start address
4701H
'B'
'3'
LRC CHK 1
LRC CHK 0
LF
END 1
END 0
Response message:
':'
STX
'0'
ADR1
ADR0
'1'
'0'
CMD1
CMD0
'6'
'4'
'7'
Starting data address
'0'
'1'
'0'
'3'
Data content
'E'
'8'
'C'
LRC CHK 1
LRC CHK 0
'6'
END 1
END 0
LF
- 9 -
':'
'0'
'1'
'0'
'3'
'0'
'4'
'0'
'1'
'9'
'0'
'0'
'0'
'0'
'0'
'6'
'7'
CR
LF
':'
'0'
'1'
'0'
'6'
'4'
'7'
'0'
'1'
'0'
'3'
'E'
'8'
'C'
'6'
CR
LF