开发者

CRC/Checksum Computation

Which technique is comput开发者_StackOverflowationally and programmatically easier to compute the CRC of a Data polynomial ?

LSB-First or MSB-first technique ?

I would be glad, if you could provide the reason behind it as well.


The techniques would be exactly the same. The fastest option would be to calculate the CRC in the order you receive the data, that way you only need O(1) storage.

Your CRC polynomial should take into account the endianess of the received data of course, so if you have a CRC polynomial for MSB first data, but receive bytes with LSB first, either reverse the bytes or the CRC polynomial. The fastest option here would be to reverse the CRC polynomial, since you can do that at compile time.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜