Guest User

Untitled

a guest
Feb 23rd, 2013
235
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.99 KB | None | 0 0
  1. Example of CRC calculation:
  2.  
  3. Frame = 0207h
  4.  
  5. CRC initialization 1111 1111 1111 1111
  6. Load the first байта 0000 0010
  7. Execute xor with the first 1111 1111 1111 1101
  8. Байта of the frame
  9. Execute 1st right сдвиг 0111 1111 1111 1110 1
  10. Carry=1,load polynomial 1010 0000 0000 0001
  11. Execute xor with the 1101 1111 1111 1111
  12. polynomial
  13. Execute 2nd right сдвиг 0110 1111 1111 1111 1
  14. Carry=1,load polynomial 1010 0000 0000 0001
  15. Execute xor with the 1100 1111 1111 1110
  16. polynomial
  17. Execute 3rd right сдвиг 0110 0111 1111 1111 0
  18. Execute 4th right сдвиг 0011 0011 1111 1111 1
  19. Carry=1,load polynomial 1010 0000 0000 0001
  20. Execute xor with the 1001 0011 1111 1110
  21. polynomial
  22. Execute 5th right сдвиг 0100 1001 1111 1111 0
  23. Execute 6th right сдвиг 0010 0100 1111 1111 1
  24. Carry=1,load polynomial 1010 0000 0000 0001
  25. Execute xor with the 1000 0100 1111 1110
  26. polynomial
  27. Execute 7th right сдвиг 0100 0010 0111 1111 0
  28. Execute 8th right сдвиг 0010 0001 0011 1111 1
  29. Carry=1,load polynomial 1010 0000 0000 0001
  30.  
  31. Load the second байта 0000 0111
  32. of the frame
  33. Execute xor with the 1000 0001 0011 1001
  34. Second байта of the frame
  35. Execute 1st right сдвиг 0100 0000 1001 1100 1
  36. Carry=1,load polynomial 1010 0000 0000 0001
  37. Execute xor with the 1110 0000 1001 1101
  38. polynomial
  39. Execute 2nd right сдвиг 0111 0000 0100 1110 1
  40. Carry=1,load polynomial 1010 0000 0000 0001
  41. Execute xor with the 1101 0000 0100 1111
  42. polynomial
  43. Execute 3rd right сдвиг 0110 1000 0010 0111 1
  44. Carry=1,load polynomial 1010 0000 0000 0001
  45. Execute xor with the 1100 1000 0010 0110
  46. polynomial
  47. Execute 4th right сдвиг 0110 0100 0001 0011 0
  48. Execute 5th right сдвиг 0010 0100 0000 1001 1
  49. Carry=1,load polynomial 1010 0000 0000 0001
  50. Execute xor with the 1001 0010 0000 1000
  51. polynomial
  52. Execute 6th right сдвиг 0100 1001 0000 0100 0
  53. Execute 7th right сдвиг 0010 0100 1000 0010 0
  54. Execute 8th right сдвиг 0001 0010 0100 0001 0
  55. CRC Result 0001 0010 0100 0001
  56. 12h 41h
Advertisement
Add Comment
Please, Sign In to add comment