CPX - AP-I - EtherNetIP - App Note
CPX - AP-I - EtherNetIP - App Note
100299
Title ............................... CPX-AP-I with EtherNet/IP; Rockwell Systems and Others; Rockwell Systems and Others
Version ............................................................................................................................................................. 1.10
Document no. .............................................................................................................................................. 100299
Original .................................................................................................................................................................en
Author ............................................................................................................................................................. Festo
Copyright Notice
This documentation is the intellectual property of Festo SE & Co. KG, which also has the exclusive copyright. Any
modification of the content, duplication or reprinting of this documentation as well as distribution to third par-
ties can only be made with the express consent of Festo SE & Co. KG.
Festo SE & Co KG reserves the right to make modifications to this document in whole or in part. All brand and
product names are trademarks or registered trademarks of their respective owners.
Legal Notice
Hardware, software, operating systems and drivers may only be used for the applications described and only in
conjunction with components recommended by Festo SE & Co. KG.
Festo AG & Co. KG does not accept any liability for damages arising from the use of any incorrect or incomplete
information contained in this documentation or any information missing therefrom.
Defects resulting from the improper handling of devices and modules are excluded from the warranty.
The data and information specified in this document should not be used for the implementation of safety func-
tions relating to the protection of personnel and machinery.
No liability is accepted for claims for damages arising from a failure or functional defect. In other respects, the
regulations with regard to liability from the terms and conditions of delivery, payment and use of software of
Festo SE & Co. KG, which can be found at www.festo.com and can be supplied on request, shall apply.
All data contained in this document do not represent guaranteed specifications, particularly with regard to func-
tionality, condition or quality, in the legal sense.
The information in this document serves only as basic information for the implementation of a specific, hypo-
thetical application and is in no way intended as a substitute for the operating instructions of the respective
manufacturers and the design and testing of the respective application by the user.
The operating instructions for Festo products can be found at www.festo.com/sp .
Users of this document (application note) must verify that all functions described here also work correctly in the
application. By reading this document and adhering to the specifications contained therein, users are also solely
responsible for their own application.
Table of contents
1 Components/Software used ................................................................................................................... 4
2 Introduction ........................................................................................................................................... 5
7 Handling Parameters with the CPX-AP System via the Parameter Object ................................................ 26
7.1.1 CPX-AP Parameter IDs and Instances; Use Case – Write to specific ID ........................................ 26
7.1.2 CPX-AP System Reading Parameter Object; Use Case – Read Parameters for use in HMI ............ 28
Application Note – CPX-AP-I with EtherNet/IP; Rockwell Systems and Others – 1.10 Seite 3 von 32
Components/Software used
1 Components/Software used
CPX-AP-I-EP-M12 Rev0.54.3 --
CPX-AP-I-4DI4DO-M12-5P Rev1.46.4 --
CPX-AP-I-8DI-M8-3P Rev1.46.4 --
VAEM-L1-S-24-AP Rev1.46.4 --
Rockwell Studio 5K V30, V31 --
Rockwell 1769-L30ERMS PLC V31 --
Google Chrome -- --
Seite 4 von 32 Application Note – CPX-AP-I with EtherNet/IP; Rockwell Systems and Others – 1.10
Introduction
2 Introduction
The CPX-AP-I-EP is an EtherNet/IP adapter that connects Festo CPX-AP-I modules to EtherNet/IP. This note will
cover web server based features of the CPX-AP-I-EP system to assist in configuration of the EtherNet/IP adapter
with Rockwell and other systems.
Festo provides documentation in a user manual to configure and use the AP-I system. This application note is
intended to provide details and hints for additional features possible when using a ControLogix or CompactLogix
PLC from Rockwell over EtherNet/IP, or any other EtherNet/IP master system. Therefore, it is a prerequisite to
this note that the user must use the Festo documentation of the AP-I system modules for valves, I/O, and Ether-
Net/IP. This is needed to become especially familiar with the following:
• Use of the Rotary switches of the CPX-AP-I-EP module
• Understanding of the LEDs of the system
• Understanding of the power, communication, and network cables used for the system
• Understanding power requirements, power distribution, and grounding of the system
• Understanding the use of module parameters
Application Note – CPX-AP-I with EtherNet/IP; Rockwell Systems and Others – 1.10 Seite 5 von 32
Terminal View for AP Modules
The CPX-AP-I-EP adapter is always slot 1 of the AP system. The left AP-I connector is the primary branch. All
modules connected to the primary branch consume the next available slot numbers, in order of connection. The
leftmost AP-I connector is the incoming branch (topmost for pneumatic), the rightmost is the outgoing branch.
VAEM-L1-S-24-AP
CPX-AP-I-4DI4DO-M12-5P CPX-AP-I-EP-M12
Seite 6 von 32 Application Note – CPX-AP-I with EtherNet/IP; Rockwell Systems and Others – 1.10
Terminal View for AP Modules
VAEM-L1-S-24-AP
The right AP-I connector is the Secondary branch of the AP-I system. Modules connected to the Secondary
branch start consuming slot numbers after the last slot number of the Primary branch. The above example
shows the completed test system with all 4 slots consumed.
3.1.2 AP - Terminal
The CPX-AP-I-EP webserver shows the connected configuration of the modules, slots 1 to 4 in this example. The
module description, code, FW version, and serial numbers, and product key are displayed. The EP product key is
not displayed since this is the password for the web access. This is found on the label of the adapter. It is typi-
cally “AP_I_EP_xxx"
Sign-in access required. User: admin Password: the product key of the EP adapter found on label
Application Note – CPX-AP-I with EtherNet/IP; Rockwell Systems and Others – 1.10 Seite 7 von 32
Terminal View for AP Modules
Each module can be configured by clicking on it. For example, slot 1 is the EtherNet/IP adapter. One click on the
module opens the parameter selection list for the module.
Slot 1. The CPX-AP-I-EP module has configuration parameters for IP address maintenance and supply voltage
diagnostics.
NOTE: Each parameter has instance numbers for the CIP Parameter Object and AP ID instance. This facilitates
easy look-up for module parameters. Every module has this list. See Parameter Object section of App Note.
Slot 2 example. The CPX-AP-I-4DI4DO-M12-5P has configuration parameters for debounce time, and fail safe
state for outputs (default off or hold last state).
Some modules, such as the 4 channel analog input may have an extensive list of parameters. The 4AI module
has 52 parameters for configuring the 4 analog channels.
Seite 8 von 32 Application Note – CPX-AP-I with EtherNet/IP; Rockwell Systems and Others – 1.10
Terminal View for AP Modules
Application Note – CPX-AP-I with EtherNet/IP; Rockwell Systems and Others – 1.10 Seite 9 von 32
EtherNet/IP View for Commissioning
Seite 10 von 32 Application Note – CPX-AP-I with EtherNet/IP; Rockwell Systems and Others – 1.10
EtherNet/IP View for Commissioning
o The diagnostic field will be structured as follows: Size is 12 bytes + mod count * 12 bytes
13 + n * 12 1 Submodule
14 + n * 12 1 Channel
20 + n * 12 4 Diagnosis Code
• The Status and Diagnostic information for Global only are 12 bytes, offset 0-8 in the above table.
The Assembly View page shows useful information for commissioning the AP-I system. This includes:
• The I/O size of the system
• The bit padding of the individual modules
• Bit length and datatype of the channels
• Module / channel description
Application Note – CPX-AP-I with EtherNet/IP; Rockwell Systems and Others – 1.10 Seite 11 von 32
EtherNet/IP View for Commissioning
Simply enter a name for the project to be created, and select the desired check boxes:
Configuration Assembly:
• Default Enable. This will generate an Assy Instance size (number of array bytes) and populate the array
with data matching the parameters set in the web browser or external SW tool (future planned).
Status Assembly:
• Default is Global and Module Status. A Generic Ethernet Module with Status Inputs will be generated.
There will be 12 bytes global plus 12 bytes per module allocated for Status and Diagnostics. This in-
cludes the EtherNet/IP adapter as a module.
• User selects Global Only status. A Generic Ethernet module with Status Inputs will be generated. There
will be 12 bytes of data allocated for Status and Diagnostic.
• User selects no Status. A Generic Ethernet Module will be generated without Status inputs.
• Refer to section 4.1.1 under Status and Diagnostic Instances for the structure of the information.
Webserver:
• Default enable. The user can change this parameter so the webserver is disabled, if they wish to have
no webserver access.
• Write Access, default enabled. The user can disable write access. This is useful if the user wishes to
prevent someone from changing the parameters of the system, but still wants viewing access.
o If these are disabled when using the exported L5X project, each time the controller connects to
the system, the webserver will not be enabled or have no write access while the machine is
running. All of the exported parameter settings will be used.
SNMP:
• Default is enabled. SNMP is useful for troubleshooting purposes of ethernet networks. MIB browsers
use SNMP for providing access to diagnostic network info.
• SNMP can also be an avenue for security risk. Ethernet parameters can be changed with this protocol.
Therefore the user can disable this via the web browser.
Seite 12 von 32 Application Note – CPX-AP-I with EtherNet/IP; Rockwell Systems and Others – 1.10
EtherNet/IP View for Commissioning
To reverse these, the user can edit the project Config tag name in Studio 5000 Logix specific to the web server
access, webserver enable, or SNMP enable. One, 1, is enable; 0 is disable.
Application Note – CPX-AP-I with EtherNet/IP; Rockwell Systems and Others – 1.10 Seite 13 von 32
EtherNet/IP View for Commissioning
Step 4.2.2.2
Step 4.2.2.3
Step 4.2.2.4
Seite 14 von 32 Application Note – CPX-AP-I with EtherNet/IP; Rockwell Systems and Others – 1.10
EtherNet/IP View for Commissioning
2. Select all rungs of the created project, right click, and select “Export Rungs”.
Step 4.2.3.2
Application Note – CPX-AP-I with EtherNet/IP; Rockwell Systems and Others – 1.10 Seite 15 von 32
EtherNet/IP View for Commissioning
3. This will create a file name “Rungs0toN_from_MainRoutine_(user name entered).L5X”. Select Export.
Step 4.2.3.3
4. Import the file from the previous step into the user project. Right click on any rung, preferably in the
Main Routine, and select Import Rungs. A pop-up will confirm the import of the rungs, plus datatypes
and other components. Select OK.
Step 4.2.3.4
Seite 16 von 32 Application Note – CPX-AP-I with EtherNet/IP; Rockwell Systems and Others – 1.10
EtherNet/IP View for Commissioning
5. The L5X imported into the user project provides Tag names with custom datatypes (UDTs), and the logic
to copy this data to the raw I/O instances of the Generic Ethernet Module set-up. Move the logic as nec-
essary to suit your needs.
Step 4.2.3.5
Application Note – CPX-AP-I with EtherNet/IP; Rockwell Systems and Others – 1.10 Seite 17 von 32
EtherNet/IP View for Commissioning
Image 4.2.4.1, example of input and output tags with custom UDT descriptions
Image 4.2.4.2; Shows benefit of UDT. Transition from digital to analog device shows the appropriate datatype.
No conversions necessary when programming to UDT.
2. A set of rungs in ladder logic to do a Synchronous Copy of data from the custom tag names to the raw
I/O Assembly Instances of the Generic Ethernet Module. It is good practice to keep the CPS instruction
for the inputs or status near the top of the user logic, and the CPS instruction for the Outputs should be
near the bottom of the logic where setting outputs occurs.
Image 4.2.4.3
Seite 18 von 32 Application Note – CPX-AP-I with EtherNet/IP; Rockwell Systems and Others – 1.10
System View for Diagnostics and Information
The Outputs regained power about 57 seconds later. Grey “X” means the problem was resolved.
Application Note – CPX-AP-I with EtherNet/IP; Rockwell Systems and Others – 1.10 Seite 19 von 32
System View for Diagnostics and Information
The user can copy this data and paste into Notepad to be used with Festo technical support:
5.1.2 Information
The information page provides basic information such as firmware version, product name, and network configu-
ration information such as IP address, netmask, gateway, etc.
5.1.3 About
This has license information of components used in the AP-I adapter.
Seite 20 von 32 Application Note – CPX-AP-I with EtherNet/IP; Rockwell Systems and Others – 1.10
Handling Diagnostic Events
The configuration will include a status connection, and an array of bytes suitable for the amount of diagnostic
data. A UDT and logic is also generated for a proper data-structure and logic to pass the data to the structure.
This enables intuitive mapping of the diagnostic data to Logix.
The data-structure below contains an example of a diagnostic event, lost output power.
In this example:
• The top group is the Global data. The latest code reported is 0x0201_0106. In the manual, this
is an error with PL24vdc.
• Each other group is specific for a module, with the lowest module number on top. Only mod-
ules with an output report an error, others are error free. Note state=5 means voltage prob-
lem, but also communicating OK. See diagnostic bit table below.
NOTE: With Assy Instance 130, and Fixed Assy Instances with Global status, only the top group is available. This
is to limit the amount of PLC data.
Application Note – CPX-AP-I with EtherNet/IP; Rockwell Systems and Others – 1.10 Seite 21 von 32
Handling Diagnostic Events
Device available
0 11 Software
(Communication ok)
1 Current 12 Maintenance
2 Voltage 13 Misc
3 Temperature 14 reserved
4 reserved 15 reserved
5 Movement 16 External Device
Configuration /
6 17 Security
Parameter
7 Monitoring 18 Encoder
8 Communication 19-31 reserved
9 Safety
10 Internal Hardware
6.1.2 Use Case – Use Status and Diagnostic Objects to access diagnostics with Service Data
Diagnostics are always available, even without access from process data. The Status and Diagnostic Object can
access diagnostic information with a n explicit message. This is optimally used in combination with Global diag-
nostics only. Therefore the process data for diagnostics are fixed at 12 bytes, and further detailed data can be
read via explicit message.
Status and Diagnostic Object Class = 0x65. Get the last active diagnosis per module.
Ac-
Attribute Name Type Description Value
cess
Class Attributes
Global Diagno-
8 Get UDINT see Global Diagnosis State
sis state
Instances
Seite 22 von 32 Application Note – CPX-AP-I with EtherNet/IP; Rockwell Systems and Others – 1.10
Handling Diagnostic Events
Instance Attributes
Module diagno-
1 Get UDINT see Module Diagnosis State
sis state
In addition, another valuable object is the Trace data object. The system will log up to 512 events which can be
retrieved by an explicit message. Instance 1 will retrieve the latest event.
Revision of the
1 Get Revision UINT 1
object
Num instances of
Current number of trace
3 Get Num instances UINT the CIP object
entries
currently created
0 = Overwrite
8 Get/Set Trace mode USINT
1 = Acknowledge
Instances
Instance Attributes
Application Note – CPX-AP-I with EtherNet/IP; Rockwell Systems and Others – 1.10 Seite 23 von 32
Handling Diagnostic Events
1 = information
2 = maintainance required
6 Get Severity USINT
4 = warning
8 = error
0 = inform
7 Get Type USINT 1 = raise
3 = resolve
By using other CIP services, all attributes of one diagnostic trace can be accessed at once by the Get Member
service 0x18.
Acknowledge
0x32
trace entry
Item Datatype
Timestamp ULINT
Module UINT
Submodule UINT
Channel UINT
Severity USINT
Type USINT
Acked USINT
The following ladder code example shows how to set-up the MSG instruction and array for the Trace data Get
Member service. Instance 1 is the latest trace entry.
Seite 24 von 32 Application Note – CPX-AP-I with EtherNet/IP; Rockwell Systems and Others – 1.10
Handling Diagnostic Events
Some errors do not recover automatically. This is true for a link error in the AP-I bus. This is typically indicated
by an error code 0x0801_0127. Also, global status bit 8 will be on indicating communication error. To recover
from this error, recycle power will work. It is also possible to recycle the connection from the PLC.
This shows the global diagnostic field where bit 8 is on for the status, and the lost link diag code is present.
The following 2 rungs can recover from this via the PLC logic. Triggering the open contact will inhibit the PLC
ethernet connection to the CPX-AP ethernet adapter. Once the physical connection is restored, removing the
trigger will allow the connection to restore. NOTE: inhibiting the connection will turn off all I/O.
Application Note – CPX-AP-I with EtherNet/IP; Rockwell Systems and Others – 1.10 Seite 25 von 32
Handling Parameters with the CPX-AP System via the Parameter Object
7 Handling Parameters with the CPX-AP System via the Parameter Object
7.1.1 CPX-AP Parameter IDs and Instances; Use Case – Write to specific ID
Parameter IDs are common IDs among the system modules. They can be read or written to via EtherNet/IP. A
partial list of parameters can be found in the user manual. The webserver lists the ID in parameter order num-
ber, from the first parameter of the first module (the EtherNet/IP adapter) to the last parameter of the last mod-
ule.
Seite 26 von 32 Application Note – CPX-AP-I with EtherNet/IP; Rockwell Systems and Others – 1.10
Handling Parameters with the CPX-AP System via the Parameter Object
These parameters can be modified by the user program a variety of ways. One method is by the:
With these services the user can easily read or write to a parameter of the AP system.
The message instruction should have a source element large enough for the data
The element is populated according to the Parameter Object service. In this case, 0x4e36 is 20022dec, which is
the monitoring load supply parameter, of module 1. The data sent is 2, which is Load Supply monitoring active:
Application Note – CPX-AP-I with EtherNet/IP; Rockwell Systems and Others – 1.10 Seite 27 von 32
Handling Parameters with the CPX-AP System via the Parameter Object
7.1.2 CPX-AP System Reading Parameter Object; Use Case – Read Parameters for use in HMI
The Parameter set of the CPX-AP-I system also follows the Parameter Object of the CIP Common spec. The user
can get any pertinent information about the parameter set by querying the parameter object.
The Parameter Object Class is 0x0F. The table below has the various attributes per the specification, not all are
supported by the CPX-AP at initial release. Any parameter attribute 100 or more is vendor specific.
Ac-
Attrib- Name Type Description Value
cess
ute
depend on
Max instances of the CIP ob-
2 Get Max instances UINT configuration
ject
of AP system
depend on
Num instances of the CIP ob-
3 Get Num instances UINT configuration
ject currently created
of AP system
0 - English
1=French
2=Spanish
Native Language Selec- 3=Italian
10 Get/Set USINT 0
tion 4=German
5=Japanese
6=Portugese
7=Mandarin Chinese
Instances
Instance Attributes
Specified
by
1 Get/Set Parameter Value
Datatype
Attribute 5
Seite 28 von 32 Application Note – CPX-AP-I with EtherNet/IP; Rockwell Systems and Others – 1.10
Handling Parameters with the CPX-AP System via the Parameter Object
USINT or
Datatype definition of this in-
5 Get Datatype ARRAY of
stance
USINT
SHORT_S
7 Get Parameter Name String Max 16 chars
TRING
SHORT_S
8 Get Units string Max 4 chars
TRING
SHORT_S
9 Get Help string Max 64 chars
TRING
Specified
Minimum value of parameter
by
10 Get Minimum Value instance. For string types this
Datatype
represents minimal length.
Attribute 5
Specified
Maximum value of parameter
by
11 Get Maximum Value instance. For string types this
Datatype
represents maximal length.
Attribute 5
Specified
by
12 Get Default Value
Datatype
Attribute 5
Application Note – CPX-AP-I with EtherNet/IP; Rockwell Systems and Others – 1.10 Seite 29 von 32
Handling Parameters with the CPX-AP System via the Parameter Object
International Parameter
22 Get STRINGI
Name
International Engineering
23 Get STRINGI
Units
With the Parameter Object it is possible to read all parameters of the CPX-AP system in logic and place the data
in a data-structure, which can be used to display on an HMI, or other visualization. Festo can provide source
code with an AOI to help support this function:
Example of source code and AOI. When executed, the data-structure can be populated as follows. The AOI
simply needs the number of parameters in the system, found from the web server - last module.
Each MSG instruction needs to point to byte [0] of the data-structure, parameter name. Class, Instance, Attrib-
ute can be left 0, the AOI will populate these as required.
Seite 30 von 32 Application Note – CPX-AP-I with EtherNet/IP; Rockwell Systems and Others – 1.10
Handling Parameters with the CPX-AP System via the Parameter Object
The data-structure can be copied from a template provided with the AOI. Simply create an array size for the QTY
of parameters + 1. In this case, there were 15 parameters. Do not expand the variables called “buffer”.
The results are shown below for interesting parameters of the CPX-AP system. Array[1] through [15] are the data
of the parameters in order 1 – 15. Array[0] is a temporary storage, and not to be used by the user.
Application Note – CPX-AP-I with EtherNet/IP; Rockwell Systems and Others – 1.10 Seite 31 von 32
Handling Parameters with the CPX-AP System via the Parameter Object
Seite 32 von 32 Application Note – CPX-AP-I with EtherNet/IP; Rockwell Systems and Others – 1.10