Re: simple transport protocol



Hello, Willem!
You wrote on Mon, 26 May 2008 06:18:53 +0000 (UTC):

W> Suppose the checksum is a simple sum modulo 256.
W> We want to send the values: 2 5 8 10 15 20
W> So, the total of what we send is this:

W> length | data | crc


W> 0 7 2 5 8 10 15 20 196

W> What I do _is_ sum % 256. Read it again, more carefully.
Alright, from the example above, considering the values are decimal:
2+5+8+10+15+20 = 60, 60 mod 256 = 60, not 196. How then you get 196?

With best regards, Roman Mashak. E-mail: mrv@xxxxxxxx


.



Relevant Pages

  • Re: simple transport protocol
    ... W> Suppose the checksum is a simple sum modulo 256. ... Some misunderstanding of terms: you sum up the values to be transmitted and ...
    (comp.programming)
  • Re: simple transport protocol
    ... Roman wrote: ... W> Suppose the checksum is a simple sum modulo 256. ... You all think I'm paranoid, ...
    (comp.programming)