Diagnostic Telegrams for the Compact Box (IPxxx-B3xx)

DiagData in DPV1 Format

The diagnostic data is automatically reported to the DP master by the Fieldbus Boxes (if it has changed). The meaning of the first 6 bytes is the same for all DP slaves, after which device-specific diagnostic data follows. The structure for a Compact Box is specified according to the setting of “Old format / DPV1 format”.

Usually the DP master has the ability to interrogate a flag in the PLC to determine whether diagnostic data has changed. The diagnostic data itself can then in most cases be read by means of a function block. In the S5 the diagnostic data is read with the FB IM308C function block, and in the S7 with the SFC13 and in TwinCAT it is read with the ADSREAD function block. The maximum length of the diagnostic data can be altered through User_Prm_Data (byte 11). If there is more diagnostic data available than can be sent, this is itself indicated in the diagnostic data.

Diagnostic

Byte

Bit

Description

0

0

Slave does not answer (is set internally by the DP master)

1

Slave is starting up (parameterization and configuration are being evaluated)

2

Configuration error

3

Ext_Diag_Data available (from byte 6)

4

Function not supported

5

Incorrect answer from slave (is set internally by the DP master)

6

Parameterization error

7

Slave is exchanging data with another master (is set internally by the DP master)

1

0

Slave must be parameterized again

1

Slave has static diagnostics

2

1

3

DP watchdog is active

4

Slave is in freeze mode

5

Slave is in sync mode

6

reserved

7

Slave is deactivated (is set internally by the DP master)

2

0-6

reserved

7

too much Ext_Diag_Data

3

 

Station address of the master with which data is being exchanged

4, 5

 

Ident number

Manufacturer-specific diagnostics for the Compact Box

Byte

Bit

Description

6

 

Length of the Ext_Diag_Data, including length byte

7

 

0x81 (identification of the DPV1 diagnostic format)

8

 

0x00

9

 

0x00

10

 

0x00

11

 

0x00

12

 

0x00

13

 

0x00

14

 

0x00

15

 

0x00

Diagnostics for the Compact Box

Byte

Bit

Description

16

0-5
6-7

In Fieldbus Boxes, bits 0-5 are always zero
faulty channel number (0-3)
0x00 channel 0
0x40 channel 1
0x80 channel 2
0xC0 channel 3

17

0-5
6

Status byte of the channel (bits 0-5)
General error bit

18

0-5
6-7

 

19

0-5
6

 

...

 

 

60

0-5
6-7

 

61

0-5
6

 

Note

Under complex mapping, the status byte is transferred from the terminal to the controller. It contains a variety of status bits depending on the terminal type involved (such as process data less than/greater than limit value x, over range, under range etc.)