You are on page 1of 3

Process-Image Input/Output Tables

Page 1 of 3

Process-Image Input/Output Tables


If the input (I) and output (Q) address areas are accessed in the user program, the program does not scan
the signal states on the digital signal modules but accesses a memory area in the system memory of the
CPU and distributed I/Os. This memory area is known as the process image.
Updating the Process Image
The following figure shows the processing steps within a scan cycle.

One of the internal tasks of the operating system (OS) is to read the status of inputs into the process image
input table (PII). Once this step is complete, the user program is executed with all blocks that are called in it.
The cycle ends with writing the process image output table (PIQ) to the outputs for the modules. Reading in
the process image input table and writing the process image output table to the outputs for the modules is all
independently controlled by the operating system.

One of the internal tasks of the operating system (OS) is to write the process image output table (PIQ) to the
outputs for the modules and to read in the status of inputs into the process image input table (PII). Once this
step is complete, the user program is executed with all blocks that are called in it. Writing the process image
output table to the outputs for the modules and reading in the process image input table is all independently
controlled by the operating system.
Advantages of the Process Image
Compared with direct access to the input/output modules, the main advantage of accessing the process
image is that the CPU has a consistent image of the process signals for the duration of one program cycle.
If a signal state on an input module changes while the program is being executed, the signal state in the
process image is retained until the process image is updated again in the next cycle. The process of
repeatedly scanning an input signal within a user program ensures that consistent input information is always
available.
Access to the process image also requires far less time than direct access to the signal modules since the

mk:@MSITStore:C:\Program%20Files\SIEMENS\STEP7\S7bin\S7BASHDB.CHM::/ba... 22.4.2009

Process-Image Input/Output Tables

Page 2 of 3

process image is located in the internal memory of the CPU.


Part Process Images (Process-Image Partitions)
In addition to having the process image (process-image input table, PII, and process-image output table,
PIQ) automatically updated by the operating system, you can assign parameters to a maximum of 15 partial
process images for an S7-400 CPU (CPU-specific, no. 1 to no. 15, see the S7-400, M7-400
Programmable Controllers Module Specifications Reference Manual). This means that you can update
sections of the process-image table, when necessary, independently of the cyclic updating of the process
image table.
Each input/output address that you assign with STEP 7 to a process-image partition no longer belongs to the
OB1 process-image input/output tables. Input and output address can only be assigned once through the OB
1 process image and all process-image partitions.
You define process-image partition with STEP 7 when you assign addresses (which input/output addresses
of the modules are listed in which process-image partition). The process-image partition is updated either by
the user with SFCs or automatically by the system by connecting to an OB.
Exception: Process image partitions for synchronous cycle interrupt OBs are not updated on the system
side, even though they are linked to an OB (OB 61 to OB 64).
Note
For S7-300 CPUs, unassigned process-image inputs and outputs can be used as
additional bit memory areas. Programs that use this capability can run on older
(that is, before 4/99) S7-400 CPUs only under one of the following conditions:
For these S7-400 CPUs


The process image areas used as bit memory must be located outside of the
parameter assignment for "Size of the Process Image" or.

must be located in a process-image partition that is updated neither by the


system nor by SFC26/SFC27.

Updating Part Process Images (Process-Image Partitions) with SFCs


You can use SFCs to update the entire process image or a process-image partition from your user program.


Requirement: The process image in question is not updated by the system.

SFC26 UPDAT_PI: Update process-image input table

SFC27 UPDAT_PO: Update process-image output table.

System Update of the Part Process Images (Process-Image Partitions)


You can also have the system update process-image partitions automatically by calling an OB - similar to the
(entire) process image, which is updated cyclically before or after OB1 is processed. You can assign this
function as a parameter only for specific CPUs.
During operation, the assigned process-image partition is updated automatically:


Before the OB is processed, the process-image partition for inputs

After the OB is processed, the process-image partition for the outputs

You assign the parameters for the CPU, along with the priority of the OBs, to indicate which process-image
partition is assigned to which OB.

mk:@MSITStore:C:\Program%20Files\SIEMENS\STEP7\S7bin\S7BASHDB.CHM::/ba... 22.4.2009

Process-Image Input/Output Tables

Page 3 of 3

I/O Access Error (PZF) during Update of the Process Image


The default reaction of the CPU families (S7-300 and S7-400) to an error during the update of the process
image varies:


S7-300: No entry is made in the diagnostic buffer, no OB is called, the corresponding input bytes are
reset to "0" and will remain at "0" until the fault is gone again.

S7-400: An entry is made in the diagnostic buffer and OB85 is started for each I/O access for each
update of the corresponding process image. The faulty input bytes are reset to "0" each time the process
image is accessed.

For new CPUs (as of 4/99), you can reassign parameters for the reaction to I/O access errors so that the
CPU functions in one of the following manners:


Generates an entry in the diagnostic buffer and starts OB85 only for incoming and outgoing PZF (before
OB 85 is called, the faulty input bytes are reset to "0" and are no longer overwritten by the operating
system until the outgoing PZF)

Produces the default reaction of an S7-300 (does not call OB85; the corresponding input bytes are reset
to "0" and are no longer overwritten by the operating system until the fault is cleared.)

Produces the default reaction of an S7-400 (calls OB85 for each individual access; the faulty input bytes
are reset to "0" each time the process image is accessed.)

How Often Does OB85 Start?


In addition to the reaction to PZF that is assigned as a parameter (incoming/outgoing, or for each I/O
access), the address space of a module also influences how often OB85 starts:
For a module with an address space of up to a double word, OB85 starts once, for example, for a digital
module with a maximum of 32 inputs or outputs, or for an analog module with two channels.
For modules with a larger address space, OB85 starts as often as access has to be made to it with double
word commands, for example, twice for an analog module with four channels.

See also:
Operating Modes and Mode Transitions
Error OBs as a Reaction to Detected Errors
Configuring Short and Equal-Length Process Reaction Times on PROFIBUS-DP

mk:@MSITStore:C:\Program%20Files\SIEMENS\STEP7\S7bin\S7BASHDB.CHM::/ba... 22.4.2009

You might also like