Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

StartBitRead/WriteCommandLengthDataChecksumStopBit
DDA50300-FF FD77


Checksum Calculation =  (Command + Length + Data) XOR 0xFFFF + 1

= (0x03 + 0x00) XOR 0xFFFF + 1

= 0xFFFD



Response

StartBitCommandStatusLengthDataChecksumStopBit
DD03001B

17 00 00 00 02 D0 03 E8 00 00 20 78 00 00 00 00 00 00 10 48 03 0F 02 0B 76 0B 82

FB FF77


Checksum Calculation Checksum Calculation = 0x10000 -  (Command Status + Length + Data) XOR 0xFFFF + 1

= 0x1000 - (0x03+ 0x00 )

= 0xFF FD

OR

Checksum Calculation =  (Command + Length + Data) XOR FF + 0x1B + data[] XOR 0xFFFF +1

= (0x03 + 0x00) XOR 0xFFFF 0x0401 XOR 0xFFF + 1

= 0xFBFE + 1

= 0xFFFD0xFBFF



References

...