APC 6000 user manual Function 3 and 4 read N words, Function 5 writing a bit

Models: 6000

1 38
Download 38 pages 11.72 Kb
Page 10
Image 10

JBUS protocol (continued)

Function 3 and 4: read N words

The number of words must be less than or equal to the word field size (see memory board).

function 3: read output or internal words;

function 4: read input words.

 

request

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

slave address

 

 

3 or 4

 

adress of

 

 

 

 

number of

 

 

 

CRC 16

 

 

 

 

first bit

 

 

 

 

words

 

 

 

 

 

 

 

 

 

 

 

 

MSB

LSB

 

MSB

 

LSB

 

 

 

 

 

 

1 byte

 

 

1 byte

 

2 bytes

 

 

 

2 bytes

 

 

2 bytes

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

response

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

slave address

 

 

3 or 4

 

number of

 

 

first word

 

last word

 

 

CRC 16

 

 

 

 

bytes read

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

PF

 

pf

 

PF

 

pf

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

1 byte

 

 

1 byte

 

1 byte

 

 

2 bytes

 

2 bytes

 

 

2 bytes

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

example

Reading words at location 146 to 14B of slave at address 28H (voltage fields)

request:

 

 

 

 

 

 

 

 

28

03

 

0146

 

06

 

A7 E0

 

 

 

 

 

 

 

 

 

 

 

 

 

response:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

28

03

 

0C

 

XXXX

 

YYYY

CRC 16

 

 

 

 

 

 

 

 

 

 

 

word 0146

word 014B

Function 5: writing a bit

request

slave address

5

 

bit address

bit value

 

0

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

1 byte

1 byte

 

2 bytes

 

1 byte

 

1 byte

 

 

 

 

 

 

 

 

 

 

 

 

write 0

 

 

 

 

bit set to 0

 

 

 

 

 

 

 

 

 

 

 

bit set to 1

 

 

write FF

 

 

 

 

 

CRC 16

2 bytes

response

slave address

5

bit address

bit value

0

CRC 16

In function 5 the response and request frames are identical.

example

Setting bit location C05 to 1 of slave at address 40H (inverter on)

request:

40 05 0C05 FF 00 90 7A

Page 10 - 6739389EN/FB

Page 10
Image 10
APC 6000 user manual Function 3 and 4 read N words, Function 5 writing a bit