Shop OBEX P1 Docs P2 Docs Learn Events
Add a CRC code to the message "10111" — Parallax Forums

Add a CRC code to the message "10111"

c99netc99net Posts: 2
edited 2012-10-10 05:32 in General Discussion
Hello !
I have the fallowing problem at school:

We have the fallowing message: 10111
I have to add a CRC code to this message using the fallowing polynomial x^3+x+1

The question is : what is the coded message?
Can anybody help me?
Thank you!
Cosmin Craciun

Comments

  • Dave HeinDave Hein Posts: 6,347
    edited 2012-10-09 12:22
    c99net, you first need to determine what the binary value of the generator polynomial is based on it's equation --- x^3+x+1. Then you need to determine how many bits the CRC, or remainder will be. I don't think anybody on the forum wants to just give you the answers outright, but we could verify if your answers are correct if you post them here. Use the long division technique Beau described at the link he posted. In the binary math that is used to compute CRCs, a subtract doesn't generate borrow's, and it reduces down to just performing an exclusive-or on each bit.
  • LoopyBytelooseLoopyByteloose Posts: 12,537
    edited 2012-10-10 01:31
    Mentoring is available, providing the answers to homework is a more awkward request. CRC is not that difficult and the instructor even made it easier by providing a task with less that 8 bits. It could have been 32bits.

    Beau is really good about these things, so no one really wants to mess this up by saying more.
  • c99netc99net Posts: 2
    edited 2012-10-10 05:32
    Thank you very much for the help. I will learn as much as I can and when I will have an answer I will tell you. The thing is that I didn't do math at this level for a long time... and now is tricky... Thank you again for the fast feedback! this forum is really great!
Sign In or Register to comment.