beautypg.com

Fairbanks X SERIES PR 5410 Process Indicator User Manual

Page 113

background image

Section 4: Commissioning

10/08 113

51207 Revision 1

4.12.2 Function 1 or 2: Reading n Bits


Command

Device

address

Function

number

Address

of 1st bit

Number

of bits

CRC 16

1 byte

1 byte

2 bytes

2 bytes

2 bytes

Range

1...127

1, 2

0,8,16...

8,16,24.

..

The bit address must always be the 1st bit of a byte. The number of bits to be read may not be
smaller than 8 and must be a multiple of 8.

Reply

Device

address

Function

number

Number of
read bytes

Value of

1st byte

Value of

2nd byte

..

Value of

last byte

CRC 16

1 byte

1 byte

1 byte

1 byte

1 byte

1 byte

2 bytes

8th ...

1st

bit

last bit


If the address of a bit to be read is out of the permissible range (0...127), an error message is sent
as a reply (the address plus the number of bits must not exceed 128).
Example of function 1 for reading the status bits of the scale.

Command

1

1

2

32

0

8

CRC

CRC

Reply

1

1

1

X

CRC

CRC


The read byte X

Bit 0 = bit 32 of SPM = ADC error

is interpreted as follows:

Bit 1 = bit 33 of SPM = above Max (maximum capacity)

:

Bit 6 = bit 38 of SPM = weight is stable

Bit 7 = bit 39 of SPM = weight is below zero or above Max

4.12.3 Function 3 or 4: Reading n Successive Words


Command

Device

address

Function

number

Address of

1st word

Number of

words

CRC 16

1 byte

1 byte

2 bytes

2 bytes

2 bytes

Range

1...127

3,4

0...63

1...64

Reply

Device

address

Function

number

Number of

bytes

Number of

words

CRC 16

1 byte

1 byte

1 byte

n bytes

2 bytes


MSB

LSB

MSB

- - - - - -

MSB LSB

1

st

word

last word


If the address of one of the words to be read is out of the permissible range (0...63), an error
message is sent as a reply (the address plus the number of bytes must not exceed 64).

Example of function 3 for reading a gross weight (D8 = W16) of 893 kg

Command

1

3

0

16

0

2

CRC

CRC

Reply

1

3

4

0

0

3

125

CRC

CRC

The individual bytes are shown.