beautypg.com

Slave status blocks – ProSoft Technology MVI71-MCM User Manual

Page 67

background image

Reference MVI71-MCM

♦ PLC Platform

Modbus Communication Module

ProSoft Technology, Inc.

Page 67 of 111

December 28, 2007

5.2.8 Slave Status Blocks

Slave status blocks send status information of each slave device on a master
port. Slaves attached to the master port can have one of the following states:

State Description

0

The slave is inactive and not defined in the command list for the master port.

1

The slave is actively being polled or controlled by the master port and
communications is successful.

2

The master port has failed to communicate with the slave device. Communications
with the slave is suspended for a user defined period based on the scanning of the
command list.

3

Communications with the slave has been disabled by the ladder logic. No
communication will occur with the slave until this state is cleared by the ladder
logic.

Slaves are defined to the system when the module initializes the master
command list. Each slave defined will be set to a state of one in this initial step. If
the master port fails to communicate with a slave device (retry count expired on a
command), the master will set the state of the slave to a value of 2 in the status
table. This suspends communication with the slave device for a user specified
scan count. Each time a command in the list is scanned that has the address of a
suspended slave, the delay counter value will be decremented. When the value
reaches zero, the slave state will be set to one. This will enable polling of the
slave.

Block ID

Description

3002

Request for slave status values for Port 1 slaves 0 to 59

3003

Request for slave status values for Port 1 slaves 60 to 119

3004

Request for slave status values for Port 1 slaves 120 to 179

3005

Request for slave status values for Port 1 slaves 180 to 239

3006

Request for slave status values for Port 1 slaves 240 to 255

3102

Request for slave status values for Port 2 slaves 0 to 59

3103

Request for slave status values for Port 2 slaves 60 to 119

3104

Request for slave status values for Port 2 slaves 120 to 179

3105

Request for slave status values for Port 2 slaves 180 to 239

3106

Request for slave status values for Port 2 slaves 240 to 255

The format of these blocks is as shown in the following table:

Offset Description

Length

0

3002 to 3006 or 3102 to 3106

1

1 to 63

Spare

63

The module will recognize the request by receiving the special write block code
and respond with a read block with the following format:

Offset Description

Length

0

3002 to 3006 or 3102 to 3106

1

1

Write Block ID

1

2 to 61

Slave Poll Data Status

60

62 to 63

Spare

2