Programmable Logic controller Open standard structure & Data Correction for SCADA
PLCopen standard structure & Data Correction to SCADA system
This is the first in a series of articles focusing on writing code using IEC 61131-3 programming. The first series of articles will focus on information architecture for the standard conventions and data types. Following coverage of these, this series will explore the code written for a scope of different situations.
THE IEC 61131-3 software model

Figure 1
Standard IEC 61131-3 has a hierarchical approach to the programming structure. The software model in Figure 1 shows the schematic of this structure. Analyze this structure from top to bottom.
Configuration:
At the top of the structure of software for any application is configuration control. This configuration “or control of the software architecture defines the function of a specific API for a specific application. This API can have many processors and can be one of many used in a single application in its processing plant. We generally discuss a configuration that includes only a PLC, but PC-based control can be extended to a PC that can be activated multiple machines. A configuration may need to communicate with other formations in the overall process through defined interfaces that provide access roads for communication functions. These must be formally specified using the standard language features.
Contact:
In each configuration to stay one or more resources. The resource provides support for the program. It is defined by the standard as:
“A resource corresponds to a function” signal processing “and” man-machine interface “and” sensor and actuator interface “functions (if any) as defined in IEC 61131-3.
An IEC program does not run when loaded into a resource. A resource of May an implementation program that exists in a controller located in a PLC or PC. In fact, today, in many integrated development environments, system performance can be used to simulate the performance of the control program development and debugging purposes. In most cases, a single configuration contains a single resource, but the standard provides additional resources in a unique configuration. Figure 1 shows 2-resources in a configuration.
Task:
The tasks are control mechanism for the implementation of the resource. There may not be specifically defined task or multiple tasks that are set for a given resource. If no task is declared executable software must have a special program, it recognizes the default execution. As you can see in Figure 1, the tasks are able to call programs and function modules. However, some implementations of the standard 61131-3 tasks limit the CIS One of the programs and modules do not work. Tasks have 3 characteristics:
1. Name
2. Type - Continuous, cyclical or Event-Based
3. Priority - 0 = Highest priority
The next article in this series will focus exclusively on tasks and configuration and associations for programs and function modules. For now, we will continue our decomposition of the software model.
Program Organization Units:
The three lower levels of software models are collectively called Program Organization Units (Pous).
* Programs
* Function blocks
* Functions
Programs:
A program, when used as a noun, refers to a software object that can absorb or “invoke” a series of function modules or functions to perform signal processing necessary to implement a partial or total control over a machine or process with PLC system. This is usually done by connecting various function modules and exchange data connections via software created using the variables. Instances (copies of a program can be created on the level of resources. Applications can read and write I / O data using global variables and directly represented. Applications can invoke and to exchange data with d other applications using the resources at the global variables. Applications can exchange data with programs in other configurations with function blocks for communication and using paths.
The real workhorse of this software are the hierarchical function block. It is customary to connect function blocks both vertically (a function block extends from the other) or horizontally (a function block called a second) to create a structured control architecture. Function blocks encapsulate both data (internal variables and input and output variable as the interface to function modules for objects other software) and an encryption algorithm that determines the value of internal variables and output function the present value of inputs and internal variables. The main differentiating factor between the function blocks and functions are storing values in memory, which is unique to the function modules and not a property of functions. When a function block can have a state defined by its memory, its class file should be copied (instantiated) several times. One of the simplest examples of a function block is one hour. When the class object “hours” are described more copies of this class can be instantiated (timer1, timer2, timer3 … etc.), each with a single state based on the value of variables.
Features:
“Low” level of the program unit of the organization function. A function is a software object that when invoked and provided with a unique collection of input variables returns a single value with the same name and data type as those in operation. Sine qua non is a characteristic behavior that returns the same value whenever the same input values are delivered. The best example of a function is ADD function. Whenever I book 2 and 2 to add input function I would get a 4 as return value. Since there is no other solution for 2 +2 there is no reason to hide information about the previous claim Add functionality (without instantiation) and therefore not need the internal memory.
Path ways:
The method of exchanging data between different configurations for access to trails. Access roads to provide a variable named, through a configuration that can transmit data values from / to other distance learning courses. The standard does not define the bottom layer to use for this transfer, but rather defines the creation of a drawing ( “container”) in which data can travel.
Global Variable:
Finally we arrive at the variables that are declared to be “visible” to all members of a certain level of hierarchy. If a global variable is declared in the program so that all programs, function blocks and functions, members of this program have access to these data. We say that the data available to them. Similarly, a global variable declared in the level of resources will be accessible for all programs is that resource.
Conclusion:
The IEC 61131-3 software model is modular and hierarchical. We have outlined the main components in this first tutorial. Next time we’ll focus on the details of the mechanism of transfer. Later tutorials will focus on the details of dust with an emphasis on the differences between the programs, function blocks and functions. Access roads will be a second tutorial with the notions of data type.