beautypg.com

Table 6-2. apb setup bytes for pcs modbus master – Micromod Micro-DCI: 53MC5000 PLC AND PRINTER INTERFACES User Manual

Page 72

background image

The Diagnostic command is implemented at the PCS with the Modbus Write Control Bytes (see Ta-
ble 6-5). The control bytes in the table that are necessary to initiate a Diagnostic command are the
PLC Address, Diagnostic Code Low, Diagnostic Code High, Diagnostic Reply Data Low, Diagnostic
Reply Data High, and Function Code. Diagnostic information is returned in control bytes Diagnos-
tic Reply Data Low and Diagnostic Reply Data High. The PLC Address control byte contains the ad-
dress of the Modbus PLC being queried by the Diagnostic command; the Diagnostic Code Low and
Diagnostic Code High control bytes specify the sub-function to be performed by the PLC; and the
Function Code control byte must be set to 8 to indicate Diagnostic command.

When the Diagnostic Loopback test is initiated from the PCS, the Function control byte has an 8
for Diagnostic command, the Diagnostic Code Low and Diagnostic Code High control bytes are 00
00 for Return Query Data and the PLC Address control byte contains the address of the PLC under
test. Unless there is a Modbus communications malfunction, the PCS perpetually sends to the
PLC, and receives from it, two bytes that contain a decimal 170

10

( hexadecimal AA

16

). The 1 ap-

pears in the Diagnostic Reply Data High control byte and the 70 appears in the Diagnostic Reply
Data Low control byte.

6.4.14 PCS MODBUS MASTER CONTROL BYTES

The APB Setup Bytes, Control and Status Bytes, Read Control Bytes, and Write Control Bytes for
PCS Modbus master operation are presented in Tables 6-2 through 6-5. If any Control Byte is
changed during operation, it takes up to 10 seconds to become effective (there is a 10 sec-
ond interval between PCS checks for setup changes.)

Table 6-2. APB Setup Bytes for PCS Modbus Master

Title

Definition

Set

By

DDI-A

DDI-B

De-

fault

Mode

It designates the APB communications functionality as
follows:

0 = Off, 3 = Modbus RTU Mode

This datapoint should be left at 0 and configured to
a 3 after all of the other control bytes are
configured because setting this datapoint causes
the Modbus PLC Interface functionality to start.

User

B290

B456

0

Baud
Rate

It designates the data transfer rate as follows:
10 = 38400, 9 = 28800, 8 = 14400, 7 = 19200,
6 = 9600, 5 = 4800, 4 = 2400, 3 = 1200,
2 = 600, 1 = 300, 0 = 110

User

B292

B458

0

Set-Up

It designates the data format transfer protocol as
follows:

0 = 8 bits, 1 stop bit, no parity
1 = 8 bits, 1 stop bit, even parity
2 = 8 bits, 1 stop bit, odd parity

User

B293

B459

0

53MC9015 53MC5000 PLC and Printer Interfaces

6-8

MODBUS2