Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                

Module 07 - Ethernet - IP

Download as pptx, pdf, or txt
Download as pptx, pdf, or txt
You are on page 1of 56

Module 07 – Ethernet/IP

Agenda
 Ethernet/IP Overview
 Terminal Configuration
 Define Ethernet/IP in the PLC
 EDS file and RSLinx
 RSNetworx for Ethernet/IP
 Ethernet/IP Watch-Outs
 Sample Program
- Floating Point
- Integer
 Shared Data Access
 Troubleshooting
 Assessment
 Exercise

1
Ethernet/IP Overview
Developed in the 1990's by ControlNet International.
Released in 2001, the standard is currently managed by ODVA.
Common Industrial Protocol (CIP) based.
Two standards speeds, 10 MBPS and 100 MBPS.
Message scheduling not necessary because of the use of smart
switches and higher network speeds.
RSNetworx for Ethernet/IP generally not needed with MT Industrial Devices
Device Level Ring (DLR) topology NOT available on Industrial
Terminals because of single port Module.
EDS File only needed to identify device for RSLinx

Module
DON'T USE the EDS file as an EDS AOP!!
supplied
by HMS Cyclic messages are referred to as "Class 1", "Implicit", or
"Scheduled" messages

Acyclic messages are referred to as "Class 3", "Explicit", or


"Unscheduled" messages (requires Message Instructions)

The same as ControlNet (and that's no accident)!

2
Ethernet/IP Overview - Continued
Works with standard RJ-45 Ethernet cables,
as well as cables with M12 connectors.

Works with standard Ethernet switches


and ruggedized switches

Works with standard Routers

But should NOT be used with an Ethernet HUB!


(control networks don't tolerate collisions very well)

The Ethernet architectures have the widest array of


topology configurations available. Please review Module
02 - Section 01 - Fieldbus Network Overview - Topology
Overview for details.

3
QoS and IGMP Snooping
Two important terms that we must be aware of on Ethernet/IP are QoS and IGMP Snooping.

QoS – Quality of Service


Quality of service determines how packets are marked, classified, and treated based on traffic type. EtherNet/IP
devices can prioritize traffic internally.
QoS does not increase bandwidth. Implementing QoS at the switch level adds another level of prioritization, and
gives preferential treatment to some network traffic at the expense of others.

QoS is used for streaming types of data, such as voice and video. It also works well with implicit (cyclic) data,
which is actually a form of streaming data.

IGMP – Internet Group Management Protocol


IGMP is a communication protocol used to manage the membership of IP multicast groups. Much of EtherNet/IP
implicit (I/O) messaging uses IP multicast to distribute I/O control data, which is consistent with the CIP
produced/consumer model.
Without IGMP, switches treat multicast packets like broadcast packets, so that multicast packets will be
retransmitted to all ports.

IGMP Snooping
The behavior of an unmanaged switch is to flood multicast packets to all ports within the same VLAN. This is not typically
desirable. To resolve this IGMP Snooping implements the following:
• A Querier manager maintains a table that lists the devices that are participating in multicast groups.
• Snooping functionality inspects packets and forwards multicast data only to the devices that requested the data.

IGMP snooping constrains the flooding of multicast traffic by dynamically configuring switch ports so that multicast traffic is
forwarded to ports associated with only a particular IP multicast group.
Note: The Querier must reside on a router or centrally located IGMP capable device, such as a switch.

4
Terminals that Support Ethernet/IP

Ethernet/IP is supported on all of the following terminals:

* Limited Variable (Shared


Data) Access

All terminals use the same Ethernet/IP module

5
Agenda
 Ethernet/IP Overview
 Terminal Configuration
 Define Ethernet/IP in the PLC
 EDS file and RSLinx
 RSNetworx for Ethernet/IP
 Ethernet/IP Watch-Outs
 Sample Program
- Floating Point
- Integer
 Shared Data Access
 Troubleshooting
 Assessment
 Exercise

6
Ethernet/IP – Terminal Configuration

1. In Setup, navigate to "Communications | PLC Interface"

2. Navigate to "Ethernet/IP – Modbus/TCP"

3. Most times, a static IP address will be used. In those cases, enter the
desired IP Address, Subnet Mask, and Gateway Address.

2
3

7
Ethernet/IP – Terminal Configuration Continued

1. Navigate to "PLC Interface | Data Format"

2. Set Format to "Floating Point"


and Byte Order to "Word Swap"
3. Press the Message Slot Edit button

4. Make sure that a scale is


2 4 defined.

If one is not defined, use


the Add button.
3

8
Agenda
 Ethernet/IP Overview
 Terminal Configuration
 Define Ethernet/IP in the PLC
 EDS file and RSLinx
 RSNetworx for Ethernet/IP
 Ethernet/IP Watch-Outs
 Sample Program
- Floating Point
- Integer
 Shared Data Access
 Troubleshooting
 Assessment
 Exercise

9
Ethernet/IP – Define in PLC
Make sure that the Bridge module
is physically in the slot specified
by the PLC Program (Slot 2 – slot
numbering starts at zero)!

The PLC rack must have an


Ethernet/IP Bridge installed in the
chassis

The individual nodes must be defined


under the module - can be a "Generic
ControlNet Module" or an Add On
Profile (AOP).
This is where the Ethernet/IP Network's implicit (cyclic) data
configuration is set up.

Note that this has nothing to do with the EDS file!!!

10
Ethernet/IP – Configure Nodes in PLC
2 different ways to define a node in the PLC program
1. Generic Ethernet Module 2. Add On Profile (AOP)

Look up values in manual Configure from Pull Down menu


(more details on this later)
I/O Shows up here

11
Agenda
 Ethernet/IP Overview
 Terminal Configuration
 Define Ethernet/IP in the PLC
 EDS file and RSLinx
 RSNetworx for Ethernet/IP
 Ethernet/IP Watch-Outs
 Sample Program
- Floating Point
- Integer
 Shared Data Access
 Troubleshooting
 Assessment
 Exercise

12
EDS File and RSLinx
Loading the EDS file into RSLinx allows it to identify the DeviceNet device on the
network.

If the EDS file has not been loaded,


then the device will show up with a
Question Mark in the Network View.

To install the EDS file into RSLinx, you need to:


1. Shut Down RSLinx.
2. Use the EDS Hardware Installation tool to load the EDS file.

13
Agenda
 Ethernet/IP Overview
 Terminal Configuration
 Define Ethernet/IP in the PLC
 EDS file and RSLinx
 RSNetworx for Ethernet/IP
 Ethernet/IP Watch-Outs
 Sample Program
- Floating Point
- Integer
 Shared Data Access
 Troubleshooting
 Assessment
 Exercise

14
RSNetworx for Ethernet/IP
RSNetworx for Ethernet/IP is primarily used for:

 Set up Device Level Ring (DLR) topology


 Set up Producer/Consumer network data
 Set up I/O Scanner (rack)
 Monitor or troubleshoot a network.

With Industrial Terminals, we are not concerned about those things. So,
we won't use RSNetworx for Ethernet/IP

15
Agenda
 Ethernet/IP Overview
 Terminal Configuration
 Define Ethernet/IP in the PLC
 EDS file and RSLinx
 RSNetworx for Ethernet/IP
 Ethernet/IP Watch-Outs
 Sample Program
- Floating Point
- Integer
 Shared Data Access
 Troubleshooting
 Assessment
 Exercise

16
Rememeber this Ethernet/IP Gotch-ya!
WARNING!!! Not all PLC's can use Ethernet/IP cyclic data!!!

SLC
MicroLogix
MicroLogix 1400
1200

These PLC's can only use discrete (also known as explicit


MicroLogix or acyclic) message instructions.
1000
These PLC's should NOT directly control a feed themselves (the weight data comes back too
slowly and with unpredictable time delays), but should use the onboard target logic of the Terminal.
And this … The EDS - Add On Profile
ControlLogix (version 20 and higher) has a feature that allows
AOP's to be created from a device's EDS file.

DO NOT USE THIS!!!


At present, the EDS Hardware Installation Tool does not handle the
many different configuration possibilities of Mettler-Toledo's terminals.
The result is an AOP that will not function as expected.

Instead, use the Custom AOP


18
Agenda
 Ethernet/IP Overview
 Terminal Configuration
 Define Ethernet/IP in the PLC
 RSNetworx for Ethernet/IP
 Sample Program
- Floating Point
- Integer
 Shared Data Access
 Troubleshooting
 Assessment
 Exercise

19
Define a Floating Point IND780 using the AOP

Leave only
"Communication" checked
Enter a name
Enter the IP Address
Check only "Mettler-Toledo"

Click "Change" to setup


the module
Select Format
Select "New Module…"

Select IND780 Ethernet/IP

Select how many


message slots

20
AOP I/O Data Tags
Floating Point Integer

Select "Controller Tags" and then Right Click

DataSelect
FROM "Monitor
IND780 Tags"

Data TO IND780

21
Agenda
 Ethernet/IP Overview
 Terminal Configuration
 Define Ethernet/IP in the PLC
 RSNetworx for Ethernet/IP
 Sample Program
- Floating Point
- Integer
 Shared Data Access
 Troubleshooting
 Assessment
 Exercise

22
Floating Point Program
First, we're going to go over the Floating Point program sample.

The Floating Point example is


contained in this subroutine.

The Floating Point example uses


this Ethernet/IP Module

23
Floating Point: Rung 1
For a detailed explanation of the Data OK and the Data Integrity bits, see this
discussion: Industrial Terminal Overview.pptx - Floating Point Special bits

Check the Terminal Status


Check the Data Integrity

"Controller Tags" View

Note that the CPS instruction automatically copies BOTH Also note the use of a SYNCHRONOUS Copy Instruction to
FPdata1 and FPData2 into the FloatingPoint_Data Tag. make sure that we get BOTH words of data at the same time!

24
Floating Point: Rung 2
For a detailed explanation of the Command Acknowledge, see this discussion: Industrial Terminal
Overview.pptx - Floating Point Command Acknowledge

When the IND780 receives a


command from the PLC, it changes
the states of the CmndAck1 and
CmndAck2 bits in the message slot
Command status word.

"Controller Tags" View The program uses these bits to drive


a Command Acknowledged bit that
will be used in later rungs
25
Floating Point: Rung 3
Rung 3 causes the PLC program to mimic the operation of the Terminal in that the value in the command
register being transmitted to the terminal must change before the terminal will act on the command.

This rung copies the new


command to the Command
Output tag…

… and the command data (if any) to


the Output Data tags.

"Controller Tags" View

26
Floating Point: Rung 4

Each command bit -

- initiates a move that transfers a


Floating Point Command value into
the "Command" Tag, which is
processed on the previous rung
(rung 3 – see previous slide).

When the Command is acknowledged


(see rung 2, 2 slides back -

- the bit that triggered the command


sequence is cleared.

The "IND780_Data_Displayed" value -

- is generated on the next rung.

27
Floating Point: Rung 5
For a detailed explanation of the Floating Point Indicator, see this discussion: Industrial Terminal
Overview.pptx - Floating Point Indicator

The 5 Floating Point


Input Indicator bits

Should be treated
as an Integer value
between 0 and 31.

This rung converts the bits -

- into an Integer value.

"Controller Tags" View

28
Agenda
 Ethernet/IP Overview
 Terminal Configuration
 Define Ethernet/IP in the PLC
 RSNetworx for Ethernet/IP
 Sample Program
- Floating Point
- Integer
 Shared Data Access
 Troubleshooting
 Assessment
 Exercise

29
Integer Program
Now we'll go over the Integer program sample.

The Integer example is contained


in this subroutine.

The Integer example uses this


Ethernet/IP Module

30
Define an Integer IND780 using the AOP

Leave only
"Communication" checked
Enter a name
Enter the IP Address
Check only "Mettler-Toledo"

Click "Change" to setup


the module
Select Format
Select "New Module…"

Select IND780 Ethernet/IP

Select how many


message slots

31
Integer: Rung 1
Reading basic data from the Terminal
The UpdateInProgress is
similar to the Data Integrity
bit in that it indicates that
the IND780 is currently
updating the buffer and that
the data should not be
used.

Check the Terminal Status


"Controller Tags" View with the DataOK bit.

Value that converts the Integer data


to Floating Point data. The value is
hard coded by the program. Calculated Working Data based off
of Integer data from the terminal and
the hard-coded 'Increment' value.

If the DataOk bit is off, flag the


problem by writing -9999.0 to the
Working Data.

32
Integer Program
Command to Tare the Scale

To cause the scale to Tare, set


this bit to 1 (true) either from
Then the flag is cleared here
an operator interface, or from
the PLC program.

As a result, the Integer number 32 (bit


5 = On) is moved to the Command
Word Output.

The scale should Tare immediately

33
Integer Program
Commands to Clear and Zero the Scale
Then the flag is cleared here

To cause the scale to Clear the Tare, set


this bit to 1 (true) either from an operator
interface, or from the PLC program.

As a result, the Integer number 16 (bit 1 = On)


is moved to the Command Word Output.

To cause the scale to Zero, set this bit to


1 (true) either from an operator interface,
or from the PLC program.
As a result, the Integer number 128 (bit 7 = On)
is moved to the Command Word Output. Then the flag is cleared here

The scale should respond immediately to each command.

34
Integer Program
Commands to return different kinds of data.
These commands work like the previous rungs

This MOV command is used only to display the data


coming back from the Terminal.

Set the corresponding bit for the desired data

Move the corresponding command into the


Command Output register

Then clear the command flag

35
Integer Program
Command to do a Preset Tare
Again, this works like the previous commands – with one change

But we have an additional step where the amount


that we want to Pre-Tare by is moved to a Staging
Variable where it can be converted to units that the
scale will understand. See the next rung. Then the flag is cleared here

To cause the scale to do a Preset Tare, set this bit As a result, the Integer number 8 (bit 3 = On)
to 1 (true) either from an operator interface, or is moved to the Command Word Output.
from the PLC program.

36
Integer Program
Normalize the Floating Point Data Output
This rung converts the Floating Point data to Integer Data so it can be written to the Terminal

The data to be converted is in this "staging variable"

Divide the "staging variable" by the same value we used


to convert the incoming Integer data to Floating Point.

The result goes to the Output data register,


which is written directly to the Terminal.

37
Agenda
 Ethernet/IP Overview
 Terminal Configuration
 Define Ethernet/IP in the PLC
 RSNetworx for Ethernet/IP
 Sample Program
- Floating Point
- Integer
 Shared Data Access
 Troubleshooting
 Assessment
 Exercise

39
Shared Data
Shared Data Access is nearly identical to what we did for ControlNet. But let's review the
whole thing anyway.

Shared Data is memory reserved inside of the Terminal that holds configuration and
process information, and it is updated constantly.

Shared Data
Gross Weight
Request Units
NET Weight
0.001 KG
Rate
Units

The PLC can Read from OR Write


to Shared Data using Discrete
(Explicit) message commands.

40
Shared Data Access Overview
In order to access Shared Data, a program must provide the following information to the
Read and Write message instructions:
• Class Code This information can be found in the Shared Data Reference
• Instance Number Manual for each Shared Data variable.
• Attribute Number
• Length For a link to the IND780's Shared Data Reference Manual, click here

For example, here is how you would find the information for a ‘WT’ type Shared Data variable:

The Shared Data Variable name is


Instance
constructed from much of that information:
Class

Length

Attribute

NOTE: Other terminals such as the IND570 and


the IND131/331 follow a similar concept.

Also note: The IND131/331 has only a small set of variables that it can access using this method.
Please see Appendix B in the IND131/331's PLC manual: 64067815_R10_IND131-331_PLC_EN.pdf

41
Shared Data Access Subroutine Call

The Shared Data Access sample code is run in this subroutine.

42
Shared Data Access: Rung 1
This subroutine responds to individual request flags by triggering discrete messages.

Request a Tare command be sent to the Terminal.

If the instruction in not already running, trigger the message.

When the message is complete, unlatch the request flag.

43
Shared Data Access: Rung 1 – Message configuration

We're setting a Boolean flag. To do that, write a single byte with a value of 1.

Open the Message


configuration by
"Controller Tags" View clicking here

Specify a Write by selecting "Set Attribute Single."

Scale Number

Shared Data Reference Manual

44
Shared Data Access: Rung 1 – Message configuration

Now all that's left is to set the Communication Path

Click the "Communication" Tab

Click the "Browse" button

Select the Float Terminal

Click OK

Click OK

45
Shared Data Access: Rung 2 – Message configuration

The Clear message rung works exactly like the previous one,
with one minor difference…

Shared Data Reference Manual

The message Attribute is set to 2

46
Shared Data Access: Rung 3 – Message configuration
Reading data is very similar to writing…
Specify a Read by selecting "Get Attribute Single."

"Controller Tags" View

Data is read into an 80 Byte


Buffer, 1 byte at a time.

Shared Data Reference Manual


When the Read is complete,
the COPY instruction moves The MOV instruction allows
the bytes into a Floating us to see the result.
Point variable.

47
Shared Data Access: Rung 4 – Message configuration
Reading data from the Integer Terminal is exactly the same as reading
from the Floating Point terminal
with one difference:

Click on Communication
Click on Browse

Select the Integer Terminal


Click Okay

Click Okay

48
Shared Data Access: Rung 4 – Data Conversion
Even converting the data is the same:

When the Read is complete,


the COPY instruction moves The MOV instruction allows
the bytes into a Floating us to see the result.
Point variable.

49
Shared Data Access: Summary
Major Points to remember for Shared Data Access

Shared Data in the Terminal contains BOTH Configuration information AND Process Data, such as Weight.

The PLC can Read FROM or Write TO Shared Data if a ControlNet Class has been defined for it.

A Shared Data variable name contains the Instance


and Attribute.
Most Shared Data variables can NOT* be accessed
using standard Cyclic Data.

* Exception: See Templates for the fieldbus interface.

Shared Data Access by a PLC is usually done using Discrete Message Instructions.

The format of the data returned by a Shared Data Access is NOT affected by the selected format of
the Terminal (Floating Point or Integer). The same Message instructions work on either format.

You will need access to the Shared Data Reference Manual to correctly set up your message instructions.

Note: The IND131/331 has only a small set of variables that it can access using this method.
Please see Appendix B in the IND131/331's PLC manual: 64067815_R10_IND131-331_PLC_EN.pdf

50
Agenda
 Ethernet/IP Overview
 Terminal Configuration
 Define Ethernet/IP in the PLC
 RSNetworx for Ethernet/IP
 Sample Program
- Floating Point
- Integer
 Shared Data Access
 Troubleshooting
 Assessment
 Exercise

51
Troubleshooting
• Look at the LED status of the module.
• Use PC to ping for IP Addresses.
• Confirm that Ethernet/IP Bridge is in correct PLC Slot.
• See the device in RSLinx before trying to add it to the Network.
• I/O size mismatch.
• Proper Format and Message Slots defined?
• Byte Order (IND560 may be different from others)!
• Check Connection Tab 'Module Fault' frame in PLC for error
message.
• Make sure that the Ethernet/IP network is plugged into the
Ethernet/IP module, not the terminal's TCP/IP RJ-45 connector.
• Make sure that user put the Ethernet/IP's IP configuration in the
Ethernet/IP configuration and not the TCP/IP Network setup.
• Confirm cable connections to switch and PLC.
• DIP switches on Module should all be UP.
• Use Generic Module or Custom AOP, not EDS AOP.
• Ethernet Switch Settings (Full Duplex, 100 MBPS, Auto
Negotiate).
• Check for IP Address Conflict.
• Cyclic works, but Explicit don't. Check MSG Connection Path
settings.
• Explicit Works, but cyclic don't. Check that PLC is capable of
Cyclic messaging.
• Check Firmware version of Ethernet/IP module in PLC Chassis.
52
Agenda
 Ethernet/IP Overview
 Terminal Configuration
 Define Ethernet/IP in the PLC
 RSNetworx for Ethernet/IP
 Sample Program
- Floating Point
- Integer
 Shared Data Access
 Troubleshooting
 Assessment
 Exercise

53
Assessment
True or False

Acyclic messages are referred to as "Class 3", "Explicit", or "Unscheduled"


messages True

All PLC's can transmit Implicit messages. False

Shared Data Access in Floating Point Format is the same as in Integer Format. True

Ethernet networks are simpler than older fieldbuses. False

The PLC must be in Program Mode before scheduling the Network. False

Cyclic (Implicit) data is similar to streaming data, such as voice or video. True

An Ethernet/IP device will work fine on the network without an EDS file. True

Ethernet/IP switches need to support QoS True

IGMP Snooping can cause Multicast Storms False

54
Agenda
 Ethernet/IP Overview
 Terminal Configuration
 Define Ethernet/IP in the PLC
 RSNetworx for Ethernet/IP
 Sample Program
- Floating Point
- Integer
 Shared Data Access
 Troubleshooting
 Assessment
 Exercise

55
Exercise – Connect a Terminal
The entire class will connect their Terminals to the PLC via Ethernet/IP.
Use the Industrial Fieldbus Training HMI to communicate to your device.
• Check the PLC Image. What's in the first 2 Input words?
Use Floating Point Format • Do a Cyclic Pushbutton Tare
• Do a Cyclic Clear Tare
• Do an Acyclic Pushbutton Tare
• Do an Acyclic Clear Tare
• Write a Value to AJ0101
• Read back AJ0101
• Do a Cyclic Programmed Tare
• Report the Gross Weight
• Report the Net Weight
• Put your terminal into Setup. What happens to the status
and data coming back when you change the scale value?
• Put the terminal back into run, then cycle power. What
happens to the Data OK bit?
• Change your Terminal to Integer Format. What error is
returned in the PLC Connection Tab?
• Take the same IP Address as someone else. What
happens?

56

You might also like