PROFIBUS
Eng Mohamed sameh
Example
IF we have a factory that bottles orange juice So we will have a
bottling line at the start of that line We will have a batching
process where all of the ingredients are mixed the juice is then
piped 500 feet
away to the filling machine where the orange juice is filled into
glass bottles.
Further down the line will be other machines obviously but I just
want to concentrate on the batching
and the filling in this practical example Now the botching and filling
is to be controlled by one peel see that has to be situated at the
filling
The filling machine has 30 i/o and batching machine have 50 i/o
And the PLC is away from the filling and batching machine to
connect PLC with the machines we have along cables that cases
error in communication because the scan cycle is 5-
100milliseconds and have ahigh cost
Eng Mohamed sameh
Solution
We can make the I/O module close to one of the machines like filling
machine and make the main PLC close to batching machine and connect
filling machine with I/O module and connect Batching machine with main
PLC and I/O module that connecting to PLC and connect PLC with the I/O
module near to filling machine with single pair wire (RS485) the solution
have many benefits it is low coast compared to the first way
• The cost is low
• Very fast
• Without compiling errors
Eng Mohamed sameh
Profibus
Profibus has only one master (Bus master ) and 128 slaves every slave has unique address like modbus always we
will use 2 wires with single pair one of this wires for bus and the second one for slave.
• The addresses comes from hardware by devices like ET200S from SIMENS .
• Address 127 is for broadcast and no Profibus DP slave has this address.
• Address 126 we can set it from hardware or software.
• Address 0 for the programming device .
-broadcast:
Is used for send message for all slaves
Eng Mohamed sameh
How Profibus work
PROFIBUS works like Modbus, where the master sends messages to all slaves, but only the slave with the
matching address in the master's message can respond.
Communication parameters
The communication parameters must be identical for the system ,PROFIBUS use these setting as a standard
And can not change
Number of data bits = 8 bits
Parity= even
Number of stop bits = 1 bit Eng Mohamed sameh
Baud rate
• Different Devices and Baud Rates
Not all PROFIBUS devices are created equal; some might support a
maximum speed of 500 kilobits per second, others up to 1.5 megabits per
second, and others up to 12 megabits per second
• Setting the Baud Rate on a Network
When setting the baud rate on a PROFIBUS DP network, the entire
network must use the maximum baud rate of the slowest device. For
example, if one device can only communicate up to 500 kilobits per second,
then the whole network must be set to this speed, even if other devices can
go faster
• Configuring the Network
When configuring the network, the maximum supported baud rate is
determined, and the master device is configured to this speed. The
PROFIBUS DP slave devices will automatically detect the baud rate used by
the master and adjust themselves accordingly. This feature simplifies the
setup process as there is no need to configure the baud rate on each slave Eng Mohamed sameh
device individually
Repeaters
• We use repeaters if the number of devices more than 32 because the number of devices
can RS485 can loaded
• Segment :
It is between 2 repeaters So here's the rule a network segment can have a maximum of 30
devices on it.
• Repeaters do not have addresses
• we can go 126 on 127 those are special case of the addresses
Eng Mohamed sameh
The relation between distance and baud rate
cabling
The cable consist of physical layer(RS485) and connectors
Connectors
• RJ(11,12,45)
• DB(9,15)
• PS2
Eng Mohamed sameh
Cable specs
Internal view for the connector
We have incoming cable and outgoing cable to connect with
network
the termination resistor:
switch is typically integrated into the connectors. This switch
allows you to easily activate or deactivate the termination
resistor, which is crucial for preventing signal reflections and
ensuring proper communication within the network.
Here's a brief overview of how it works
•ON Position: When the switch is in the "ON" position, the
termination resistor is active, which helps to minimize signal
reflections at the end of the bus segment.
•OFF Position: When the switch is in the "OFF" position, the
termination resistor is inactive, which is useful during
troubleshooting or when the segment is not in use Eng Mohamed sameh
when the
switch is on and
when it is off
• The switch is on
• When the connector in master or in
the last device
• In master because it is the first device
and it is sending messages
• At the end of network because we
don’t need to send messages to
another device and want to close the
circuit
• The last device must connect to power
to connect with the network correctly
GSD Files
Is an electronic datasheet for device or device database file , all Profibus devices have own GSD files
• GSD files contains devices specific data
1. Vender identification information
2. Baud rates
3. Messages length.
4. Timing information
Eng Mohamed sameh
GSD-Mapping
We have a GSD files and will upload this files in PROFIBUS
planning software and PROFIBUS planning software dawnload
the configration in master parameters record that can Profibus
master device can use it
• Practical example
Let's say you have 3 different sensors from 3 different
manufacturers. Each sensor has its own GSD file. The software
loads these files and assigns addresses for each sensor based on
its file. Then, it creates a network map containing all the
addresses and data the master needs to communicate with these
sensors
This link for dawnload GSD files
Eng Mohamed sameh
1-
2-
Eng Mohamed sameh
Mapping in Profibus
I have a slave 1 and it is consist of i/o modules
DI card 10.0 10.1 10.2
DO card q0.0 q0.1 q0.2
The master know if we want to send the data to i0.0 in
slave 1 that is the mapping
And have slave 2 with DO modules
if we want to send the data to q0.0 in slave 2
By knowing some information we can send the data
correctly
Eng Mohamed sameh
Connecting PLC with ET200S
1-Make one of plcs master,and the second is slave
2-specify the addresses the out from master is
input to slave and the out from slave is input to
master2-
Eng Mohamed sameh
3-
4-
Eng Mohamed sameh