Page 32 - Industrial Technology April 2021 issue
P. 32
SYSTEMS INTEGRATION
IO-LINK INTEGRATION
SENSORS AND SYSTEMS
CHARLIE WALKER, SMART SENSOR SPECIALIST WITH SICK (UK),
DISCUSSES IO-LINK DEVICE INTEGRATION USING FUNCTION BLOCKS
f your job involves integrating IO-Link devices into any operators to introduce new IO-Link integrations is opening
kind of automated system, then the chances are you up – all without the possibilities of errors creeping in and
will have had to create a Function Block. Function being repeated. Now, new web-based software technology
IBlocks are capsules of information that simplify PLC is being developed that creates IO-Link function blocks
programming. They are useful tools that can even replace and integrates device data into a wide range of common
hardwired physical components for common tasks like PLC control systems in a matter of minutes. You can
timers or counters. If, like me, you belong to the ranks of follow a step-by-step process in a web-browser
competent, but by no means specialist, PLC programmers dashboard, and create a fully-tested function block ready
who use Function Blocks to make system set-up quicker to use in your code.
and more reliable, you will probably also find them a You don’t need to be experienced in IO-Link and
tedious part of the job that most of us probably don’t look there’s no need to start searching for parameters, indexes
forward to. and data formats. You can download a library with all of
So how do you create a Function Block? This involves the software you need to install the Function Block as well
writing some code and specifying the inputs and outputs as the full supporting documentation.
to that set of instructions. You may include some other Let’s imagine a production line, where there is a
functions that already exist within the programming conveyor system with hundreds of diverter stations. You content of libraries can be defined individually through
environment. Then, the whole thing is compiled into a may want the sensors at each station to be used in very free selection of the available device parameters and can
library, along with any other supporting files that help it to similar ways. Using a function block ‘factory’ gives us a be adjusted at any time. In addition, process data parser
work. Once it has been fully tested, the function can be chance to create the control code very quickly for all the functions can be generated, simplifying and speeding up
called on repeatedly by the PLC without needing to repeat sensors, while still having the ability to tweak each one’s PLC programming considerably, as well as helping to
the base code. Just as importantly, the Function Block exact operation, depending on the inputs selected. avoid errors. The process data parser function makes it
must be fully documented so that anyone who uses it later possible to systematically access any individual piece of
also understands what the purpose of the block is, and Critical data information in the IO-Link process data, without having
how it works. Now, we will also want to extract critical data from the been previously informed of its structure and contents
All this takes time, and that means cost. You might sensors to aid with timely service and maintenance, as from manuals.
have invested hours, and more likely days, depending on well as to avoid unnecessary downtime. That critical data You can select special features to reduce programming
the task in hand and the complexity, to write and test can be extracted automatically via the Function Block. If effort significantly. So, for example, the multi-selection
Function Block functionality. Even then, you still need to we monitor the level of dirt build-up on the sensor, for option allows for simultaneous reading of several
create the library and document the block. example, then the value of that data is that it allows us to parameters and there’s no need to program elaborate
I have had function libraries sent over to me that have make very accurate predictions about how long we can sequence chains to read or write the parameters in
been created in a rush by a colleague in order to help me expect the sensor to perform at acceptable levels, before it succession.
solve a problem. Naturally, I have been grateful, but, fails and we incur downtime. If, for example, we know that Enumerators (enums) replace meaningless numbers
without the documentation to support the block, I have we have one week or more before an expected failure, we with names. This not only accelerates the development
needed to spend considerable time understanding how to can schedule maintenance to clean the sensors when it process as it is no longer necessary to look anything up,
incorporate it into my code. If specific types of data causes us the absolute least downtime. On the flip side, if but the source code becomes easier to read and clearer for
structures have been used in the Function Blocks, that are a failure is imminent, the data enables us to intervene as third parties at a later point in time. A subindex access
not already part of the library, then you must spend extra soon as practical to prevent unscheduled stops. function serves to reduce data loss and communication
time creating them before you can really get moving with Sick’s Function Block Factory is the first web-based length. Instead of complete, complex variables – referred
the project. service of its type that enables users to create function to as records in the IO-Link context – it makes it possible
The good news is that software tools are now being blocks automatically for most common PLCs. It will work to read out defined sub-variables or to change them via a
developed that can quite literally ‘manufacture’ Function for any IO-link device with an I/O device description write function. The entire record therefore does not have
Blocks in a matter of minutes. As a result, the scope for (IODD), no matter what the device type or its to be transmitted back and forth; only a fraction of it must
manufacturer. To create a Function Block, users simply be transmitted, namely the sub-variable.
sign in to the Sick 24/7 web service, select the IODD file Data is one of the most important commodities of
for the IO-link device and the chosen PLC system. The modern factory environments. To fully realise its value, it
name of the Function Block can be edited to suit naming must be extracted from the ‘eyes and ears’ of the system
conventions. Then, the IO-Link parameters and key as painlessly as possible. Those eyes and ears are the
features of the Function Block are selected. sensors, and the data could be anything from a count
The function block created can be used to read and value, the amount of dirt on a sensor window or a
write parameters and service data for any IO-Link device. reflector.
It handles the entire acyclic IO-Link communication The potential to create Function Blocks quickly and
including data interpretation, index and sub-index reliably unlocks many more benefits for IO-Link
resolution as well as byte-swapping, if required. integrations. It invites users to expand the scope of their
As part of the library provided, the data structure automation projects and to try out new ideas. So what
already contains all required variables, so the need for will your next project be?
manual variable declaration is eliminated. The scope and MORE INFORMATION: www.sick.co.uk
32 INDUSTRIAL TECHNOLOGY • March/April 2021