add chat to your website

The Hidden Power of Functions in HMI/SCADA application design

“At each increase of knowledge as well as on the contrivance of every new tool, human labour becomes abridged.”  Charles Babbage

I have been immersed in the world of computing since earning my undergraduate degree in Computer Science and Management Information Systems in the early 1980s.  The technological evolution since those early days has been nothing short of extraordinary.  Today, we often take for granted that computers are the lifeblood of modern society.  Imagine if they were to suddenly cease functioning all at once:  the power grid would go dark, vehicles would collide, planes would fall from the sky, water treatment plants would grind to a halt, stock markets would freeze, supply chains would break down, and employees would go unpaid.  Computing has revolutionized nearly every facet of our lives, becoming an essential thread in the fabric of our world.

Throughout my software career, I have had the privilege of witnessing a fascinating evolution in programming.  Each new language, from assembler to modern high-level languages, has built upon the knowledge and innovations of its predecessors (see chart below).  This continuous progression not only advanced the tools at our disposal but also unlocked new possibilities, reshaping how we approach problem-solving and solution design.

I will skip the early contributions of pioneers like Alan Turing and Ada Lovelace and start the discussion from the 1940s onward.

The chart below illustrates the hierarchical evolution of programming languages.  It starts from foundational machine language at the base, which consists of binary code directly executed by the hardware.  Stacked above is assembly language, a symbolic representation of machine instructions that simplifies programming while maintaining close control over the hardware.  Next, high-level languages emerge, offering human-readable syntax that abstracts away hardware complexities, making programming more accessible and efficient.  Building upon this, specific high-level languages such as Fortran, C, and Pascal are highlighted, representing key milestones in structured programming.  At the top layer, the chart culminates in object-oriented and visual languages, such as C++ and Visual Basic.  This further enhances productivity by introducing concepts like encapsulation, inheritance, and user-friendly development environments.  Together, the layers reflect the progressive abstraction and sophistication of programming languages over time.

A similar transformation occurred in industrial automation.  Early control systems, though limited, introduced the foundational concept of automating tasks and processes.  SCADA systems expanded on this by integrating programmable logic and more sophisticated control algorithms, revolutionizing how industries monitor and control operations.

Before SCADA emerged in the mid-20th century, industrial facilities and remote sites relied on personnel to manually manage equipment using push buttons and analog dials.  As these facilities grew in size and complexity, the need arose to control equipment across greater distances.  Relays and timers offered a basic level of supervisory control, reducing the need for on-site intervention.  However, as organizations scaled, the limitations of these systems became apparent.  Relays and timers were challenging to reconfigure and troubleshoot, requiring massive amounts of space in control panels.

The advent of computers in the 1950s marked a turning point.  Early industrial control systems began to utilize these machines, paving the way for supervisory control in utilities, oil and gas pipelines, and other sectors.  The 1960s saw the introduction of telemetry, enabling automated data transmission from remote sites.  By the early 1970s, the term “SCADA” (Supervisory Control and Data Acquisition) was coined, with the rise of microprocessors and PLCs further enhancing monitoring and control capabilities.

The first SCADA systems relied on monolithic architectures with mainframe computers.  These standalone systems lacked the networking capabilities we take for granted today.  By the 1980s and 1990s, SCADA systems evolved into distributed models, thanks to advancements in smaller computers, Local Area Networking (LAN), and PC-based HMI software. Although these distributed systems enabled SCADA networks to interconnect, the proprietary LAN protocols of the time restricted interoperability between vendors.

The late 1990s and early 2000s saw the rise of networked SCADA systems, which embraced open architectures and non-proprietary communication protocols, such as Ethernet.  These systems allowed seamless communication between devices from different vendors, removing earlier limitations and enabling organizations to scale their networks more effectively.

Over time, industrial automation software, such as HMI/SCADA, has evolved to incorporate many features and functionalities inspired by IT software.  This shift has provided users with greater levels of abstraction, enhanced usability, and improved efficiency.  Modern HMI/SCADA packages not only leverage the capabilities of their underlying programming languages but also introduce features tailored specifically to the demands of industrial automation environments.  Among these are functions—a critical yet often overlooked component.

Functions form the backbone of any robust system.  They simplify repetitive tasks, manage intricate workflows, and enhance the adaptability of systems to meet evolving requirements.  In this blog, we will explore the evolution of functions, emphasizing their pivotal role in contemporary application design and demonstrating how they revolutionize interactions with industrial processes.

History of Functions

In the earliest days of computing, the concept of software functions as we understand them today did not exist. Programming was performed much lower, where developers directly manipulated hardware using machine code.  This code, specific to each computer’s hardware, required precision and an intimate understanding of the machine’s architecture.

The introduction of assembly language marked a significant step forward.  By replacing raw numbers with symbolic names, assembly made programming slightly more manageable.  However, the real breakthrough came with the advent of high-level programming languages like FORTRAN and COBOL.  These languages transformed the programming landscape by allowing developers to write more human-readable code focused on solving problems rather than grappling with hardware details.

One of the key innovations of these early high-level languages was the introduction of subroutines—reusable blocks of code that could be invoked from different parts of a program.  This concept laid the foundation for functions as we know them today.

FORTRAN, developed in the late 1950s, introduced both subroutines and functions.  These enabled programmers to encapsulate mathematical operations and other tasks into reusable code segments.

Around the same time, ALGOL pioneered the use of procedures similar to functions and introduced the concept of block-structured programming.  This innovation profoundly influenced modern programming languages like C, Pascal, and Python.

Later, C set the standard for functions in modular programming.  It formalized features like function prototypes, arguments, and return values, providing a blueprint for subsequent languages.

While subroutines were a significant advancement, they were primarily procedural, focusing on executing a sequence of actions.  Functions, conversely, introduced the idea of calculating and returning results.  For instance, a simple function like square(x)—which computes the square of a number—takes an input, processes it, and returns a value that can be used elsewhere in the program.  This ability to compute and return values distinguishes functions from their procedural ancestors.

Over time, programming languages evolved, and the distinction between subroutines and functions blurred.  Today, the term function is often used for both, regardless of whether a value is explicitly returned.  However, the core principle remains the same:  modular, reusable blocks of code that enhance clarity, reduce repetition, and increase programming efficiency.

This journey from low-level machine code to the sophisticated functions of modern programming highlights the profound evolution of how we write and think about software.  Functions now serve as the building blocks of robust, adaptable systems, proving their enduring importance in programming.

Functions defined

A function is a block of organized, reusable code to perform a specific task.  Functions allow programmers to break down a program into smaller, modular parts, making the code easier to read, debug, and maintain.

Key Characteristics of Functions

Name:  Functions are identified by a unique name used to call or execute them.  For instance, in ADISRA SmartView, there is a function called SVDatabase.

Parameters (Optional):  Functions can accept input values, parameters or arguments, to tailor their behavior.  For example, in ADISRA SmartView, the SVDatabase function can be used to fetch or update data from a connected database, with parameters specifying the exact data to retrieve or modify.

Return Value (Optional):  After completing their task, functions can produce an output known as a return value.  For instance, the SVDatabase function in ADISRA SmartView can return specific data fetched from the database.

Encapsulation:  Functions encapsulate their internal logic, hiding the underlying implementation details while providing a simple interface.  In ADISRA SmartView, users only need to call SVDatabase to retrieve data without worrying about how the function interacts with the database.

Reusability:  Functions are designed to be reusable, enabling the same code to be called from multiple places without needing to rewrite.  This makes them an essential tool for efficient and maintainable programming.

ADISRA SmartView Functions Library

ADISRA SmartView HMI/SCADA Software features a robust and comprehensive System Function Library designed to empower users with a robust set of pre-built functions for building applications efficiently and effectively.  This library provides various versatile functions, enabling users to simplify complex tasks and easily create highly functional and adaptable applications.

Captured Image from ADISRA SmartView

ADISRA SmartView introduces two distinct types of function libraries:  the System Functions Library and User Function Libraries.  This dual-library approach ensures robust, built-in functionality and the flexibility for users to create custom solutions tailored to their needs.

System Functions Library

The System Functions Library is a collection of pre-defined, built-in functions provided by ADISRA SmartView.  These functions are designed to streamline development by offering ready-to-use functionality for various tasks, such as database interactions, data manipulation, and system operations.  Key characteristics of the System Functions Library include:

Built-In and Immutable:  These functions are integrated into ADISRA SmartView and cannot be altered or deleted, ensuring their reliability and consistency.

Ease of Use:  These functions are accessible across all scripting contexts, including service documents, triggers, and screen scripts, and they allow users to implement essential features quickly and effectively.

Standardized Functionality:  By using pre-tested, standardized functions, users can trust in the accuracy and performance of their applications.

User Function Libraries

In addition to the System Functions Library, ADISRA SmartView empowers users to create their User Function Libraries. These libraries enable users to define custom functions tailored to specific application requirements.  Key features of User Function Libraries include:

Customizability:  Users can develop unique functions to encapsulate specific logic, workflows, or calculations, enhancing modularity and reusability.

Cross-Application Usage:  Once defined, these user-created functions can be shared and reused across multiple ADISRA SmartView applications, promoting consistency and reducing development time.

Scalability:  User Function Libraries grow alongside your projects, enabling you to build a library of reusable components for future applications.  By offering a System Functions Library for standardized, built-in functionality and User Function Libraries for customized logic, ADISRA SmartView delivers a powerful and flexible framework.  This approach simplifies application development while empowering users to address unique challenges with tailor-made solutions.

With its extensive function library, ADISRA SmartView allows developers and engineers to focus on delivering value through their applications rather than spending time on repetitive or low-level tasks.  Whether you’re building a simple dashboard or a complex industrial control system, the System Function Library is a foundational tool for achieving your desired functionality with precision and efficiency.

Download our comprehensive white paper here to learn more about the Function Libraries in ADISRA SmartView.

Experience ADISRA SmartView by downloading a software trial from our website here.

Conclusion

Functions are the unsung heroes of modern software development.  They form the backbone of modular, efficient, and adaptable applications.  From their early beginnings in programming history to their current role in HMI/SCADA systems, functions have consistently evolved to meet the demands of increasingly complex tasks and workflows.

In industrial automation, functions provide the foundation for seamless interaction with processes, whether by simplifying repetitive tasks, managing workflows, or ensuring application consistency.  ADISRA SmartView takes this further by offering a System Functions Library and User Function Libraries, empowering users to harness pre-built capabilities while crafting custom solutions tailored to their unique requirements.

By leveraging ADISRA SmartView’s powerful function libraries, developers and engineers can focus on innovation and delivering value rather than getting bogged down by low-level tasks. Whether accessing data from a database, automating control logic, or creating scalable, reusable components, ADISRA SmartView provides the tools to make it happen efficiently.

Explore the transformative potential of HMI/SCADA application design functions by downloading our comprehensive white paper above.  Better yet, experience the capabilities of ADISRA SmartView firsthand by downloading a trial version from our website here. Empower your applications with the hidden power of functions today!

Leave a Comment

Your email address will not be published. Required fields are marked *

fourteen + two =