https//www.racom.eu/eng/support/protocols_docum/bc165a_df1.html
1. Introduction
The DF1 protocol for MORSE is designed for communication with Allen-Bradley
PLCs. It supports the Full-Duplex protocol version.
According to the single byte address contained within the Allen-Bradley
PLC, it transmits MORSE packets to the respective address in the network.
It makes use of BCC or CRC.
2. Data Format
The format of the frame arriving from the PLC is as follows:
|DLE/8|STX/8|DST/8|SRC/8|CMD/8|STS/8|TNS/16|data/length|DLE/8|ETX/8|BCC/8|
This frame is transmitted through the MORSE network in the following
format:
|CMD/8|STS/8|TNS/16|data/length|
Item content (hexadecimal):
DLE/8 - 10 flag
STX/8 - 02 start text
DST/8 - 01 destination address
SRC/8 - 02 source address
|CMD/8|STS/8|TNS/16|data/length| - sequence built up in PLC
ETX/8 - 03 end text
BCC/8 or CRC/16 - Check sum
The MORSE destination address is made up of the DST item, and the MORSE
source address from the SRC item, and vice versa.
One of the following can be selected for the check sum:
BCC/8 - block check character (simpler)
CRC/16 - cyclic redundancy check (perfect checking)
3. Implementation in Morse
Below is an example of communication using the DF1 protocol between two
Allen-Bradley PLCs with addresses 00 and 03, which are connected to the
MORSE CU with addresses xxxxxx00 and xxxxxx03.
13:33:33.058 rx;i 60 | S00
1002 0300 0B00 7E00 0000 5402 2006 2401 07E9 0000 0380 827F 0080 E943 0100
8D91 1300 0000 0000 E070 7200 F643 E070 7200 F643 A302 2002 2401 1003 15C6
13:33:33.065 tx 2 | S00
1006
13:33:33.252 tx 44 | S00
1002 0003 4B00 7E00 0000 D400 0000 3D7F 0080 827F 0080 E943 0100 8D91 1300
E070 7200 E070 7200 0000 1003 0FC9
13:33:33.267 rx;i 2 | S00
1006
13:33:33.299 rx;i 39 | S00
1002 0300 0A00 7F00 0000 3D7F 7F00 4C08 910B 546F 5472 616E 7370 6F72 7400
2800 1010 0010 03B6 99
13:33:33.304 tx 2 | S00
1006
13:33:33.482 tx 56 | S00
1002 0003 4A00 7F00 0000 827F 7F00 CC00 0000 C300 0A1A 0200 0300 0400 0500
0600 0700 0800 0000 0000 0000 0000 0000 0000 0000 0000 1003 854D
13:33:33.500 rx;i 2 | S00
1006
13:33:33.540 rx;i 39 | S00
1002 0300 0B00 8F00 0000 4E02 2006 2401 07E9 E943 0100 8D91 1300 0200 2002
2401 1010 0010 03A3 C4
13:33:33.545 tx 2 | S00
1006
13:33:33.720 tx 28 | S00
1002 0003 4B00 8F00 0000 CE00 0000 E943 0100 8D91 1300 0000 1003 B56A
13:33:33.731 rx;i 2 | S00
1006
In the following example of unsuccessful communication the sequence
provided from the PLC is replaced by characters AAAA.
>>
06:22:58.798 tx 9 | S00
1002 0E0D AAAA 1003 91
06:22:58.813 rx;i 2 | S00
1015
06:22:58.814 tx 9 | S00
1002 0E0D AAAA 1003 91
06:22:58.829 rx;i 2 | S00
1015
Communication unit CU (radio modem) sent data
1002 0E0D AAAA 1003 91
to the PLC and received a reply
1015 = NAK (= I don“t understand)
That is why data transmission is repeated, and in this example, with the
same result.
In the second example the RS232 link is disconnected:
>>
06:23:21.694 tx 9 | S00
1002 0E0D AAAA 1003 91
06:23:22.694 tx 2 | S00
1005
Here the CU receives no reply, which is why it transmits a query at the end
of the 1000ms timeout period
1005 = ENQ (repeat reply)
The logical relationship of the communication is described in the Allen-
Bradley PLC documentation. We only show a simplified listing here for
getting your bearings:
Transmitter (PLC or protocol DF1 for MORSE) after transmitting data it get
a reply:
ACK 1006 -> communication terminated
NAK 1015 -> repeats data
nothing, timeout -> sends ENQ 1005
receiver obtains a message:
data OK -> replies ACK 1006
data incomprehensible -> replies NAK 1015
ENQ 1005 -> repeats the last ACK or NAK message
4. Configuration Parameters
ALLEN-BRADLEY DF1 parameters:
(t):1000ms (r):1 (b)cv:0
(q)uit
>>
(t) - timeout of link layer
(r) - number of repeats on link layer
(b) - selection of check sum (0-BCC, 1-CRC)