hit counter script

String And Character Instructions; String Data Overview; String Conversion Instructions - Siemens SIMATIC S7 System Manual

Hide thumbs Also See for SIMATIC S7:
Table of Contents

Advertisement

Programming instructions
6.2 Extended instructions
RET_VAL (W#16#....)
8083
8084
8085
8086
8087
80B0
6.2.3

String and character instructions

6.2.3.1

String data overview

String data type
String data is stored as a 2-byte header followed by up to 254 character bytes of ASCII
character codes. A String header contains two lengths. The first byte is the maximum length
that is given in square brackets when you initialize a string, or 254 by default. The second
header byte is the current length that is the number of valid characters in the string. The
current length must be smaller than or equal to the maximum length. The number of stored
bytes occupied by the String format is 2 bytes greater than the maximum length.
Initialize your String data
String input and output data must be initialized as valid strings in memory, before execution
of any string instructions.
Valid String data
Valid string has a maximum length that must be greater than zero but less than 255. The
current length must be less than or equal to the maximum length.
Strings cannot be assigned to I or Q memory areas.
For more information see: Format of the String data type (Page 57)
6.2.3.2

String conversion instructions

String to value and value to string conversions
You can convert number character strings to number values or number values to number
character strings with these instructions:
● S_CONV converts (number string to a number value) or (number value to a number
● STRG_VAL converts a number string to a number value with format options
● VAL_STRG converts a number value to a number string with format options
136
Description
Illegal day value
Illegal hour value
Illegal minute value
Illegal second value
Illegal nanosecond value
The real-time clock has failed
string)
S7-1200 Programmable controller
System Manual, 11/2009, A5E02486680-02

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Simatic s7-1200

Table of Contents

Save PDF