Parameter OUT string format rules:
● Leading space characters are added to the leftmost part of the string when the converted
● When the FORMAT parameter sign bit is FALSE, unsigned and signed integer data type
● When the sign bit is TRUE, unsigned and signed integer data type values are written to
● When the FORMAT is set to exponential notation, Real data type values are written to the
● When the FORMAT is set to fixed point notation, integer, unsigned integer, and real data
● Leading zeros to the left of the decimal point (except the digit adjacent to the decimal
● Values to the right of the decimal point are rounded to fit in the number of digits to the
● The size of the output string must be a minimum of three bytes more than the number of
● Values are right-justified in the output string.
Conditions reported by ENO
When an error is encountered during the conversion operation, the following results will be
returned:
● ENO is set to 0.
● OUT is set to 0, or as shown in the examples for string to value conversion.
● OUT is unchanged, or as shown in the examples when OUT is a string.
Table 8- 30
ENO status
ENO
Description
1
No error
0
Illegal or invalid parameter; for example, an access to a DB that does not exist
0
Illegal string where the maximum length of the string is 0 or 255
0
Illegal string where the current length is greater than the maximum length
0
The converted number value is too large for the specified OUT data type.
0
The OUT parameter maximum string size must be large enough to accept the number of characters
specified by parameter SIZE, starting at the character position parameter P.
S7-1200 Programmable controller
System Manual, 03/2014, A5E02486680-AG
string is smaller than the specified size.
values are written to the output buffer without the leading "+" sign. The "-" sign is used if
required.
the output buffer always with a leading sign character.
output buffer as:
type values are written to the output buffer as:
point) are suppressed.
right of the decimal point specified by the PREC parameter.
digits to the right of the decimal point.
Extended instructions
8.2 String and character
299