In a world where ladder logic is still dominant, texted-based programing languages like structured text are gaining ground, especially as industrial automation adopts modern software practices such as version control, continuous integration/continuous development (CI/CD) pipelines and artificial intelligence (AI).
Developers are increasingly asking whether the industrial world can catch up to the modern tech stack without sacrificing the stability and determinism that make programmable logic controllers (PLCs) so reliable.
How might higher-level programing languages and version-control tools like Python, C# and GitHub integrate into traditional controls environments? While the IEC 61131-3 languages still form the foundation of control logic, the case for expanding beyond them, or at least bridging the gap, is growing stronger.
The tech industry has developed many design tools, which largely use text-based languages, and Patrick Smith, senior project engineer at DMC, a CSIA-certified system integrator, thinks they will inevitably make it into the world of machine controls. “I expect to see structured text continue to gain popularity,” Smith predicts. “In addition, the ability to represent languages like ladder logic with a text equivalent is becoming more developed.” He highlights some of the modern development tools driving language choice, including:
- powerful and extensible text-based integrated development environments (IDEs) such as Visual Studio Code
- integration with version control platforms like Git
- utilizing CI/CD pipelines and DevOp workflows.
“While several companies are working to bring these tools to the controls world and its unique languages, the plethora of easily accessible tools will likely continue to push the industry toward structured text,” Smith says.
As far as movement toward higher-level languages, such as Python or C# or other model-based design, Smith could see it happening some day, due to the popularity of those languages, but not any time soon, for a number of reasons. Namely, IEC languages have strong industry support and PLC products that support them. Right now, very few higher-level languages are able to run on a PLC’s CPU without significant modifications by the PLC vendor.
“So, not only do the vendors give up control over the language features available, but they also have to do extra work in making the language capable of running properly,” Smith says. “The alternative would be shifting PLCs to sharing more architecture with PCs or common embedded controllers, but that would be a fairly radical paradigm shift and still results in the PLC vendors giving up control over parts of their hardware and software.” PLC vendors might also disincentive these languages as they could ultimately make it easier for programmers to transition between vendors, instead of standardizing on one.
Get your subscription to Control Design’s daily newsletter.
Another problem with high-level languages for controls programming is that they receive frequent updates and improvements. “Since the controls world generally prefers stability over the cutting edge, the PLC implementations of these languages would likely not keep up with the language release cadence,” Smith explains. “This would lead to situations where PLC Vendor A supports Python 3.11, while Vendor B supports Python 3.9, and that doesn’t even begin to get into variations between controllers from the same vendor. Since these language versions can often bring significant changes, it would not improve the portability of the language at all.”
Higher-level languages are also much harder to maintain and troubleshoot. “Higher-level languages typically require more familiarity and bring their own set of tools and best practices for troubleshooting,” Smith says. “Transitioning to higher-level languages would likely require companies to provide thorough training for their maintenance teams or hiring programmers who know these languages well.”
On the downside, these programmers are likely more expensive, he adds, and less familiar with electrical and mechanical problems that maintenance teams face.
“In addition, effective troubleshooting of higher-level languages would likely require adopting DevOps strategies, such as maintaining development and testing environments, or being able to replicate a production environment when debugging,” Smith says. Software-based PLCs and digital twins are starting to bridge this gap, but industry-wide support has a long way to go, he adds.