Siemens Industry Online Support
Siemens AG
Entry type: Application example, Entry ID: 109479728, Entry date: 03/30/2017

Library of general functions (LGF) for STEP 7 (TIA Portal) and S7-1200 / S7-1500

  • Entry
  • Associated product(s)
The library "LGF (Library of general functions)" contains additional functions for STEP 7 (TIA Portal).

STEP 7 in TIA Portal already has an extensive number of instructions for PLC programming (mathematical functions, times, counters, etc.). In addition, there are other useful basic functions that are often required in automation projects.

Such general-purpose functions are provided as "Library of General Functions". This library can be used unrestricted and contains features such as FIFO, search function, matrix calculations, astro timer, ....

These functions

  • are immediately usable by parameterization
  • can be used universally
  • are not protected and therefore customizable
  • are best documented including interface description

All blocks in the library can be universally used with the following controller:

  • S7-1200 and S7-1200F product family
  • S7-1500 and S7-1500F product family
  • Simulation with S7-PLCSIM (as of V13 SP1)

Download for TIA V13 SP1 Update 9
  Documentation LGF V2.0.1 (1,4 MB) 
 Registrierung notwendig  TIA Portal Library LGF V2.0.1 (2,1 MB)

Download for TIA V14 Update 1
  Documentation LGF V3.0.1 (2,9 MB)
 Registrierung notwendig  TIA Portal Library LGF V3.0.0 (1,5 MB)

Further Information
The LGF was created with the programming styleguide. 
Library with program examples for TIA Portal instructions
Library with PLC data types (LPD) for STEP 7 (TIA Portal) and S7-1200 / S7-1500

Last change
LGF V3.0.1
See chapter history in the documentation

Security information
In order to protect plants, systems, machines and networks against cyber threats, it is necessary to implement – and continuously maintain – a holistic, state-of-the-art industrial security concept. Siemens’ products and solutions constitute one element of such a concept. For more information about industrial security, please visit
Support to the statistics
With this function the IDs found are listed according to number (format .txt).

Generate list
Copy URL
View this page in new design
mySupport Cockpit