reset password
Author Message
aligh1979
Posts: 121
Posted 12:07 Feb 05, 2012 |

it seems we have the choice to pick the desired "ncheckbytes" byte numbers . in the example of the project requirements, the ncheckbytes is 1 , there will be some situation where the ncheckbytes was 2 for instance ,  then the value of
2 ^ (8 * ncheckbytes) would be 65536 , since it's calculated independently , then the checksum will be 1022 mod 65536 = 1022

and we are only allowed to have 2 bytes for check sum . and each byte can hold 255 max , so there is no way we can show that 1022 in this way !

please guide us .

Thanks

dely
Posts: 32
Posted 12:38 Feb 05, 2012 |

1022 in binary is 00000011 11111110.  It fits in 2 bytes perfectly fine.