TwinCAT 3 can run on a plain-vanilla copy of Windows 7. Also, the license cost scales with the processing power of the PC. On the other hand, industrial PCs are hardened against tougher environmental conditions like dirt and temperature, and they come in nicer form factors for mounting inside of a control panel. They also take a 24V input rather than running from the AC mains.
|Published (Last):||25 April 2017|
|PDF File Size:||5.76 Mb|
|ePub File Size:||7.38 Mb|
|Price:||Free* [*Free Regsitration Required]|
Any use outside the limits of the copyright law is not permitted without permission of the publisher and is punishable. This applies, in particular, to copying, translating, microfilming, and importing and editing in electronic systems. Editor: Elmar Krammer. Table of Contents M. Bani Younis, A. Fay, G. Diehm Supporting the design of drive applications for packaging machines T. Dreyer, A. Finkbeiner Modularity in machinery Ch. Huelke, M. Hauke, J. Krah, Ch. In case of modernizations and re-structuring of machines, the necessity increases to modernize the installed PLC because it can no longer meet the increasing requirements, as well as spare part costs.
The reimplementation of mature control programs on another, new PLC is still a laborious, cumbersome and error-prone manual task, even if it is supported by some industrial tools on a low abstraction level nowadays. The re-implementation results achieved by these state-of-the-art industrial tools offer only limited assistance, because they do not allow a fully automatic transfer onto a new platform. In addition, a functional check is not possible before the machine is in operation with the new PLC this induces a considerable risk for a timely re-start of production.
In addition, the existing tools lack functionality for the re-documentation of changed code. This makes it difficult for the user to understand the changed code and to follow the algorithms used. These obstacles have inspired researchers to investigate ways to analyze, verify, and simulate PLC programs on an abstract level before migrating them to the new controller running on the physical plant [1, 2, 3, 4].
In order to avoid the limitations and problems mentioned above, this work proposes a re-implementation approach based on formal methods. These formal methods allow: a formal analysis of the existing PLC control code, a documentation and visualization of the PLC control code, and a separation of the source and the target code, with a PLC-independent intermediate storage format. However, the approach presented here is not limited to these source and target languages.
The rest of the paper is structured as follows. The re-implementation approach is introduced in Section 3. Section 4 provides an example to illustrate the method. Section 5 concludes this paper and gives an outlook on future work. This language had been a quasi-standard in Germany for several years, with a large installed base of machines and plants, and the corresponding hardware is now no longer produced.
This means that there is a good possibility for the application of re-implementation. The software on a STEP5 PLC is implemented in a hierarchical form using four main types of modules as follows: OB: Organization Block; serves for the management of the user program in form of a listing of the program modules to be worked on. PB: Program Block; in this module the user programs are located structured in groups.
It includes only binary operations. FB: Function Block; this is often used to realize frequently used or complicated functions. DB: Data Block; this module contains data which the other Blocks operate on. In addition to these general modules STEP5 also holds special types of modules like timers and counters.
The presented approach is an extension of previous work described in . Figure 1 illustrates the individual steps for the re-implementation of PLC programs. The four steps are further explained in the following sub-sections. The XML document obtained through this transformation is a hierarchically structured document.
The obtained XML as a result of the previous processing can be validated using a validating parser that confirms that the XML document in addition to being well-. Figure 2. XSLT is used to transform the well-formed and valid XML to another XML which as a result of identification of instructions has additional attributes appended to the instruction tags.
The type attribute classifies the operations into different types. The main idea in the abstraction step is to merge several instructions.
As an example, the case of binary operations is presented in the following: in an assemblylike language like IL, there are instructions that only influence the current state of the accumulator not any other variables or output ports. However, the state of the accumulator is not of interest for the correct description of the algorithm.
Therefore, operations that only influence the accumulator may be grouped until an operation arrives in the sequence that depends on the result of this calculation.
The operation S sets the operand to 1 if the accumulator content is one, else it is not executed. Conversion into SFC. Most machines and plants operate in production cycles.
Therefore, the PLC program has mainly the task to control the sequence of actions in these production cycles, including alternative sequences, and changes between different operation modes. To optimally design, test, implement and maintain these sequence control algorithms, the IEC standard provides the SFC language. It is therefore desirable to reimplement these sequence control algorithms in SFC.
This step towards the conversion into SFC is an extension to the steps described earlier in  and . The condition of the state transition is transformed into a new transition of the SFC which points to a new step in SFC.
The outputs of the FSM transition are converted into actions of the step. For each output of alternative transitions, a new step has to be generated.
A dummy transition has to be extra generated with a TRUE condition to represent a destination of the action step before. This transition has to point again to a dummy step.
The latter is important in case multiple FSM transitions point to the same state. The conversion of timers, counters and other functions Non-binary functions is implemented by means of the S action qualifier of SFC. An external action will be allocated for this qualifier which retrieves the logic of the function of the input PLC code of the conversion. In case of timers and counters, the allocated action is used for the start of the timer or counter.
As pointed out above, the conversion of IL to SFC should only be applied to sequence control algorithms, but not to latches and interlocking control code, which is intended to be executed in every PLC cycle. It is therefore necessary to automatically distinguish sequence control code from interlocking control code. This is not trivial, since both look similar in IL. An important feature to distinguish whether a given piece of control code is of sequence control type is to investigate the FSM in XML for the use of variables or flags which store the information about which step is active.
These flags are necessary to ensure the sequential behavior of the sequence control code. Whereas in SFC, the information about which step is active is stored internally. In each other PLC language, the PLC programmer has to program these flags and their setting and re-setting manually in the sequence control code see for. The four steps described above to convert IL code into SFC code will be expressed by means of an example in the next Section.
Example The proposed approach is illustrated in the following example: A mixing machine for two colors cf. The main aim of the PLC program is to control the production cycles of the mixing machine, i. This sequence control type is given using step flags in Figure 5 e. UN M Note that the comments explanations listed in the right part of Figure 5 are only shown to illustrate the example, but are not interpreted in any way by the re-implementation algorithm.
The controlled production cycle is as follows: After actuation of the start button S0, the LED H0 is switched on, the valve Y1 is opened, and the pump M2 is started.
When the liquid reaches the sensor B1, the valve Y1 is closed, and valve Y2 is opened. After six seconds, the stirrer M1 is switched off. After the described process, the system is in its initial state again. By means of the emergency stop S6, the thermal triggers F1 or F2, or by reaching limit switch B4, the plant can be switched off at any time. The actual control algorithm is programmed in PB2 as shown in Figure 5, containing 12 groups of instructions.
Segment given in Figure 6. Figure 7. The transformation. Finally, an SFC is generated describing the dynamics of the module cf. This timer is converted automatically using the S qualifier of an external SFC action, which is used to start a TP time function cf. IF E0. The paper presents an approach for the re-implementation of existing PLC programs based on formalization and visualization. The next steps of the authors work are the extension of the re-implementation steps to be able to optimize the SFC, e.
References  L. Baresi, M. Mauri, A. Monti, and M. Mader and H. Wupper, What is the method in applying formal methods to PLC applications? Rossi, J. Roussel, J. Frey and L. John, M.
TR3020 | TwinCAT 3 Training: Basic PLC programming
Cookbook "How to implement an ADS client"
TwinCAT 3 Tutorial: Quick Start