Using Local Variables; Using The Status Chart To Monitor Your Program - Siemens SIMATIC S7-200 System Manual

Programmable controller
Hide thumbs Also See for SIMATIC S7-200:
Table of Contents

Advertisement

Using Local Variables

You can use the local variable table of
the program editor to assign variables
that are unique to an individual
subroutine or interrupt routine. See
Figure 5-9.
Local variables can be used as
parameters that are passed in to a
subroutine and they increase the
portability or reuse of a subroutine
portability or reuse of a subroutine.

Using the Status Chart to Monitor Your Program

A status chart allows you to monitor or modify the values of the process variables as your S7-200
runs the control program. You can track the status of program inputs, outputs, or variables by
displaying the current values. The status chart also allows you to force or change the values of the
Status
process variables.
Chart
You can create multiple status charts in order to view elements from different portions of your
program.
To access the status chart, select the View > Component > Status Chart menu command or
click the Status Chart icon in the navigation bar.
When you create a status chart, you
enter addresses of process variables for
monitoring. You cannot view the status of
constants, accumulators, or local
variables. You can display a timer or
counter value either as a bit or as a
word. Displaying the value as a bit
shows the status of the timer or counter
bit; displaying the value as a word shows
bit; displaying the value as a word shows
the timer or counter value.
To build a status chart and monitor the variables:
1.
Enter the address for each desired value in the Address field.
2.
Select the data type in the Format column.
3.
To view the status of the process variables in your S7-200, select the Debug > Chart
Status menu command.
4.
To continuously sample the values, or to perform a single read of the status, click the button
on the toolbar. The Status Chart also allows you to modify or force values for the different
process variables.
You can insert additional rows in your Status Chart by selecting the Edit > Insert > Row menu
command.
Tip
You can create multiple status charts to divide the variables into logical groups so that each
group can be viewed in a shorter and separate status chart.
Programming Concepts, Conventions, and Features
Figure 5-9
Local Variable Table
Figure 5-10 Status Chart
Chapter 5
63

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents