Siemens SIMATIC CP 340 User Manual page 57

Ptp coupling and configuration
Hide thumbs Also See for SIMATIC CP 340:
Table of Contents

Advertisement

Variables
Up to 4 variables (3 + a message text number) can be displayed in a message text. The
values of variables can be transmitted from the CPU to the CP 340. The following can be
displayed as variables: Calculated values of the user program, such as: levels), date and
time, strings (string variables), or other message texts.
A conversion statement must be specified in the configured message text or in the format
string for each variable, and the meaning and output format of the variable value must be
encoded in this statement.
Format string
The format string allows you to define the display type and composition of a message text.
The format string can consist of:
● Text (all printable characters, for example: The level ... l was reached at ... hours.)
● Conversion statements for variables (e.g., %N = pointer to message text number x, where
● Control statements with control characters for bold, condensed, expanded, italic, and
You can use other control characters if you enter them in the control character table in the
CP 340: Point-to-Point Communication, Parameter Assignment user interface and reset the
CP 340 parameters.
Additional information is available in the section "Conversion and Control Statements for
Printer Output (Page 77)".
Additional functions
In addition to outputting message texts, you can use the following functions for printout. To
execute one of these functions, simply specify it in the format string in the same way.
● Set page number (format string = %P)
● Begin new page (format string = \F)
● Print with/without line break (\x at the end of the format string)
Please note that a line feed is carried out by default after each output.
PtP coupling and configuration of CP 340
Manual, 04/2011, A5E00369892-03
x is the value of a variable (see example 2 below)).
There must be one (and only one) conversion statement for each variable in the format
string or configured message text. The conversion statements are applied to the variables
in the sequence in which they occur.
underlining (e.g., \B = bold type on) or with additional control characters you have defined
Basic Principles of Serial Data Transmission
2.6 Data transmission with the printer driver
57

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents