CODESYS 3.5 - PLC Programming With Structures - Lesson 8 - Standard & Bespoke Structures
Автор: Liam Bee
Загружено: 2025-11-25
Просмотров: 15
Описание:
🔹This course is from 2023 and is now free. You can still access it ad free at https://liambee.me
if you become a member or purchase the course.
🔹Downloadable content for this course is available here for free:
https://liambee.me/codesys-structured...
In this lesson we look at how to enhance your structured data with bespoke, asset specific parameters, without disturbing the standardised type data that your system relies on. This approach allows each instrument, asset or area of the project to contain its own custom additions while still benefiting from a common, shared structure.
We begin by introducing a new function block called an Interlock Manager. This block monitors a value, compares it against a trigger level, and latches an interlock until the release condition is met. The example shows a pressure high interlock using the existing structured data. After confirming it works, we explore how to give each pressure instrument its own set of parameters such as high trigger, release value and delay times.
At first it might seem easiest to place these bespoke parameters in a shared global variable list. While this works for small systems, it quickly becomes problematic as systems grow. With many instruments and many bespoke parameters, a single global list becomes hard to maintain, difficult to expand and risky to modify. Structural changes can trigger reinitialisation of unrelated data, causing unwanted behaviour in running systems.
To avoid this, we restructure the project so each asset has its own global variable list containing two areas:
• typed – the standardised structure shared across the whole project
• bespoke – a structure containing asset specific custom data
This separation gives each asset its own isolated namespace. Pressure1 has its own typed and bespoke sections, and Pressure2 has its own typed and bespoke sections. Both share the same standard data structure, yet each can have different bespoke parameters without affecting the other.
We then create a dedicated DUT for bespoke pressure data and add trigger values, release values and delays. After assigning this to each pressure instrument, the Interlock Manager can reference pressure1.bespoke or pressure2.bespoke directly. When Pressure2 needs new bespoke elements, such as low trigger and low release parameters, we simply update Pressure2’s bespoke structure. Only that instance is affected during an online change. Pressure1 remains untouched.
This approach provides a powerful way to extend functionality safely. You can add new asset specific features without forcing modifications to your standard type structures, avoiding widespread reinitialisation or interface changes. It also keeps the project clean and easier to maintain, especially as it scales to dozens or hundreds of instruments.
By the end of the lesson you will understand how to combine standard structured data with bespoke extensions in a way that is safe, scalable and predictable. This method significantly reduces the impact of changes and gives you a flexible architecture for long term growth.
#AlwaysLearning #Automation #Codesys #PLC #HMI
Повторяем попытку...
Доступные форматы для скачивания:
Скачать видео
-
Информация по загрузке: