0% found this document useful (0 votes)
181 views110 pages

Types of Fieldbus PDF

Uploaded by

Rizky Muhammad
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
181 views110 pages

Types of Fieldbus PDF

Uploaded by

Rizky Muhammad
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 110

BECKHOFF Fieldbus Networks Workshop

Fieldbus System Details


• Ethernet
• Profibus
• DeviceNet
• Sercos

1
BECKHOFF Fieldbus Networks Workshop

Industrial Ethernet: Overview


Background Has been in use for controller – controller communication for years.
New: use as fieldbus replacement.
Medium Access CSMA/CD
Control Method
Addressing Ethernet: physical Node Address; IP: IP-Address; TCP/UDP: port-Address
Transmission Media, Shielded and unshielded twisted pair, Plastic Fibre Optics (PMMA); 10/100 Mbit/s
Baudrate 10 Mbit coax-cable is hardly in use any more
Topology UTP/STP/POF: star topology (hubs or switches)
Node Hierarchy Depends on protocol
Network expansion 100m between node and hub/switch
Frame Length Ethernet: up to 1500 Bytes; process data lenght depends on protocol used
Error Detection CRC
Priorities No. Prioritised Ethernet will come, but cannot be mixed with standard ethernet
devices
Typical Cycle times 10... 50ms (not deterministic, single frames can be delayed much longer)

2
BECKHOFF Fieldbus Networks Workshop

Ethernet: Overview

Ethernet transmits pakets of 46-1500 data bytes


Transmission Media (10MBit/s)
• Koax cable for bus topology (10Base5 “Thick Cable”, 10Base2 “Cheapernet”);
• Fibre Optics (10BaseF)
• Shielded twisted pair (STP) or unshielded twisted pair (UTP) 10BaseT for star topology
Header: Physical Addresses:
• 22Bit Manufacturer ID (OUI: Organizationally Unique Identifier) and 24Bit Serial Number
• further: Protocol-Info, Address type (Peer to Peer, Broad-, Multicast etc.)
Media Access Method: CSMA/CD
• Advantage: no need to make each Node known to the network
• Disadvantage: behavior is non deterministic
• Pakets „die“, if media access failed 15 times in a row

3
BECKHOFF Fieldbus Networks Workshop

Switched Ethernet Topology


•Switched Ethernet (full-duplex) avoids collisions
•But: still non deterministic, as switches need paket queues PC w/
HMI
Soft PLC
PC w/ PC w/
Modular PLC Block I/O
HMI Config Sw
E Small Robot
P I/O N I/O Controller
L E Device
C T

10/100M Ethernet ENet 10/100M Ethernet ENet


Switch Switch 10/100M Ethernet

Device

Block I/O Device


E
E N
N I/O I/O
Block I/O I/O I/O E
E
T Block I/O
T

Modular I/O Rack

4
BECKHOFF Fieldbus Networks Workshop

TCP/IP Stack: Overview


•TCP/IP (or UDP/IP) is embedded in Ethernet Packet
•Structure supports Exchange of protocol layers
8 Bytes

20 Bytes UDP-Hdr. UDP-Data


(IP-Port)
TCP-Header TCP-Data
(IP-Port)
20 Bytes

IP-Header
PROT

IP-Data
(IP-Address)
22 Bytes

Ethernet-Header 46...1500 Bytes Ethernet-Data CRC


08-00

(MAC-ID)

5
BECKHOFF Fieldbus Networks Workshop

Internet Protocol (IP): Overview


• Datagram with 20 Byte Header
• Unsecured Data transport from a source to a destination address
• Header: Addresses, Header-Checksum, Protocol infos,Time to Live,
Fragmentation infos etc.
• Supports Routing between networks
• IP-Addresses: Network-
and Host address version Hdr Len Service Type Total Length
16bit Identification Flags 13bit Fragment Offset
• Address resolution
20 Bytes

8bit Time to Live 8bit Protocol 16bit Header Checksum


with ARP 32bit Source IP address
32bit Destination IP address
Options (if any), padding

IP Datagramm Data (up to 65535 Bytes)

Ethernet SA DA 0800 IP Header and Data CRC

6
BECKHOFF Fieldbus Networks Workshop

User Datagram Protocol (UDP): Overview


Simple datagram-oriented data transport, carried in IP data
Non-guaranteed delivery of data
• Packets may be delivered out of order or may not be delivered at all!
Less overhead than TCP
Needed for broadcast and multicast applications
Good for request / response type protocols
• SNMP
8 Bytes

16bit source port number 16bit destination port number


• TFTP
16bit UDP length 16bit UDP checksum
• DHCP / BOOTP
UDP data
(theoretically up to 65507 Bytes,
typically restricted by the implementation)

IP IP-HDR (PROT=17) UDP Header and Data

SA DA 0800 IP Header and Data CRC


7
BECKHOFF Fieldbus Networks Workshop

Transmission Control Protocol (TCP): Overview


Connection oriented data transport, carried in IP data
• Point to point between exactly two host ports
Reliable: Transfers are acknowledged, Order of sequential packets maintained
Data transferred as a stream of bytes
Good for protocols needing
16bit source port number 16bit destination port number
to move streams of data 20 Bytes 32bit sequence number
• HTTP,FTP,SMTP 32bit acknowledgement number
HDR LEN (reserved) flags 16bit window size
Only works with unicast 16bit TCP checksum 16bit urgent pointer
IP addresses TCP data
• No broadcast or multicast (theoretically up to 65495 Bytes,
typically restricted by the implementation)

IP IP-HDR (PROT=06) TCP Header and Data

SA DA 0800 IP Header and Data CRC


8
BECKHOFF Fieldbus Networks Workshop

TCP: Connection
Establish: Three way handshake between two hosts
• Host 1 sends SYN (synchronize) to host 2
• Host 2 sends ACK to host 1 along with its own SYN
• Host 1 sends ACK to host 2

Terminate: Four way handshake


• Host 1 sends FIN (final) to host 2
• Host 2 send ACK to host 1
• Host 2 (in a separate message) sends FIN to host 1
• Host 1 sends ACK to host 2

-> it takes some time to establish/terminate a connection!

9
BECKHOFF Fieldbus Networks Workshop

ARP: Address Resolution Protocol


TCP Address:
MAC-ID ?
Port Number

If no entry in ARP Cache


IP
Address
Send ARP Request
with IP Address and MAC ID
Ethernet FF FF FF FF FF FF
Address:
MAC-ID Node answers with MAC-ID
and both MAC-ID and IP-Address
Number are entered
in ARP Cache

Communication starts
10
BECKHOFF Fieldbus Networks Workshop

IP Address Assignment
Several Possibilities:
1. Setting by Local Software (PC) or Configuration Tool
2. DHCP (Dynamic Host Configuration Protocol)
– requires configuration of DHCP Server
3. BootP (Bootstrap Protocol)
– requires BootP Server
4. ARP –s (adds entry in ARP cache, can be used
to assign IP-Adress to MAC-ID via network)
5. DIP-Switch (on field devices, typically only for LSB)

11
BECKHOFF Fieldbus Networks Workshop

Ethernet: ProfiNet
ProfiNet:
• Access to Profibus Networks via
Ethernet
• Protokoll: RPC (Remote Procedure
Calls) via TCP/IP or UDP/IP
• DCOM-based
• DCOM will not be advanced by
Microsoft (Source: VSLive Conf.)
• DCOM is not Internet-compatibel
(e.g. Firewall )
• Microsofts new developments are
base on HTTP and TCP/IP, SOAP
(Simple Object Access Protocol:
XML based description)
• ProfiNet is not (yet): Profibus on
Ethernet
12 • But: Real Time ProfiNet will come
BECKHOFF Fieldbus Networks Workshop

Ethernet: IDA
•Initially „Kuka and Friends“ + Jetter
•Kuka meanwhile pulled out
•Has selected NDDS (RTI) as
Middleware, uses TCP/IP und
UDP/IP
•Therefore NDDS-User Schneider
joined IDA
•5/2000: Jetter drops VentureCom
DCX and moves to NDDS
•So far white papers and device
model finished
•No final protocol solution published,
no products available yet.

13
BECKHOFF Fieldbus Networks Workshop

Ethernet: Ethernet IP
•ODVA und Control and Information Protocol (CIP)
ControlNet
International Semi Pneu AC Position Other
Devices Valve Drives Cntrllrs Profiles
•CIP (Control User
and Information Layer
Protocol) on Application Object Library
TCP/IP and
UDP/IP
Application Application Layer
•No data Explicit, I/O, Routing
Layer
concerning real
time capability
encapsulation
available Transport DeviceNet ControlNet
DLL DLL Future
and Data Link UPD TCP
•Sample Code Layer Transport Transport
available IP

•First devices
are entering DeviceNet ControlNet Ethernet
Physical
marketplace Layer
Physical Physical Physical Future
Layer Layer Layer
ATM, Firewire
14 USB, Blue Tooth
BECKHOFF Fieldbus Networks Workshop

IAONA: Industrial Automation Open Networking Alliance

+ + : Memorandum Of Understanding

• IAONA (Europe + US together) becomes umbrella


organisation for Industrial Ethernet
• IDA and Ethernet/IP are recognized by IAONA as de
facto standards
• other groups are invited to join
• areas not covered yet („white spots“) are tackled jointly
(Joint Work Groups)
• therefore: new structure of IAONA
15
BECKHOFF Fieldbus Networks Workshop

IAONA: Industrial Automation Open Networking Alliance


TSC Chairman: Peter Klüger, Kuka
Deputy chairman: Martin Rostan, Beckhoff
29 members 129 members
Board IAONA US 2 2 Board IAONA Europe
Technical Steering
Member IAONA US Committee Member IAONA Europe

TSC tasks:
•Installs Workgroups Chairman
Chairman Joint Technical
•Publishes Standards
Chairman Joint Technical
Workgroup
•Coordinates work of the
Workgroup
Joint Technical
Workgroups
Workgroup

16 PNO? FF? OMAC?


BECKHOFF Fieldbus Networks Workshop

Ethernet: Modbus TCP


• Serial Modbus Protocol on
TCP/IP
Query message from Master
• Master/Slave (Polling)
Transaction ID Transaction ID
• Few Services, easy to Protocol ID Protocol ID
implement Length Length
Unit ID Unit ID
• Wide spread use Modbus fct code Modbus fct code
• Only for moderate Real
Time Requirements Data Data

Response message from Slave

17
BECKHOFF Fieldbus Networks Workshop

Beckhoff ADS
Automation Device Specification:
• Ethernet TCP/IP for networking of control system
• Not just on TCP/IP or UDP/IP: available on most field bus systems as well

LAN
PC Control System PC Control System PC Control System
VB OPC DLL Ethernet VB OPC DLL Ethernet VB OPC DLL Ethernet

ADS Router ADS Router ADS Router

PLC PLC NC Fieldbus PLC PLC NC Fieldbus PLC PLC NC Fieldbus


Fieldbus

Bus Controller Bus Controller

ADS Communication Path

18
BECKHOFF Fieldbus Networks Workshop

ADS Message Router


Communicates locally, via User Interface
COM Interface, TCP/IP or
Fieldbus Visual C++
PLC System
Program
Addresses: Control Manager
ADS DLL
• Clients in public Networks ADS ADS ADS
via TCP/IP
• Local Networks TCP/IP TwinCAT ADS text
Message Router

• Clients in local Networks


ADS ADS ADS
• Fieldbusses
PLC NC
• Coupler in Feldbus systems I/O Mapper Server Server
• Server processes
I/O Level

Fieldbus C

Fieldbus D
Fieldbus A

Fieldbus B

Fieldbus E
19
BECKHOFF Fieldbus Networks Workshop

ADS Protocol
• Client / Server-Principle on TCP or UDP
• Services:
–Synchronous read/write AMS Net ID: Addresses the Device

16 Bytes
ADS Port: Target Location of Data
–asynchronous read/write Index Group
Index Offset
–connect (with defined Cycle Time)
ADS Data
–notification on change (with minimal
Cycle Time)
UDP or TCP Hdr UDP Data or TCP Data

IP IP-HDR) UDP Header and Data

SA DA 0800 IP Header and Data CRC


20
BECKHOFF Fieldbus Networks Workshop

Ethernet: Multi-Protocol Devices


Modbus
Beckhoff Ethernet ProfiNet “CIP”
I/O Devices ADS BOOTP
FTP HTTP DNS SNMP DHCP
support all relevant
Protocols –
if possible even in TCP UDP
parallel!
OSPF IGMP
ICMP
IGRP

ARP IP RARP

Ethernet

21
BECKHOFF Fieldbus Networks Workshop

Beckhoff and Ethernet at work:


Microsoft Headquarter Munich

22
BECKHOFF Fieldbus Networks Workshop

Microsoft Headquarter Munich: Details Building 1 Building 2

Terminal rail 1 Terminal rail 4

•11 Buildings
•44 Floors, 27000 m² 3. Floor
Terminal rail 1 Terminal rail 4

•11 Building Controller


•164 Bus Controller (BC9000) 2. Floor

•12000 digital I/O Points Terminal rail 1 Terminal rail 4

•2100 analogue I/O Points


1. Floor
Terminal rail 1
•User Interface: Web Browser Terminal rail 4

•Protocol: ADS on UDP/IP


Ground Floor

Building Computer

23
BECKHOFF Fieldbus Networks Workshop

Ethernet: Cycle Times


• Ethernet Cycle Time is hardly predictable.
• Depends on software runtimes (UDP + TCP) and
100
timing behavior of „Master“ (COTS Technology)
90
• 100 Mbit Switched Ethernet:
80 almost independent of no. of nodes and of no. of bytes.
70
Cycle Time [ms]

Modbus TCP: Node Response within 10..20 ms, Cycle Times 40..60 ms
60

50

40
Beckhoff ADS/UDP: Node Response within 1..4 ms, Cycle Times 15..25 ms
30

20

10

0
5 10 15 20 25 30
No of Nodes
24
BECKHOFF Fieldbus Networks Workshop

Ethernet: Conclusions
• high baudrate is not always equal to high performance
• standardisation of Industrial Ethernet is not finished yet
• interoperability is not guaranteed yet
• its either COTS technology or hard real time
• infrastructure costs (industrial components) still
significantly higher than with standard fieldbus systems
Therefore:
Ethernet is no ideal replacement for standard fieldbus
systems (yet), but a nice alternative for applications with:
- existing Ethernet infrastucture
- low real time requirements
25
BECKHOFF Fieldbus Networks Workshop

Profibus DP: Overview


Background Profibus Sensor/Actuator derivative, initially developed by Siemens
Medium Access Polling. If more than one master present, masters use additional token passing
Control Method method
Addressing Node Addressing. Frame contains transmitter and receiver address
Transmission Media, RS485: shielded twisted pair, fibre optics (plastic); 9,6 kbit/s....12 Mbit/s
Baudrate
Topology Electrical: bus (line) with terminating resistors; FO: ring
Node Hierarchy Typical: 1 Master, up to 31 slaves. With repeater: up to 126 nodes. Several
masters possible.
Network expansion 100 m (12 Mbaud), 200 m (1,5 Mbaud), 1200 m (93,75 kBaud). With 3 repeaters:
values times 4 (segment – repeater – seg – rep – seg – rep – seg)
Frame Length 0...246 Bytes. Typical: 1...32 Bytes
Error Detection CRC. Hamming Distance: 4 (3 Bits out of 32 (246) x 8 may change)
Priorities 2
Typical Cycle times 1...3 ms

26
®

BECKHOFF Fieldbus Networks Workshop PROCESS FIELD BUS

Profibus-DP: Topology

Termination Termination

Station Repeater
1
2 3 30 31

Termination
Repeater

62 61 33 32
* Note: Repeaters do not have a station address, but they
count towards the max. number of stations in each segment

27
®

BECKHOFF Fieldbus Networks Workshop PROCESS FIELD BUS

Profibus-DP: Termination
first station last station
Bus Termination Bus Termination
VP VP
390 Ω 390 Ω
110 nH Data Line B 110 nH
B B
220 Ω 220 Ω
110 nH Data Line A 110 nH
A A
390 Ω 390 Ω
DGND DGND

A B A B
Station 2 Station 3

28
®

BECKHOFF Fieldbus Networks Workshop PROCESS FIELD BUS

Profibus-DP: Shielding/Grounding
Master Recommended Practise
Slave Slave

ground rail ground rail ground rail

Screen grounding
data cable data cable clamp

ground cable, potential equalization

Grounding rail close


to cable lead-through

29
®

BECKHOFF Fieldbus Networks Workshop PROCESS FIELD BUS

Profibus-DP: Monomaster System


DP-Master (Class 1)
Monomaster Systems achieve the
shortest bus cycle time
PLC
They consist of:
- 1 DP-Master (Class 1)
- 1 to max. 125 DP-Slaves
- DP-Master (Class 2) - optional

PROFIBUS-DP

Distributed Inputs and Outputs

DP - Slaves

30
®

BECKHOFF Fieldbus Networks Workshop PROCESS FIELD BUS

Profibus-DP: Multi Master System


Several DP-Masters PROFIBUS-DP Multimaster systems consist of:
may access a DP-Slave with read functions - multiple Masters (Class 1 or 2)
- 1 to max. 124 DP-Slaves
DP-Master - max. 126 devices on the same bus
(Class 2) PC

CNC PLC
DP-Master
(Class 1) DP-Master
(Class 1)

PROFIBUS - DP

distributed inputs and outputs distributed inputs and outputs

PROFIBUS-P
DP - Slaves
31
®

BECKHOFF Fieldbus Networks Workshop PROCESS FIELD BUS

Profibus-DP: Multi Master Media Access

Active Stations, Master Devices

PC
PLC PLC

polling polling
PROFIBUS

Passive Stations, Slave Devices, get polled, no direct slave to slave communication
32
®

BECKHOFF Fieldbus Networks Workshop PROCESS FIELD BUS

Profibus-DP: Protocol Classes

DPV0 Cyclic Process Data Communication

DPV1 Alarm and acyclic Services (e.g.


Parameter data)

DPV2 Slave to Slave Communication (via


Master), Equidistance (Motion Control)

33
®

BECKHOFF Fieldbus Networks Workshop PROCESS FIELD BUS

Profibus-DP: Timing
Time

Master Slave
TSYN = 33 Tbit

Request
Telegram
TRDY Request
min TSDR

Response
Response
max TSDR
Telegram

Legend: TRDY = Ready Time


TSDR = Station Response Time, typically 11 TBit
TSYN = Synchronization Time, typically 22 TBit
34
®

BECKHOFF Fieldbus Networks Workshop PROCESS FIELD BUS

Profibus-DP: Calculation of Cycle Time


TMC = ( TSYN + TID1 + TSDR + Header + I x 11TBit + 0 x 11TBit ) x Slaves
TMC = Message Cycle Time in Bit Times
TID1 = Idle Time at the Master = typically 75 TBit
TSDR = Station Delay Time at the Slave = typically 11TBit
Header = Telegram Overhead in Request and Response Frame = 198 TBit
I = Number of Input Data Bytes per Slave
O = Number of Output Data Bytes per Slave
Slaves = Number of Slaves

Example: PROFIBUS-DP System consisting of 1 Master and 20 Slaves each


with 2 Byte Input and 2 Byte Output Data.
TMC = ( 33 + 75 + 11 + 198 + 22 + 22 ) x 20 = 7220 TBit
7220 TBit (1.5 MBaud) = (TBit = 0.66 µs) = 4.8 ms
7220 TBit (12 MBaud) = (TBit = 0.83 ns) = 0.6 ms
In practice, a safety margin of approx 10 to 20% should be added for bus administration,
diagnostic messages and retries (after bit errors).
35
®

BECKHOFF Fieldbus Networks Workshop PROCESS FIELD BUS

Profibus: Cycle Times


40
12 MBaud, 2+2 Bytes
35 12 MBaud, 6+6 Bytes
12 MBaud, 20+20 Bytes
1,5 MBaud, 2+2 Bytes
30 1,5 MBaud, 6+6 Bytes
1,5 MBaud, 20+20 Bytes
Cycle Time [ms]

500 kBaud, 2+2 Bytes


25 500 kBaud, 6+6 Bytes
500 kBaud, 20+20 Bytes

20

15

10

0
5 10 15 20 25 30
No of Nodes
36
®

BECKHOFF Fieldbus Networks Workshop PROCESS FIELD BUS

Profibus-DP: Troubleshooting
Simple test for eliminating the most common wiring errors:
• Data cable crossed over
• Open circuit of one of the data cables
• Open circuit of the cable shield
• Short circuit between the data cables
• Short circuit between data cables and cable shield
• Additional bus terminating resistors inserted unintentionally

37
®

BECKHOFF Fieldbus Networks Workshop PROCESS FIELD BUS

Profibus-DP: Troubleshooting
Test each segment after installing cables and attaching bus
connectors, but:
- bus connectors must not be connected to Profibus devices
- bus terminating resistors must be removed or disabled
Test equipment: 2 test connectors DB9, 1 Ohmmeter
• Connector 1 with double pole single throw switch; moving
contact connected to shield (case) of the test connector.
Fixed contacts connected to pin 3 (data wire B) and pin 8
(data wire A).
• Connector 2 used to connect the Ohmmeter to the bus

38
®

BECKHOFF Fieldbus Networks Workshop PROCESS FIELD BUS

Profibus-DP: Troubleshooting
RS 485 Segment


8 3 Bus Connector Bus Connector 8 3
screen Bus Connectors of screen
further stations

Test Connector 1 Test Connector 2

Wiring Test Setup

39
®

BECKHOFF Fieldbus Networks Workshop PROCESS FIELD BUS

Profibus-DP: Troubleshooting Ω
A B A B

8 3 Bus Connector Bus Connector 8 3


screen screen

Test Connector 1 Test Connector 2

Test Step 1:
TC1: first connect pin 3 and shield
TC2: measure resistance R between pin 3 and shield
If R < 10 Ω: Data B and shield connection o.k.
If R = infinity: Data B or shield open circuit
Then disconnect pin 3 and shield at TC1
Resistance R now has to be infinite.
If not: short circuit between data B and shield or
40 Data A and Data B swapped over
®

BECKHOFF Fieldbus Networks Workshop PROCESS FIELD BUS

Profibus-DP: Troubleshooting Ω
A B A B

8 3 Bus Connector Bus Connector 8 3


screen screen

Test Connector 1 Test Connector 2

Test Step 2:
TC1: connect pin 8 and shield
TC2: measure resistance R between pin 8 and shield
If R < 10 Ω: Data A and shield connection o.k.
If R = infinity: Data A or shield open circuit
Then disconnect pin 8 and shield at TC1
Resistance R now has to be infinite
If not: short circuit between data B and shield or
41 Data A and Data B crossed over
®

BECKHOFF Fieldbus Networks Workshop PROCESS FIELD BUS

Profibus-DP: Troubleshooting Ω
A B A B

8 3 Bus Connector Bus Connector 8 3


screen screen

Test Connector 1 Test Connector 2

Test Step 3: Bus terminating resistors


TC1: switch position is not important
TC2: measure resistance R between pin 3 and pin 8
If R = infinite: o.k., if no terminating Resistors connected
If R = 220..230 Ω: 1 Terminating Resistor connected
If R = 110..120 Ω: 2 Terminating Resistors connected
If R = <110 Ω: too many Terminating Resistors

42
®

BECKHOFF Fieldbus Networks Workshop PROCESS FIELD BUS

Profibus-DP: Installation Guidelines (RS485)


Profibus cables and cables for... must be laid...
- Bus signals, e.g. PROFIBUS in the same cable conduit or cable way.
- Data signals for PC´s, programming devices,
printers etc.
- Screened analog inputs
- Unscreened DC voltages (<= 60V)
- Screened process signals (<= 25 V)
- Unscreened AC voltages (<= 25V)
- Coaxial cables for monitors
- DC voltages from 60V... 400V (unshielded) in separate cable conduit or cable way
- AC voltages from 25V... 400V (unshielded) without minimum spacing requirements
- DC and AC voltages > 400 V (unshielded) inside control cabinet: in separate cable
- Telephone cables conduits or cable ways without minimum
- For areas with explosion hazard spacing requirements
outside control cabinets: In seperate cable
runs spaced at least 10cm (4‘‘) apart
43
BECKHOFF Fieldbus Networks Workshop

DeviceNet: Overview
Background CAN based Sensor actor bus system, initially developed by Allen Bradley
Medium Access CSMA/CA
Control Method
Addressing Frame Addressing (CAN Identifier). Predefined Master-Slave Connection Set links
Node Adresses (MAC-ID) with CAN Identifiers
Transmission Media, ISO 11898: shielded twisted pair; 125, 250, 500 kBit/s
Baudrate
Topology Electrical: bus (line) with terminating resistors
Node Hierarchy Typical: 1 Master, up to 63 slaves. Several masters possible (rarely used)
Network expansion 100 m (500 kBaud), 250 m (250 kBaud), 500 m (125 kBaud). Use of repeaters
does not lead to longer networks, as propagation delay is the limit (not damping)
Frame Length 0...8 Bytes. Longer process images are sent using segmented transfer
Error Detection CRC, Frame Check, Bus Monitoring, Bit Stuffing, Acknowledge Check. Hamming
Distance: 6 (5 Bits out of 83 may change)
Priorities 2048
Typical Cycle times 5...15 ms
44
BECKHOFF Fieldbus Networks Workshop

DeviceNet (CAN): Dominant and Recessive Bits


V+
V+ -> 1
-> 0
bus-line

S1 S2 S3

device 1 device 2 device 3

State Table
S1 0 1 0 1 0 1 0 1 0 - level is dominant
S2 0 0 1 1 0 0 1 1 1 - level is recessive
S3 0 0 0 0 1 1 1 1
Bus Level 0 0 0 0 0 0 0 1

45
BECKHOFF Fieldbus Networks Workshop

DeviceNet: CAN Arbitration with CSMA/CA


S R
O Identifier T Control Data
1
F 10 9 8 7 6 5 4 3 2 1 0 R Field Field
node 1 listening only
0

1
node 2 listening only
0

1
node 3
0

1
bus-level
0

Node 3 wins arbitration and transmits his data.

46
BECKHOFF Fieldbus Networks Workshop

DeviceNet: Topology

node 1 . . . . . . . . node n

Basic CAN Topology: CAN_H


ISO 11898 120 Ω CAN Bus Line 120 Ω
CAN_L

PS
Trunk Line with
Terminating
Resistors + (short)
Drop Lines
„Zero Drop“
Drop Line

47
BECKHOFF Fieldbus Networks Workshop

DeviceNet: Dropline Daisy-Chaining & Branching


Trunk
Tap Tap

Dropline

Branching Limitations
20 ft max to node farthest from tap
sum of cable-feet goes against dropline
budget

plug-in device
connector

Use inside Control Panels


where multiple devices are
clustered together
48
BECKHOFF Fieldbus Networks Workshop

DeviceNet: Propagation Delay limits Network Length

CAN-Controller 1 CAN-Controller n
~ 40 ns

opto- opto- . . . . . . opto- opto-


coupler coupler ~ 50 ns coupler coupler

transceiver 1 ~ 100...150 ns transceiver n

~ 5,5 ns/m

49 CAN Arbitration requires Propagation delay < Bit Time


BECKHOFF Fieldbus Networks Workshop

DeviceNet: Drop Line + Multidrop Limitations


Trunk line Trunk line Multiport Tap

Drop line
Drop line

Trunk/Drop Topology Multiport Tap Topology


Bit Rate Trunk Single Σ Trunk Single
Length Drop Drop Length Drop
(without Drops) Length Lengths (without Drops) Length
500kbit/s 100m <5m <25m 66m <1,2m
250kbit/s 250m <10m <50m 120m <2,4m
125kbit/s 500m <20m <100m 310m <4,8m

50
BECKHOFF Fieldbus Networks Workshop

DeviceNet: CAN Error Detection and Recovery


1. Local or global error detected.
2. An Error Flag will be transmitted (globalisation of error).
3. In case of local error this Error Flag will proceed an
overlapping Error Flag followed by the Error Delimiter.
4. The message will be discarded by each node.
5. The Error Counters of every bus node are incremented.
6. The message transmission will be repeated
automatically.

51
BECKHOFF Fieldbus Networks Workshop

DeviceNet: Globalisation of Local Errors

transmitter data data 8 bit 3 repetition

receiver 1 6 bit

receiver 2 6 bit

bus-level

The receiver 2 detects an error and makes it public to the other nodes.

52
BECKHOFF Fieldbus Networks Workshop

DeviceNet: Why Local Errors?


Threshold
1. Different Sampling Disturbance
Points in different
Nodes Sampling Point A
Sampling Point B

Threshold A
2. Different Switching Threshold B

Thresholds in different Disturbance

Nodes
Sampling Point

3. Dispersion during
Propagation along the
Bus Line

53
BECKHOFF Fieldbus Networks Workshop

DeviceNet: Error Counters and Error States


REC: Receive Error Counter Reset and Configuration
TEC: Transmit Error Counter

Error Active
27 or
> 1 127

Reset, Configuration
TE EC >

and Reception of
7
TE an = 12

128x11 recessive
C

7
R

12
<
C d

Bits
C

<=
RE

Too many
Errors: Bus Off

Error Passive Bus Off

TEC > 255

54
BECKHOFF Fieldbus Networks Workshop

DeviceNet: Multimaster and Multicast

PLC1 PLC2 MMI


#1

#2
DRIVE DRIVE DRIVE
I/O 1 1 2 3

• Transaction #1 - position reference from I/O Rack #1 is broadcasted


to PLC1, PLC2, and the MMI at the same time
• Transaction #2 - speed command is sent to all three drives at the
same time
• But: 99% of all DeviceNet Networks are single Master / single Cast
(„Group 2 Only“- Networks, where Slaves communicate with Master only)
55
BECKHOFF Fieldbus Networks Workshop

DeviceNet: Polling
• The simplest and most understood; “polling”
• The PLC or scanner is the master and I/O devices are the slaves
• The slaves speak only when spoken to
• Only one master per network (“single master”)
• Most (>95%) of all DeviceNet installations work this way
• Deterministic behavior, easy to configure
• But: less efficient use of bandwidth than other options

PLC
3,6,..
1,4,...
I/O 1 2,5,.. I/O 2 I/O 3

56
BECKHOFF Fieldbus Networks Workshop

DeviceNet: Polling Procedure with AB Scanner

Poll Response Node 2

Poll Response Node 1

Poll Response Node 4

Poll Response Node 6

Poll Response Node 5


Poll Response Node 3

Poll Response Node 7

Poll Response Node 8


Poll Request Node 1
Poll Request Node 2
Poll Request Node 3
Poll Request Node 4

Poll Request Node 5

Poll Request Node 6

Poll Request Node 7


Poll Request Node 8

Poll Request Node 1


Poll Request Node 2
Poll Request Node 3
Poll Request Node 4
Scanner first sends all Poll Requests Interscan Delay

Interscan delay is the time the scanner module will wait between the
last poll message request and the start of the next scan cycle.
Background poll ratio sets the frequency of poll messages to a
device in relation to the number of I/O scans. For example, if the
ratio is set at 10, that device will be polled once every 10 scans.

57 It is not possible to set a specific cycle time.


BECKHOFF Fieldbus Networks Workshop

DeviceNet: Cyclic Data Production


• Devices report data on a user-configured time increment basis (input or output)
• Cyclic Data Production is more efficient for applications with slowly changing
I/O (analog)
• Network traffic is reduced
• Performance is repeatable
• Can be used in Master/Slave, Peer-to-Peer, or Multimaster environments
• More configuration effort than polling but better performance when the
minimum required update rate for individual I/O devices can be identified

PLC
every 500 ms
every 25 ms I/O 1 I/O 2 I/O 3
58 every 2000 ms
BECKHOFF Fieldbus Networks Workshop

DeviceNet: Change of State (COS)


• Rather than a master going through a polling list (scanning), devices report
data (input or output) on a change-of-state basis as the events happen
• Change of State is more efficient for discrete applications
• Network traffic is significantly reduced, performance is greatly improved
• Background heartbeat for device supervision (Network Management)
• Can be used in Master/Slave, Peer-to-Peer, or Multimaster environments
• Bandwidth analysis in system test phase required
• in DeviceNet Change of State is always combined with Cyclic

PLC
#2
#3 #1
I/O 1 I/O 2 I/O 3
59
BECKHOFF Fieldbus Networks Workshop

DeviceNet: Calculation of Cycle Times


TMC = (I x 8 + (NRQT x TTH) + O x 8 + (NRST x TTH)) x Slaves x 100%/BL

TMC = Message Cycle Time in Bit Times


I = Number of Input Data Bytes per Slave
NRQS = No. of Request Telegrams (I=1..8:NRQS=1; 9…14:2; 15…21:3; 22…28:4 etc.)
TTH = Telegram Header= 50 Tbit (including 3 Stuff Bits)
O = Number of Output Data Bytes per Slave
NRQS = No. of Response T. (O=1..8:NRQS=1; 9…14:2; 15…21:3; 22…28:4 etc.)
Slaves = Number of Slaves
BL = Busload; typical: up to 80% (for polling only)

Example: DeviceNet System consisting of 1 Master and 20 Slaves each


with 2 Byte Input and 2 Byte Output Data, 80% Busload
TMC = (2x8 + 50 + 2x8 + 50) x 20 x 100%/80% = 3300 TBit
3300TBit (500kBaud) = (TBit = 2 µs) = 6.6 ms
3300TBit (125kBaud) = (TBit = 8 µs) = 26.4 ms
60
BECKHOFF Fieldbus Networks Workshop

DeviceNet: Cycle Times I (Polling)


160
500 kBaud, 2+2 Bytes
140 500 kBaud, 6+6 Bytes
500kBaud, 20+20 Bytes
250 kBaud, 2+2 Bytes 80% Busload
120 250 kBaud, 6+6 Bytes
250 kBaud, 20+20 Bytes
Cycle Time [ms]

125 kBaud, 2+2 Bytes


100 125 kBaud, 6+6 Bytes
125 kBaud, 20+20 Bytes

80

60

40

20

0
5 10 15 20 25 30
No of Nodes
61
BECKHOFF Fieldbus Networks Workshop

DeviceNet: Cycle Times II (Polling, 500 kBaud)


40

35

500 kBaud, 2+2 Bytes


30 500 kBaud, 6+6 Bytes 80% Busload
500kBaud, 20+20 Bytes
Cycle Time [ms]

25

20

15

10

0
5 10 15 20 25 30
No of Nodes
62
BECKHOFF Fieldbus Networks Workshop

DeviceNet: Cycle Times III


45

40

35
500 kBaud, 10 Nodes, 80% Busload
Cycle Time [ms]

30

25

20

15

10

0
0 5 10 15 20 25 30 35 40 45 50

No of I/O Bytes per Slave


63
BECKHOFF Fieldbus Networks Workshop

Network Wiring Design


Network Wiring Design Affects…
• Maximum communication baudrate
• Network power distribution
Network Wiring Design Goals
• Control total trunk length
• Control cumulative drop length
(the total length of all drop lines)

64
BECKHOFF Fieldbus Networks Workshop

Network Wiring Design (continued)


Important Points:
• Network trunk lines may be constructed with thick, thin or
a combination of think and thin cable according to the
tables in the DeviceNet Specification – typically thin is
sufficient
• The trunk line must be terminated at each end
• Two terminators, no more and no less
• DeviceNet differs from many other networks in that it
requires network termination for proper operation,
regardless of cable length

65
BECKHOFF Fieldbus Networks Workshop

Network Wiring Design (continued)


… More Important Points:
• The trunkline-dropline topology guidelines must be
followed faithfully
• Bending the rules will usually cause more problems
than it solves
• Building trunks with thin cable has a significant impact on
network power design
• Thin cable has a higher DC resistance and will
adversely affect voltage drop in the power system

66
BECKHOFF Fieldbus Networks Workshop

Network Power
Network power is a new concept to most control
systems designers
• 24Vdc is supplied in the network cable
• Powers simple devices
• Powers the isolated network interface in larger devices
Power System Design Goals
• Deliver 11Vdc minimum at each device
• Limit common mode voltage to < 5v
• Voltage drop in DC common line

67
BECKHOFF Fieldbus Networks Workshop

Network Power (continued)


Power System Design Process
• Determine maximum current for each device
• Place one or more power supplies on the network to
ensure that:
• The voltage drop in the cable between a power supply
and each station it supplies does not exceed 5Vdc
• The current does not exceed the cable/connector limit
• The DeviceNet Specification provides an easy table-
lookup method for power system design

68
BECKHOFF Fieldbus Networks Workshop

Network Power (continued)


Important Points:
• Use the maximum inrush current specification for each
device for power calculations
• Minimum requirements must be guaranteed when
power is applied
• Use multiple power supplies with care
• You must guarantee that the power supply common
does not vary by more than 5V between any two points
in the network

69
BECKHOFF Fieldbus Networks Workshop

Grounding
Network Grounding Guidelines
• Connect the DC power supply common wire and the shield
to a low-impedance ground at the power supply
• If multiple power supplies are present, ground at only
the power supply closest to the middle of the network
• Location of ground affects common mode voltage
• All splices and taps in the network must connect the shield
as well as the signal and power lines

70
BECKHOFF Fieldbus Networks Workshop

DeviceNet: Shielding/Grounding
Optional R-C Circuit for HF grounding

Master

Slave Slave

ground rail ground rail ground rail


R-C

Shield grounded data cable

only at one location

71
BECKHOFF Fieldbus Networks Workshop

Testing
General Test Parameters
• Do not perform these tests while the system is operating
(no communication)!
• All devices installed
• All power supplies turned on
• Perform these tests in sequence
• Some tests assume that previous tests were successful

72
BECKHOFF Fieldbus Networks Workshop

Testing (continued)
Network Termination & Signal Wires
• Check the resistance from CANH to CANL at each device
• If the value is > 60 ohms, there 120 Ω
could be a break in one of
the signal wires or
missing network terminator(s)
• If the value is < 50 ohms look for:
- a short between the network wires,
- extra terminating resistor(s), Ω
- faulty node transceiver(s)
Depending on the
type of Ohmmeter it
may be necessary to
disconnect the nodes
for this test! 120 Ω
73
BECKHOFF Fieldbus Networks Workshop

Testing (continued)
Shield
• Connect a DC ammeter (16 amps max) from DC common
to the shield at the opposite end of the network from the
power supply
• There should be significant current flow
• If there is no current, the shield is broken or the network
is improperly grounded
• If the power supply is in the middle of the network, do
this test at each end
• This test can also be performed at the end of each drop
if practical

74
BECKHOFF Fieldbus Networks Workshop

Testing (continued)
Grounding
• Break the shield at a few points in the network and insert a
DC ammeter
• If there is current flow, the shield is connected to DC
common or ground in more than one place (ground
loop)

75
BECKHOFF Fieldbus Networks Workshop

Testing (continued)
Network Power - Minimum supply voltage
• Measure the supply voltage at each device
• It should be > 11Vdc
• If not, check for faulty or loose connectors and verify
power system design calculations by measuring current
flow in each section of cable with an ampmeter

76
BECKHOFF Fieldbus Networks Workshop

Testing (continued)
Network Power - Common Mode Voltage
• Shield must be continuous and have no current flow in it
(tested previously)
• Measure and record the voltage between the shield and
DC common at each device
• The maximum difference should be < 5V between any
two devices

77
BECKHOFF Fieldbus Networks Workshop

Testing (continued)
MAC ID/ Baud Rate Settings
• The Network Status LED is an excellent diagnostic tool for
this purpose
• The LED should be flashing green on all devices
• Solid RED indicates a communication fault (possibly
incorrect baud rate) or a duplicate MAC ID (station
address)
• Use a network configuration tool to perform a "network
who" to verify that all stations are connected and capable
of communicating

78
BECKHOFF Fieldbus Networks Workshop

Diagnosing Faults
Common network problems
• Faulty devices
• Opens & shorts in the network wiring
• Faulty connectors or cable
• Electrical interference
• Incorrect grounding or broken shield
• Signal distortion & attenuation
• Incorrect termination
• Failure to adhere to topology guidelines
• Faulty connectors or loose terminal blocks

79
BECKHOFF Fieldbus Networks Workshop

Diagnosing Faults
Problems specific to DeviceNet
• Missing terminators
• Excessive common mode voltage
• Excess current or cable length
• Faulty connectors
• Low power supply voltage
• Excess current or cable length
• Faulty connectors
• Excessive signal propagation delay
• Excess cable length

80
BECKHOFF Fieldbus Networks Workshop

Diagnosing Faults (continued)


Low-tech Approach:
• Disconnect parts of the network and watch where the fault
goes
• Does not work well for problems such as excessive
common mode voltage, ground loops, electrical
interference and signal distortion because
disconnecting part of the network frequently solves the
problem
• If the network was previously operating, ask the
question "what has changed?”

81
BECKHOFF Fieldbus Networks Workshop

Diagnosing Faults (continued)


Using an Oscilloscope:
• Can be misleading since many perfectly good differential
signals look perfectly awful when viewed individually
• Most network problems your are tempted to diagnose with
an oscilloscope are intermittent
• Unless you are able to trigger your scope on the bad
signal you will probably spend your time looking at good
signals

82
BECKHOFF Fieldbus Networks Workshop

Diagnosing Faults (continued)


Your Brain is Your Best Diagnostic Tool:
• Be a detective, record symptoms in detail
• Your notes are invaluable if you enlist the help of others
• Look for patterns in the symptoms
• Do intermittent problems occur when other un-related
equipment is in use?
• Do some nodes communicate correctly? What is the
difference between the functioning nodes and the
others? (proximity to the power supply, to the
terminator, to the scanner)

83
BECKHOFF Fieldbus Networks Workshop

DeviceNet Troubleshooting: Conclusion


The vast majority of DeviceNet network problems
are user created by:
• Failing to follow cable system design rules
• Missing terminators
• Excessive trunk/drop length
• Improper topology
• Failing to follow power system design rules
• Excessive common mode voltage

84
BECKHOFF Fieldbus Networks Workshop

SERCOS: Overview
Background Fibre Optic Network, originally developed for Drive Control
Medium Access Time Slicing Method
Control Method
Addressing Node Addressing
Transmission Media, 1000 µm Plastic Optical Fibre (PMMA:Polymethylmethacrylate);
Baudrate 2 or 4 Mbaud, coming soon: 8 and 16 MBaud
Topology Ring
Node Hierarchy 1 Master, up to 253 slaves
Network expansion Max. 40 m between two nodes
Frame Length Cyclic Drive Telegram: typical 4 Bytes, maximal 32 Bytes
Error Detection CRC. Hamming Distance: 4
Priorities 1
Typical Cycle times 0,5...2 ms, cycle times of 0,0628 ms possible

85
BECKHOFF Fieldbus Networks Workshop

SERCOS: Medium Access Control via Time Slicing


• Master calculates a time window for each slave
• In the initialization phase this timing parameter is
configured on the slave
• Each Slave has an adjustable address
(independent of its position within the ring)
• The Master cyclically sends a synchronization telegram “MST”
• Communication is collision free due to the fixed time
slices and synchronized communication

86
BECKHOFF Fieldbus Networks Workshop

SERCOS: Communication Principle

87
BECKHOFF Fieldbus Networks Workshop

SERCOS: Telegram Structure

88
BECKHOFF Fieldbus Networks Workshop

SERCOS: Startup Phases


The optical Ring is checked
Phase 0 Reset Phase
10 times MST
OK

Phase 1 Ring identification Master identifies all Slaves


All Slaves respond with
Drive Telegram
OK
Initialisation of the Slaves
Phase 2 Initialisation Phase Timing parameters are read
(+Parameterisation) Calculate Time Slice parameters
OK Download parameters
All Values ok
Phase 3 Parametrisation Phase Timing is activated, further
Parametrisation
OK Slaves check parameters
Phase 4 Operational
Everything operational
89
BECKHOFF Fieldbus Networks Workshop

SERCOS: Calculation of Cycle Time


TMC = TMST+TMDTH+2TJit+(TATH+TJit+(7+I+0)x9,6 +TMDTS ) x Slaves
TMC = Message Cycle Time in Bit Times
TMST = Master Sync Telegram Time = 56,4 TBit
TMDTH = Master Data Telegram Header = 44,8 TBit
TJit = Jitter Time btw. two messages = 16TBit@16MBaud;8@8; typ.20@4; 40@2
TATH = Slave Telegram Header = 16TBit
TMDTS = Master Data Telegram Slave Header = 38,4 TBit
I = Number of Input Data Bytes per Slave
O = Number of Output Data Bytes per Slave
Slaves = Number of Slaves
Example: SERCOS System consisting of 1 Master and 20 Slaves each
with 2 Byte Input and 2 Byte Output Data, 4MBaud
TMC = 56,4 + 44,8 + 40 + (16 + 20 + (7+2+2)x9,6 + 38,4) x 20 = 3741 TBit
3741TBit (4 MBaud) = (TBit = 0.25 µs) = 0.94 ms
3653 TBit (16 MBaud) = (TBit = 62.5 ns) = 0.23 ms
In practice, time for data access from PLC/NC to the master should be added (typ. 0.3ms)

90
BECKHOFF Fieldbus Networks Workshop

SERCOS: Cycle Times


8
16MBaud, 2+2Bytes
16MBaud, 6+6 Bytes
7
16MBaud, 20+20 Bytes
4MBaud, 2+2Bytes

6 4MBaud, 6+6 Bytes


4MBaud, 20+20Bytes
2MBaud, 2+2Bytes including 0.3 ms Master Access Time
Cycle Time [ms]

5 2MBaud, 6+6 Bytes


2MBaud, 20+20Bytes

0
5 10 15 No of Slaves 20 25 30

91
BECKHOFF Fieldbus Networks Workshop

SERCOS: Cycle Times


Nodes per
Datarate 16 MBit/s
SERCOS interface
Position/Velocity
Fibre Optic - Ring
Control Telegram

120

80

40

Datenrate 4 MBit/s
20
Position/Velocity
Control Telegram
10

5
2

0,0628 0,125 0,25 0,5 1 2 3


92 SERCOS interface Cycle time in ms
BECKHOFF Fieldbus Networks Workshop

SERCOS: FC750x Mastercard Facts


Baudrate 2 / 4 / 8 / 16 MBit/s

Max. No of Slaves 254 Nodes

Software support TwinCAT I/O … NCI, not without TwinCAT!

Synchronization TwinCAT Real Time

Minimal Cycle time 62,5 µs

All settings via TwinCAT

FC750x does not need an interrupt!

93
BECKHOFF Fieldbus Networks Workshop

SERCOS: BK7500 Bus Coupler Facts


Baudrate 2 / 4 / 8 / 16 Mbit/s

Max. No of Devices 254 Nodes

Max. number of bytes 32 bytes input / 32 bytes output for the cyclic
interface (depending on the master)

Minimal Cycle time 62,5 µs; if cycle time shorter


than K-Bus update, old
data is repeated

Settings Node Address


Distance to next node (Tx Intensity)
Baud Rate
94
BECKHOFF Fieldbus Networks Workshop CANopen

CANopen: Overview
Background CAN Protocol defined by CAN in Automation. Used in General Automation
Applications (I/Os, Drives, etc) and in Embedded Applications
Medium Access CSMA/CA.
Control Method
Addressing Frame Addressing (CAN Identifier). Predefined Master-Slave Connection Set links
Node Adresses (MAC-ID) with CAN Identifiers
Transmission Media, ISO 11898: shielded twisted pair; 10, 20, 50, 100, 125, 250, 500, 800, 1000 kBit/s
Baudrate
Topology Electrical: bus (line) with terminating resistors
Node Hierarchy Typical: 1 Master, up to 63 slaves. Several masters possible (rarely used)
Network expansion 100 m (500 kBaud), 250 m (250 kBaud), 500 m (125 kBaud). Use of repeaters
does not lead to longer networks, as propagation delay is the limit (not damping)
Frame Length 0...8 Bytes. Longer process images are sent using different telegrams (PDOs)
Error Detection CRC, Frame Check, Bus Monitoring, Bit Stuffing, Acknowledge Check. Hamming
Distance: 6 (5 Bits out of 83 may change)
Priorities 2048
Typical Cycle times
95 5...15 ms
BECKHOFF Fieldbus Networks Workshop CANopen

CANopen: Device Model


• All Parameters and Application Objects are organized in an object dictionary
• Access to these objects via service data objects (SDO) and process data objects (PDO)

Protocol Stack Object Dictionary Application


Software
CAN PDO Protocol Data Types I/O
SDO Protocol Communication Objects Device Profile
Sync Protocol Application Objects Implementation
Time Protocol Proprietary Objects
Emergency Protocol Proprietary
NMT Protocol Software
Heartbeat Protocol Routines
etc.

96
BECKHOFF Fieldbus Networks Workshop CANopen

CANopen: Process Data Object (PDO)


• PDOs contain real time I/O data. Contents is described in PDO Mapping Object
• Each PDO has one producer and one to many consumers
• PDO equivalent in DeviceNet: I/O messages (or implicit messaging)

Producer/Consumer: PDO
makes use of CAN
PDO_1 consumer PDO_1 consumer
broadcast mechanism
PDO_1
ID Data

PDO_1 producer Other node

97
BECKHOFF Fieldbus Networks Workshop CANopen

CANopen: PDO Scheduling


PDO Trans-
mission Type
Internal
1. Event- or Timer- event consumer(s)
driven producer

Remote Frame
2. Remotely consumer(s)
requested producer

Sync
3. Synchronous consumer(s)
producer
transmission
(cyclic, acyclic)
98
BECKHOFF Fieldbus Networks Workshop CANopen

CANopen: PDO Synchronisation


• SYNC telegram acts as trigger for input reading and output validation

Communication_Cycle_Period
synchronous
Sync Sync window
length(s)
Actual Command Actual Command
Messages Messages Messages Messages

Samples taken time


at SYNC for
actual message

99 Actuation based on COMMAND at next SYNC


BECKHOFF Fieldbus Networks Workshop CANopen

CANopen: PDO Mapping


Object Dictionary The PDO Mapping Entry in the
Object Dictionary allows one to
Mapping Object

Index Sub Object contents


determine which Application
1ZZZh 01h 6TTTh TTh 8
Data is mapped in the PDOs
1ZZZh 02h 6UUUh UUh 8
1ZZZh 03h 6WWWWh WWh 16

PDO-Length: 32 Bit
PDO_1 Object A Object B Object D

6TTTh TTh Object A


6UUUh UUh Object B
Application Object

6VVVh VVh Object C


6WWWh WWh Object D
6XXXh XXh Object E
Beckhoff CANopen Bus
6YYYh YYh Object F
Couplers generate a Default
6ZZZh ZZh Object G Mapping autononomously
100
BECKHOFF Fieldbus Networks Workshop CANopen

CANopen: Variable PDO Mapping


Object Dictionary Variable PDO Mapping allows
one to select which Application
Mapping Object

Index Sub Object contents


Data is mapped in the PDOs
1ZZZh 01h 6TTTh TTh 8
1ZZZh 02h 6ZZZh ZZh 16
1ZZZh 03h 6XXXh XXh 8

PDO_1 Object A Object G Object E

6TTTh TTh Object A


6UUUh UUh Object B
Application Object

6VVVh VVh Object C


6WWWh WWh Object D
6XXXh XXh Object E
6YYYh YYh Object F
6ZZZh ZZh Object G

101
BECKHOFF Fieldbus Networks Workshop CANopen

CANopen: Service Data Objects (SDO)


• SDOs are used to read or write data to the servers object dictionary
• Typically used acyclically, but may be used for (slow changing) process data as well
Peer-to-Peer Communication

SDO Client Node n-1 OD

ID 1 Data
ID 2 Data

Node n OD SDO Server OD

102
BECKHOFF Fieldbus Networks Workshop CANopen

CANopen: Object Dictionary Access via SDO


• The SDO contains the address information for the object dictionary: index and subindex
• SDO equivalent in DeviceNet: Explicit Messaging

Byte 0 Byte 1-3: Multiplexor Byte 4-7: Data

Command 16-bit-Index 8-bit 1-4 byte parameter


Specifier Subindex data

Index Subindex Description Value

Object Dictionary
103
BECKHOFF Fieldbus Networks Workshop CANopen

CANopen: Predefined PDO Identifiers


• Nodes derive Identifier set from their node ID
• with these identifiers Master/Slave connections are established
Master Slave X
RPDO_1_M TPDO_1_X
RPDO_2_M TPDO_2_X

TPDO_1_M RPDO_1_X
TPDO_2_M RPDO_2_X
Slave Y
RPDO_3_M TPDO_1_Y
RPDO_4_M TPDO_2_Y

TPDO_3_M RPDO_1_Y
104
TPDO_4_M RPDO_2_Y
BECKHOFF Fieldbus Networks Workshop CANopen

CANopen: PDO Linking


• If devices shall communicate directly (without a relaying master), Identifiers have to be
adapted (configured)
• This is as well the case if several nodes shall listen to the same PDO
Device X

RPDO_2_X
RPDO_1_X

TPDO_1_X
TPDO_2_X
Device Z Device Y
RPDO_1_Z TPDO_1_Y
RPDO_2_Z TPDO_2_Y
RPDO_3_Z RPDP_1_Y
TPDO_1_Z RPDO_2_Y
105
TPDO_2_Z RPDO_3_Y
BECKHOFF Fieldbus Networks Workshop CANopen

CANopen: Feature List


‹ Up to 512 Transmit-PDOs and up to 512 Receive-PDOs

‹ Asynchronous and synchronous PDO transmission

‹ One Default-Server-SDO, up to 127 Server-SDOs

‹ Up to 128 Client-SDOs

‹ Boot-up Message and Heartbeat Message

‹ Emergency and SDO Abort Message

‹ Time-stamp message

‹ NMT Slave state machine


106 Medium Access (CAN Arbitration) + Topology: see DeviceNet !
BECKHOFF Fieldbus Networks Workshop Lightbus

Lightbus: Overview
Background Developed by Beckhoff in 1989. Still one of the fastest systems around
Medium Access Master/Slave (Polling)
Control Method
Addressing Node Addressing
Transmission Media, Plastic Fibre Optics (PMMA); 2,5 MBit/s
Baudrate
Topology Ring
Node Hierarchy 1 Master, up to 254 slaves
Network expansion POF: 40m between two slaves; 300m with HCS Fibres
Frame Length 4 Bytes Process Data
Error Detection CRC
Priorities CDL concept allows one to distinguish 8 priorities
Typical Cycle times 1..2 ms (there are applications with 67 µs)

107
BECKHOFF Fieldbus Networks Workshop Lightbus

Lightbus: System Overview


TwinCAT FC2001/02 C1220 C1300 C1120
Software- PCI inter- ISA inter- VME inter- S5 inter-
PLC/NC face card face card face card face card

BK2000
M1400
Lightbus Coupler,
Lightbus module, 32 x digital I/O
Bus Terminals

M2400
BC2000 Lightbus module, 16 x digital I/O,
Lightbus Controller with max. 4 x analog outputs
integrated IEC 61131-3

M3000
Absolut Encoder with Lightbus interface,
24 Bit, 4096 steps/revolution

AX20xx-B200 M3120
Compact digital Lightbus module, 4 channel
servo drive with Incremental Encoder interface
Lightbus interface
M63xx
Operating panels with
108 Lightbus interface
BECKHOFF Fieldbus Networks Workshop Lightbus

Lightbus: Topology
‹ fiber optic ring with 45m (150 ft)
distance between nodes

‹ online fiber optic media


diagnostics
‹ error location indication
‹ syncronization commands
‹ NO address switch setting
‹ logical addressing possible
‹ various vendors for encoders,
drives, IO devices

109
BECKHOFF Fieldbus Networks Workshop Lightbus

Lightbus:Frame Format
‹ deterministic communication in 25µs “frames”

‹ fastest update time 25 µs for 4 interrupt channels

‹ 7 different communication cycle times for modules down to 50µs

‹ modules freely configurable in CDL’s (communication description


lists) for communication timing

110

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy