EasyManua.ls Logo

Schweitzer Engineering Laboratories SEL-587Z - 02 h Read Input Status Command

Schweitzer Engineering Laboratories SEL-587Z
276 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
D.5
Date Code 20020903 SEL-587Z Instruction Manual
Modbus RTU Communications Protocol
Modbus Commands
02h Read Input
Status Command
Use function code 02h to read the On/Off status of the selected bits (inputs).
You may read the status of up to 2000 bits per query. Note that the input
addresses start at 0 (e.g., Input 1 is located at address zero). The input status is
packed one input per bit of the data field. The least significant byte (LSB) of
the first data byte contains the starting input address in the query. The other
inputs follow towards the high order end of this byte, and from low order to
high order in subsequent bytes.
To build the response, the relay calculates the number of bytes required to
contain the number of bits requested. If the number of bits requested is not
evenly divisible by eight, the relay adds one more byte to maintain the balance
of bits, padded by zeroes to make an even byte.
Input numbers are defined below:
Input addresses start at 0000 (i.e., Input 1 is located at Input Address 0000).
The relay responses to errors in the query are shown below:
Table D.5 02h Read Input Status Command
Bytes Field
Requests from the master must have the following format:
1 byte Slave Address
1 byte Function Code (02h)
2 bytes Address of the First Bit
2 bytes Number of Bits to Read
2 bytes CRC-16
A successful response from the slave will have the following format:
1 byte Slave Address
1 byte Function Code (02h)
1 byte Bytes of data (n)
n bytes Data
2 bytes CRC-16
Input Numbers Description
1 Input 1
2 Input 2
Error Error Code Returned
Communication
Counter Increments
Invalid bit to read Illegal Data Address (02h) Invalid Address
Invalid number of bits to read Illegal Data Value (03h) Illegal Register
Format error Illegal Data Value (03h) Bad Packet Format

Table of Contents

Related product manuals