DigiTrace TCONTROL-CONT-03 Manual page 16

Compact microprocessor controller
Hide thumbs Also See for TCONTROL-CONT-03:
Table of Contents

Advertisement

Available languages

Available languages

2 Protocol description
Character
H
strings
(texts)
Example for
data type
TEXT4
16
Character strings (texts) are transmitted in the ASCII format.
To mark the end, the last character to be transmitted can be a "\0"
(ASCII code 0x00). Characters after this mark are without
significance.
The address tables show the max. possible number of characters in a
data type, e.g. "TEXT24" (24 characters). When an end mark is used,
then only 23 readable characters are available for the text in this
example.
If no end mark is used, the use of the maximum number of characters
(e.g. TEXT8 = 8 characters) indicated in the data type is required. This
prevents characters still contained in the memory from being
appended to the text.
Knowing that the transmission of texts takes place word by word (16
bits), 0x00 is additionally appended where an odd number of
characters is used (incl. "\0").
Read the text (here: "AbC ") under address 0x0067 (a max. of 4 characters can
be saved)
ASCII code for "AbC " (with one space at the end):
0x41, 0x62, 0x43, 0x20
Request: 01 03 0067 0002 (+ 2 byte CRC16)
Slave address = 01
Function = 03, i.e. read n words
Address = 0067
Number of words to be read = 0002, because of the maximum of 4
characters
Response: 01 03 04 41 62 43 20 (+ 2 byte CRC16)
Slave address = 01
Function = 03, i.e. read n words
Number of bytes read = 04
Variant:
ASCII code for "Ab" (without a space at the end):
0x41, 0x62, 0x00
ASCII 0x00 ("\0") marks the end of the character string.
During transmission, 0x00 is additionally appended to obtain an even number
of characters.
Response in this case: 01 03 04 41 62 00 00 (+ 2 byte CRC16)

Hide quick links:

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the TCONTROL-CONT-03 and is the answer not in the manual?

Questions and answers

Related Products for DigiTrace TCONTROL-CONT-03

Table of Contents