Chapter 4 Explanation of Functions

(4) Explanation of function codes

(i) Reading the coil status [01h]

This function reads the coil status (on or off).

(Example)

When reading the status of the intelligent input terminals [1] to [6] of the inverter at slave address "8": Assume that the intelligent input terminals are in the status as shown below.

Intelligent input terminal

1

2

3

4

5

6

 

Coil number

7

8

9

10

11

12

Coils 13 and 14 are off.

Terminal status

ON

ON

ON

OFF

ON

OFF

 

Query

 

Response

 

 

 

Field name

Sample setting

 

 

Field name

Sample setting

 

 

 

(hexadecimal)

 

 

 

(hexadecimal)

 

1

Slave address (*1)

08

 

1

Slave address

08

 

2

Function code

01

 

2

Function code

01

 

3

Starting coil number

00

 

3

Number of data bytes

01

 

 

(upper digit) (*2)

 

 

4

Coil data (*4)

17

 

4

Starting coil number

06

 

5

CRC-16 code (upper digit)

12

 

 

(lower digit) (*2)

 

 

6

CRC-16 code (lower digit)

1A

 

5

Number of coils (upper digit)

00

 

 

*4

The data as many as the specified number of data

 

 

(*3)

 

 

bytes is transferred.

 

 

6

Number of coils (lower digit) (*3)

06

 

 

 

 

 

7

CRC-16 code (upper digit)

5C

 

 

 

 

 

8

CRC-16 code (lower digit)

90

 

 

 

 

*1

This query cannot be broadcasted.

 

 

 

 

 

*2

Note that the starting coil number is 1 less than the

 

 

 

 

 

 

actual coil number of the coil to be read first.

 

 

 

 

*3

If 0 or a value more than 32 is specified as the number

 

 

 

 

 

 

of coils to be read, the inverter will respond with error

 

 

 

 

 

 

code "03h".

 

 

 

 

 

The data received in the response indicates the status of coils 7 to 14. Read the received data (17h = 00010111b) as shown below. The least-significant bit indicates the status of coil 7.

Coil number

14

13

12

11

10

9

8

7

Coil status

OFF

OFF

OFF

ON

OFF

ON

ON

ON

If the query has specified the reading of an undefined coil, the data on the said coil is represented by "0" in the response.

If the function to read the coil status cannot be executed normally, the inverter will return an exception response. For details, see Item (viii), "Exception response."

4 - 133

Page 191
Image 191
Hitachi SJ700-2 instruction manual Intelligent input terminal Coil number, Terminal status