During the latest COVID lock down, scrolling randomly through the internet, I stumbled on Project Euler, a series of mathematical/computer programming problems. So I thought it would be fun to try a few challenges with Structured Text. After completing the first 2 challenges it occurred to me that it might be fun to publish a repo on Github with this project, to see if I can get more people to solve challenges and on the fly creating a lot of mathematical Structured Text example code.
Tag: Inheritance
You should use AND_THEN. OR_ELSE?

In this post I’ll discuss the operators ‘AND_THEN’ and ‘OR_ELSE’. Operators which I find really useful from time to time.
Fluent interface in Structured Text

A popular programming design in high level languages as C# is the so-called ‘fluent code’ or ‘fluent interface’. But what is a fluent interface and how can we implement this in Structured Text? In this post I briefly explain what a fluent interface is and give an example of a fluent interface in Structured Text.
The three pillars of OOP – Inheritance

With the object orientated options we’ve got available with IEC 61131-3 last years the time has come to talk about design patterns and best practices in the world of PLC programming. In this series of three posts ‘The three pillars of OOP’ I will explain the concepts of: Encapsulation, Inheritance and Polymorphism with some examples in TwinCAT. This post is about the second pillar ‘Inheritance’.