Siemens SINUMERIK 840Di Function Manual page 1210

Basic machine
Hide thumbs Also See for SINUMERIK 840Di:
Table of Contents

Advertisement

Detailed Description
2.4 Starting up the PLC program
The For Each...Next Block programmed above can be programmed in the Delphi
programming language as follows (the programming for C, C++ programming languages is
similar).
Var
EnumVar: IEnumVariant;
rgvar: OleVariant;
fetched: Cardinal;
//For Each Next
EnumVar := (S7Prog.Next._NewEnum) as IEnumVariant;
While (EnumVar.Next(1,rgvar,fetched) = S_OK) Do Begin
Cont := IS7Container(IDispatch(rgvar)); // block container,
check sources
If (Cont.ConcreteType = S7BlockContainer) Then Break;
Cont := NIL;
End;
2.4.7
Software upgrades
Software upgrade
Whenever you update the PLC or NCK software, always reset the PLC to its initial state first.
This initial clear state can be achieved by means of a general PLC reset. All existing blocks
are cleared when the PLC is reset.
It is usually necessary to include the new basic program when a new NCU software version
is installed. The basic programs blocks must be loaded into the user project for this purpose.
OB 1, OB 40, OB 100, FC 12 and DB 4 should not be loaded if these blocks are already
included in the user project. These blocks may have been modified by the user. The new
basic program must be linked with the user program.
To do this, proceed as follows:
1. Generate the text or source file of all user blocks before copying the basic program.
2. Then copy the new basic program blocks to this machine project (for a description, see
3. All user programs *.awl must then be recompiled in the correct order! (See also the
However, it is normally sufficient to recompile the organization blocks (OB) and the instance
data blocks of the machine program. This means you only need to generate sources for the
organization blocks and the instance data blocks (before upgrading).
2-16
Subsection "Application of basic program")
"Machine program" Section.)
This newly compiled machine program must then be loaded to the PLC CPU using
STEP 7.
PLC Basic Program Solution Line (P3 sl)
Function Manual, 08/2005 Edition, 6FC5397-0BP10-0BA0

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents