Write Register
The write command is used to write contiguous registers (1 to 256 registers) in the engine.
Syntax: {Prefix1} {Types} {Lens} {Address} {Datas} {FCS}
Prefix1 : 0x7E 0x00 (2 bytes)
Types : 0x08 (1 byte)
Lens
: 0x00~0xFF (1 byte), byte count, i.e. number of registers written. When Lens=0x00, 256
Address : 0x0000~0xFFFF (2 bytes), starting register address.
Datas
: 0x00~0xFF (1~256 bytes), data to be written into the register(s)
FCS
: CRC-CCITT checksum, 2 bytes.
7
contiguous registers are to be written.
Computation sequence: Types+ Lens+Address+Datas; polynomial: X
(0x1021), initial value: 0x0000.
The following C language program is provided for reference.
16
12
5
+X
+X
+1