Java brings opportunities to industrial automation

Like many in the embedded systems industry, industrial automation vendors have watched and waited for the validation of Java in their domain. At the top of the list of concerns are performance problems caused by simplistic implementations of the Java virtual machine (JVM) and garbage collection algorithm.


Like many in the embedded systems industry, industrial automation vendors have watched and waited for the validation of Java in their domain. At the top of the list of concerns are performance problems caused by simplistic implementations of the Java virtual machine (JVM) and garbage collection algorithm. However, with a new generation of Java virtual machines sporting real-time garbage collection algorithms and throughput speeds approaching that of C++ on many common operations, the time is ripe for industrial automation to reap the benefits of the Java programming language.

What makes Java fit the industrial automation world are the concepts of JVM and class file. A class file is a sequence of machine-independent instructions interpreted by the JVM running on a host computer. Java virtual machines and class files have been used on the Internet for several years to download and execute programs inside web browsers.

Typically, a class file is sent over a network and loaded into the Java virtual machine via a Java classloader, which reads the class file, validates it, and loads it into memory ready for the JVM to execute. Because class files are machine independent, the classloader and JVM combine to load and execute Java files in exactly the same manner, with the same results, on any hardware platform.

Hardware independence

One of Java's primary advantages is its ability to run programs on different hardware platforms without recompiling source code. For industrial automation, this has several benefits.

First, as hardware is updated and newer controllers replace older controllers, no change in the binary software is required. For example, if a PLC that fully utilizes a 40-MHz Intel processor is upgraded to a 100-MHz Power PC processor, then the same binary class files can be used for both controllers, assuming that hardware ports and external interfaces are programmed for portability.

Second, hardware independence allows developers to "simulate" the run-time environment on a desktop computer, greatly reducing development time. With the simple addition of low-level hardware simulation, the same application class files that run on the target PLC can also execute on a desktop computer for development and debugging.

Easier debugging

Familiar debugging tools and development environments not tied to specific hardware platforms are easier for developers to learn and use, and testing does not require the constant downloading and setup of the target PLC. Another benefit is that debugging is only required on a single version of source code—once for all platforms. This reduces project overhead and maintenance by greatly simplifying project build configurations, reducing coding errors, and simplifying bug tracking and change requests.

In addition to cross-platform compatibility, Java programming language provides the means for seamlessly downloading new or revised code to PLCs without any type of reset of the hardware or JVM. This ability, called dynamic downloading , was designed into the Java language with this idea in mind.

Imagine a factory with PLCs controlling automobile part production and connected via a wireless company intranet. Using a web browser, the production controller can change PLC configuration to produce camshafts for six-cylinder engines instead of four-cylinder engines without intervening with the machine physically. While such behavior could be accomplished using another programming language, Java makes this type of system architecture easy and intuitive to program. Benefits are clear when considering the movement towards just-in-time delivery of products.

Not only can dynamic downloading change hardware's behavior, it can also be used to "patch" existing code or add more functionality. Ability to change a single source file, recompile it, dynamically download only the changed class file, and link it into a running JVM provides added flexibility for software maintenance.

Essentially, Java brings cross-platform compatibility and dynamic downloading to industrial automation. However, Java also provides software safety, developer productivity, and access to a large set of libraries that provide rapid design and coding of applications. With embedded Java libraries designed to provide pure Java interrupts and input/output functions, developers can write platform-independent device drivers, providing further cross-platform compatibility. Rapid improvements in Java technology and advancements in hardware have made Java a viable solution for industrial automation. The question is not whether Java will be adopted for use in industrial automation, but rather who will be the first to take advantage of what Java offers.

Dr. James Lathrop, director of professional services, NewMonics (Ames, Ia.), ,

Java's advantages

1Portable binariesallow seamless deployment across platforms

Object-oriented programming improves productivity two to 10 times

Reuse of code leverages original code investment

Run-time environment enables extensibility

Java compiler and classloader aid security

No comments
The Engineers' Choice Awards highlight some of the best new control, instrumentation and automation products as chosen by...
Each year, a panel of Control Engineering editors and industry expert judges select the System Integrator of the Year Award winners.
Control Engineering Leaders Under 40 identifies and gives recognition to young engineers who...
Learn more about methods used to ensure that the integration between the safety system and the process control...
Adding industrial toughness and reliability to Ethernet eGuide
Technological advances like multiple-in-multiple-out (MIMO) transmitting and receiving
Virtualization advice: 4 ways splitting servers can help manufacturing; Efficient motion controls; Fill the brain drain; Learn from the HART Plant of the Year
Two sides to process safety: Combining human and technical factors in your program; Preparing HMI graphics for migrations; Mechatronics and safety; Engineers' Choice Awards
Detecting security breaches: Forensic invenstigations depend on knowing your networks inside and out; Wireless workers; Opening robotic control; Product exclusive: Robust encoders
The Ask Control Engineering blog covers all aspects of automation, including motors, drives, sensors, motion control, machine control, and embedded systems.
Join this ongoing discussion of machine guarding topics, including solutions assessments, regulatory compliance, gap analysis...
News and comments from Control Engineering process industries editor, Peter Welander.
IMS Research, recently acquired by IHS Inc., is a leading independent supplier of market research and consultancy to the global electronics industry.
This is a blog from the trenches – written by engineers who are implementing and upgrading control systems every day across every industry.
Anthony Baker is a fictitious aggregation of experts from Callisto Integration, providing manufacturing consulting and systems integration.
Integrator Guide

Integrator Guide

Search the online Automation Integrator Guide

Create New Listing

Visit the System Integrators page to view past winners of Control Engineering's System Integrator of the Year Award and learn how to enter the competition. You will also find more information on system integrators and Control System Integrators Association.

Case Study Database

Case Study Database

Get more exposure for your case study by uploading it to the Control Engineering case study database, where end-users can identify relevant solutions and explore what the experts are doing to effectively implement a variety of technology and productivity related projects.

These case studies provide examples of how knowledgeable solution providers have used technology, processes and people to create effective and successful implementations in real-world situations. Case studies can be completed by filling out a simple online form where you can outline the project title, abstract, and full story in 1500 words or less; upload photos, videos and a logo.

Click here to visit the Case Study Database and upload your case study.