CTI, A DIVISION OF THE POLING GROUP


Release Notes
View release notes from all the V4 versions of PLCIO
PLCIO 4.0
PLCIO 4.1
PLCIO 4.2
PLCIO 4.3
PLCIO 4.4
PLCIO 4.5
PLCIO 4.6
PLCIO 4.6
Release Notes - December 6, 2024


New Features
Single Unified Library:

This release of PLCIO does away with the individual shared libraries (.so files) for each PLC module and condenses them into a single libplc.so (shared) or libplc.a (static) library. This layout is more convienent when including PLCIO in embedded systems or for compiling the library statically into any existing C/C++ applications.

New Management Functions:

New management functions have been added to the library to assist in some non-PLC operations. plc_log_callback() allows the application to set up a custom callback function handler for log messages generated by PLCIO. This enables logging directly to memory or other application-specific resources instead of directly to a file. Another function, plc_get_softplc_list(), allows the application to iterate through the list of available Logical PLCs listed in the "plcio.cfg" configuration file.

Enhanced Error Checking:

The library now provides a macro PLC_IS_COMM_ERROR(plc_ptr->j_error) to help decide how to handle errors from a plc_read() or plc_write() call. Generally, communications errors (those in the 40 through 99 range, with the exception of PLCE_TIMEOUT) require the application to close and reopen the connection to the PLC before sending the next read/write request. This macro makes the decision easier--returning true or false signifying whether the application must reconnect to the PLC.

Redesigned Programming Manual:

PLCIO 4.6.0 comes with a new modern layout for the PDF manual, featuring colored text and a typeface that is easier to read. This version does away with the "Word Art"-stylized fonts that were popular in the 90's.

New Modules
Mitsubishi SLMP Support:

This release introduces support for Mitsubishi Electric MELSEC-Q/L/iQ-R/iQ-F series PLCs using the new 'slmp' module. Both device code and label name addressing styles are supported.

OPC UA Support:

This release also introduces support for communicating to an OPC UA server over Ethernet using the 'opcua' module. Both Browsename and Node ID syntax is supported, allowing PLCIO to write to any array index in any namespace using 16 of the most common data types available in OPC UA.

This module enables PLCIO to communicate to some PLCs that optionally export their internal tags via OPC UA, such as the Bosch/Rexroth IndraControl CML series of motion and logic controllers (MLCs).

Other Enhancements
- In UNIX, new protections are in place for when the operating system generates a SIGPIPE signal. Originally, if PLCIO attempts to send a message to a TCP connection that has already been closed by the remote PLC, the operating system will generate a SIGPIPE signal. If this signal is not explicitly caught by the application, then the application will terminate with no warning or log message.

As this behavior was never mentioned in the PLCIO manual, and that some applications might rely on SIGPIPE being generated for other reasons, this version of PLCIO now ensures (if it is supported by the operating system) that all read/write requests are sent with a special socket flag indicating that no SIGPIPE should be generated on broken connections.

- A CMakeLists.txt file is now included with the library to aid compiling PLCIO under Microsoft Visual C++ (MSVC).

- Several bugs have been fixed since the previous release of PLCIO. See the "Changelog" file for details.

PLCIO 4.5
Release Notes - December 14, 2015


New Features
Operating System Support:

This release of PLCIO adds support for compiling on two new operating systems: IBM AIX version 7 and FreeBSD version 10. The Makefile has been rewritten to handle compiling for different build environments, including but not limited to: GNU GCC, Clang, IBM's XL C compiler, and HP's aCC compiler.

Serial Multiplexer Capability:

PLCIO now has the ability to connect directly to several independent devices or PLC's that are sharing the same serial bus. The PLCIO library now keeps track of the serial ports that are open, allowing plc_open() calls on the same port multiple times (in the same process) but with different remote node numbers in each open call. 'plciod' is no longer required to act as the middleman to share a single serial port.

New Modules
New Omron Host Link Support:

This release introduces support for the Omron Host Link protocol using the 'hostlink' module. This allows PLCIO to communicate to an Omron PLC over a serial interface using standard C-mode commands. In addition, PLCIO can optionally send FINS commands over Host Link, which allows you to access tag names and extended address ranges over the serial bus as long as support is available on the PLC.

Modbus RTU Returns:

Support has returned for the Modbus RTU serial protocol using the 'modrtu' module. This new module completes the set of PLC's that were missing support since version 4.0 of the PLCIO series was introduced.

Other Enhancements

- On UNIX, the close-on-exec flag is now set on all file descriptors opened from within plc_open(). This fixes a problem where child processes spawned by the PLCIO application were keeping opened copies of file descriptors connected to the remote PLC's, even after plc_close() was being called by the parent process.

PLCIO 4.4
Release Notes - January 1, 2013


Release Highlights

New Omron PLC Support:

This release introduces support for Omron CS/CJ-series PLCs using the 'fins' PLCIO module. The new module can communicate to the PLC using FINS over the TCP, UDP, or EtherNet/IP protocols. All types of memory and I/O files can be read or written to directly. The 'fins' module can also download the symbol table from either the PLC's Memory Card, the EM file, or Comment memory, and use that as a lookup table to translate tag names to memory addresses during runtime.

Streaming I/O Slave Support:

PLCIO now has the ability to communicate to an Allen-Bradley Logix-series PLC using the implicit messaging version of the EtherNet/IP protocol. The new 'cipioslv' module allows the PLCIO application to appear to the PLC like an I/O bus coupler. It can read and write data similar to the normal Streaming I/O mode, however when the application is first started, it sits idly in the background (as a slave), waiting until the PLC (master) makes the connection.

Being a direct complement to the 'cipio' module, two PLCIO applications can now communicate to each other over implicit messaging by using both the 'cipio' and 'cipioslv' modules together.

PLCIO 4.3
Release Notes - January 27, 2011


Release Highlights

New ABDF1 Module:

Serial communication to Allen-Bradley PLC-5 and SLC 5/00 series PLCs has returned to PLCIO with the "abdf1" module. This module supports the full-duplex mode of the DF1 protocol, with both BCC and CRC checksum capability. This module can be coupled with the `plciod' daemon to allow several PLCIO applications to share a single serial port, with the option for each application to target a different PLC node on the DF1 network.

Other Enhancements

- The "step7" module has been enhanced to support Siemens S7-200 series PLCs as well as Rack selection on the S7-300 and -400 series systems.

- The ./configure script now allows you to specify your own compiler flags. This is useful for compiling a 32-bit library on an otherwise 64-bit system, and vice versa.

- Modules pertaining to Allen-Bradley PLC-5 and SLC 5/00 PLCs now have improved string support. "ST" files are now writable, and "A" files can now be read and written using the new PLC_RCHAR and PLC_WCHAR operation codes. Furthermore, reading "ST" files on a SLC 5/00 will now return strings in the correct byte-order. Applications using this feature should be changed to no longer manually perform byte-order conversions.

PLCIO 4.2
Release Notes - December 29, 2009


New Features

Streaming I/O:

PLCIO can now communicate directly with Ethernet I/O Bus Terminals using the EtherNet/IP protocol in a new mode called Streaming I/O. In Streaming I/O, inputs are constantly received from the remote device using Multicast Networking, and outputs are constantly transmitted--without acknowledgments or replies. Each output packet from PLCIO refreshes the device's entire set of outputs, providing for a stateless communications protocol.

Initial support is provided for two EtherNet/IP-based Bus Terminals:

* Beckhoff BK9105
* Phoenix Contact FL IL 24 BK ETH/IP-PAC

Use the new "cipio" module to communicate with I/O Bus Terminals.

Unsolicited Polling:

Two new API functions are added in this release: plc_fd_set() and plc_fd_isset(), which mirror the equivalent UNIX functions FD_SET() and FD_ISSET(). These functions supply the PLCIO application with the internal file descriptors used in PLCIO modules to listen for requests from the PLC. This allows the programmer to use a single select() call to poll for PLC-specific events, right alongside application-specific events.

Other Features:

- The "cipab" module is now split into two: "cipab", which handles PLC-5 or SLC 5/00 communications directly over EtherNet/IP, and "cipdh", which handles SLC 5/00 communications via Data Highway Plus over EtherNet/IP.

- Unified the CIP-style modules under a common CIP communications library, adding the following new features:
- Connected Messaging option for extra reliability.
- Proper EtherNet/IP Route Path specification using the Path=xxx keyword.

- Added new global variable 'j_plcio_open_timeout', which when set to a nonzero value, overrides the timeout for subsequent plc_open() calls (in milliseconds).

- Added 'j_sequence' to the PLCSLAVE structure to report the sequence number that is received with a Streaming I/O packet.

- Fixes and features for the "cip" module:
- Added support for tag sizes greater than 64KB.
- Added support for tag, program, and structure names up to 40 characters.
- Reading aliases to tags now return the correct data in all cases.
- The "showcip -s" command now displays the correct C structure for built-in ControlLogix types, such as MESSAGE, where issues existed with placement of padding and hidden structure members.

- PLCIO modules now have version information, which prevents users from accidentally loading modules using a newer or older libplc.so.

PLCIO 4.1
Release Notes - July 6, 2007


New Features

Remote Processing:

PLCIO now has built-in support for solicited communication with PLCs connected to remote computers over the ethernet. The new concentrator daemon, `plciod', forwards PLCIO requests from multiple applications to a single PLC in a round-robin fashion. Programs that were previously unable to share the same connection to a single PLC can now do so through the `remote' module.

Microsoft Windows Support:

PLCIO can now run on any Windows operating system version Windows 95 or later. Compiling PLCIO for Windows requires the MSYS/MinGW environment and a recent GCC compiler. Details can be found at http://www.mingw.org.

Other Features:

- Added "j_fileno" to the PLCSLAVE structure for Allen-Bradley file number retrieval.

- The PLCIO configuration file, plcio.cfg, now allows the keyword NULL to be present in the point configuration field. This lets users define a soft PLC but still use physical PLC addresses.

- Added two new keywords, PLC_LOG_NONE and PLC_LOG_TTY, that can be used as the argument to plc_log_init(). PLC_LOG_NONE is an alias for NULL, meaning to turn off all logging. PLC_LOG_TTY is an alias for the current terminal running the program.

PLCIO 4.0
Release Notes - April 9, 2005


Introduction

PLCIO 4.0 is a top-down rewrite of the original PLCIO library that CTI has provided for several years. This version continues to support dynamically- loadable modules for each PLC, while insuring identical API behavior independent of the module used. Although the PLCIO library remains mostly unchanged, binary compatibility is broken from previous versions of PLCIO. Programmers must recompile and link their applications to the new library.

New Features:

Portability:

PLCIO can now be compiled and operated on 64-bit architectures. It can be compiled with the GNU Compiler Collection (GCC) on any UNIX operating system. PLCIO continues to support HP-UX's native `cc' compiler as it has done in the past.

Hardened I/O:

PLCIO now sports an "industrially-hardened" I/O interface. All ethernet communication is now passed through special read/write functions. These functions will automatically restart if any interrupting signals are received, piece together broken TCP/IP frames, and obey the timeouts specified in the PLCIO function calls.

As a beneficial side-effect, PLCIO can now operate over relaying connections such as SSH tunnels and VPNs, where TCP/IP packets are usually fragmented and/or combined.

Logging:

With PLC verbose mode set to level 4, all PLC-level communications between server and PLC are now logged to a file in hexadecimal format, 16 bytes per line.

A new config-file keyword, $LOGSIZE, allows the user to set the maximum file size for logging. When this size is exceeded, the file is renamed with a .1 suffix and a new log file begins.

Errors:

A new error system is in place to address the shortcomings of PLCIO 3.x. The 'j_error' member of the PLC structure contains the error code of the last PLCIO API function, or 0 on success. PLCIO-specific errors use codes 1 through 99, and Module-specific errors use codes 200 and up.

Each part of PLCIO that produces an error logs a message to the 'ac_errmsg' structure member, up to 79 bytes long. This message contains information about the exact error that occurred, including actual error values returned by the PLC in some cases. It is no longer static, as in version 3.x.

Each PLCIO application can test for additional error values returned along with the PLCIO error by looking at the aj_errorval[0...7] structure member. Only specific PLCIO Errors fill in these values. Refer to the manual for the meanings of additional error values on a per-function and per-module basis.

The 'j_errno' member of the PLC structure contains the UNIX errno value at the time of the error.

With verbose mode set to 1 or greater, all PLCIO errors will automatically be logged with a detailed error message. This allows developers to easily view the errors of any PLCIO function call in the entire application.

Timeouts:

Starting with PLCIO 4.0, all timeouts are specified in milliseconds. Earlier versions relied on a HZ value to specify the number of ticks per second. The use of HZ was unstable, since HZ can change from machine to machine depending on the UNIX kernel used. This had a tendency to break binaries that were either cross-compiled or copied between servers.

Timeouts now denote the total amount of time between a PLCIO function call and the return from that call, instead of the amount of time allowed for each individual I/O operation inside. Programmers may need to account for more time if many PLC transactions are required for a single function call (such as large read/write requests).

A timeout of 0 turns off the timer for that particular PLCIO function.

For backward compatibility, the value HZ is #defined in to be always 1000 regardless of OS or implementation.

Argument Validation:

All PLCIO function-call arguments are now validated in the PLCIO library proper before being passed to the modules. This makes module-writing extremely simple to program, as each module need only be written with the basic I/O tasks required to communicate with the PLC. This fixes many bugs where parameter checking was inconsistent (or missing) between modules.

In a similar fashion, all format conversion is now handled on the PLCIO-side and taken away from the modules. Modules have the option to override this.

The unsolicited (slave) version of the plc_read() call is now handled in PLCIO as a shortcut for plc_receive() and plc_reply(). This eliminates many lines of duplicated code per module that earlier handled those two cases separately. This led to correcting many bugs, most that were present in one version of the read/receive code but not in the other.

Serial I/O:

Support for opening a serial device is once again included in PLCIO 4.0. Users can select baud rates from 300 up through 460800, byte sizes from 5 to 8 bits, even/odd/no parity, and 1 or 2 stop bits. Users can also choose between hardware (RTS/CTS), software (XON/XOFF), or no flow control (provided the underlying hardware supports these options).

Library Changes

- The #include file no longer includes any system headers. Programmers are expected to #include all required headers for their applications.

- Unsolicited-only modules `enipab5' and `enipslc' have been integrated into a single module, 'enip'. Applications should use the new module name.

- Allen-Bradley modules 'abeth5' and 'abeth500' have been integrated into asingle module, 'abeth'. For solicited communication, programmers can select the PLC-5 or SLC500 version using plc_open("abeth plc5 hostname") and plc_open("abeth slc500 hostname"). The module supports unsolicited communication from both types of PLCs simultaneously.

- Module 'cipab5' has been renamed to 'cipab'.

- The PLCSLAVE structure was changed to store more information for the application during a plc_receive() call. In this version, the 'j_ipaddr' structure member was added to record the IP Address of the PLC sending the message. Using the "(sock_node *)plc_ptr->pavoid" structure to determine the IP Address is no longer valid and should not be used.

- The plc_status() function was dropped from the library.

- Physical PLC points can now be accessed with plc_read() or plc_write(), evenwhen the PLC is opened using logical access. This can be done by prefixing the function's 'pc_addr' argument with a ! symbol. This method is recommended only for diagnostic purposes.


CTI, A DIVISION OF THE POLING GROUP
Founded in 1978, CTI has been a valuable resource for large industries. Since 2001, we've expanded the capabilities of Poling Group tire equipment, including uniformity and geometry testing machines.

©2024 The CTI Division of the Poling Group