L-force | plc designer – Lenze PLC Designer PLC Designer (R3-1) User Manual

Page 134

Advertising
background image

L-force | PLC Designer

Concepts and Base Components

132

DMS 4.1 EN 03/2011 TD29

• The default namespace of a library is defined in the library properties. If it is not

defined explicitly, it will equates with the library name. However, when creating a
library project, also a different standard namespace can be specified in the
properties dialog. Later, when the library has got included in a project, the
namespace always can be modified locally by the user, again in the properties
dialog.

• Examples: Assume that for the following examples the "namespace" of library Lib1

is specified in the library properties to be "Lib1". See in the right column the use of
the namespaces for unique access on variable var 1 which is defined in the
modules module1 and POU1 .

Variable var1 is available at the following
locations within the project:

Access on var1 via using the appropriate namespace
path...

(1)

1. In library Lib1 in the global Library
Manager in the POUs window

"Lib1.module1.var1"

(2)

2. In library Lib1 in the Library Manager
below Application App1 of Device Dev1 in
the Devices window

"Dev1.App1.Lib1.module1.var1"

(3)

3. In library Lib1 which is included in
library F_Lib in the global Library Manager
in the POUs window

By default (option "Publish..." in the library Properties
is deactivated): "F_Lib.Lib1.module1.var1"

If option "Publish..." was activated, module1 would be
treated like a component of a top-level library. Thus
accessing would be possible by "Lib1.module1.var1" or
"module1.var1". In the current example this however would
cause compiler errors because the access path is not unique,
see (1) and( 4).

(4)

4. In object module1 which is defined in
the POUs window.

"module1.var1"

(5)

5. In object POU1 which is defined in the
POUs window.

"POUxy.var1"

Advertising