Delta ISPSoft — 6.2.3 Principles of ARRAY or STRING Symbol

Chapter 6 Symbol Variables whose data type is STRING is generally used with an applied instruction. Please refer to the programming manual for a model for more information. When users declare a symbol whose data type is STRING, they can specify the maximum size of the string. The number of characters in a string is within the range between 1 and 128, and one character occupies 1 byte. The number of devices assigned to the characters in a string must conform to the size of the string, and one extra byte must be assigned to the ending character in the string.

If the last character and the ending character in a string does not occupy the two bytes in a word device, the ending character will be assigned another device. For example, two word devices (four bytes) will be assigned to a string which is composed of three characters, and three word devices (six bytes) will be assigned to a string which is composed of four or five characters. Please refer to the following figure. The number in the parentheses in the Type… cell for a symbol whose data type is STRING indicates the maximum size of the string.

The characters in the Initial Value cell for a symbol whose data type is STRING cannot be put in double quotes, and the number of characters in the Initial Value cell for the symbol whose data type is STRING must be less than or equal to the maximum number of characters in the string. When using DVPxxMC and AS5xx, users do not need to adjust because the string length declared is allocated by software. For initial value assigned, the character length of an initial value is 0~32000 characters. After declaring, the maximum length of characters is not shown in the brackets beside STRING type. DVPxxMC/ AS5xx 6-31 Input character length range is 0~32000