![AV Link HX-2384Z Скачать руководство пользователя страница 82](http://html1.mh-extra.com/html/av-link/hx-2384z/hx-2384z_user-manual_3023799082.webp)
H
H
H
X
X
X
-
-
-
2
2
2
3
3
3
8
8
8
4
4
4
Z
Z
Z
/
/
/
H
H
H
X
X
X
-
-
-
3
3
3
3
3
3
1
1
1
6
6
6
0
0
0
8
8
8
Z
Z
Z
81
D-1.5 Byte 5 – Check Byte
Check Byte (CB)
Name
Bit 7
Bit 6
Bit 5
Bit 4
Bit 3
Bit 2
Bit 1
Bit 0
CB
CRC (cyclic redundancy check)
CRC:
Host must send CRC code to follow the last byte.
Example:
20 01 05 03 93 --- Device ID 0, Switch Video Output 6 to the Input 3.
Byte 1 (DB) is 0x20 – Device: Iden Device ID = 0x20 + 0 = 0x20
Byte 2 (RB) is 0x01 – Request: Switch Video Output Channel = 0x01
Byte 3 (IB) is 0x06 – Index: Output 6 = 6
Byte 4 (VB) is 0x03 – Value: Input 3 = 3
Byte 5 (CB) is 0x93 – CRC code from Byte 1 to Byte 4. (CRC4). CRC is 0x93
CRC Calculation
CRC 0
= 0 (initial value)
CRC 1
= Crc8(CRC 0 ^
Byte 1
) = Crc8(0x20) = 0x23
CRC 2
= Crc8(CRC 1 ^
Byte 2
) = Crc8(0x23 ^ 0x01) = Crc8(0x22) = 0x9F
CRC 3
= Crc8(CRC 2 ^
Byte 3
) = Crc8(0x9F ^ 0x06) = Crc8(0x99) = 0x8D
CRC 4
= Crc8(CRC 3 ^
Byte 4
) = Crc8(0x8D ^ 0x03) = Crc8(0x8E) = 0x93
Use the algebraic representations of the polynomials is the
CRC-8-Dallas/Maxim
Polynomial:
(
0x31 or 0x8C
)
For "^" (XOR)
XOR Truth Table
Input
Output
A
B
0
0
0
0
1
1
1
0
1
1
1
0