I am trying to compare a CRC from my file with the CRC taken from the serial port. The problem is that when I change code in my software, sometimes the CRC doesn't match each other. Can anyone help me?
I am trying to compare a CRC from my file with the CRC taken from the serial port. The problem is that when I change code in my software, sometimes the CRC doesn't match each other. Can anyone help me?
I've use my psychic powers to determine where the problem in your code is. Now you can use your psychic powers to figure out what changes I'm suggesting.
Quzah.
Hope is the first step on the road to disappointment.
I just wanna know what could be the reasoning behind this. If I comment a useless function, I get mismatched CRC. Are there any latest information on CRC on the web that I can check out?
7. It is easier to write an incorrect program than understand a correct one.
40. There are two ways to write error-free programs; only the third one works.*
Thanks Dave
You really should attempt to post as much detail as possible about your problem. But anyway, I'll take a shot in the dark on this one since I had a similiar problem with a RS-232 device.
My problem was a timing issue with the RS-232 port. I was writing an application to communicate with a security/automation controller via the serial port. The controller required me to wait a full second prior to querying the port for the first time and thereafter I had to wait 50 milliseconds to read each additional char on the port. If I waited a little longer than the stated time, the app would sometimes hang or I would miss a transmitted character. Obviously, missing a character would cause inaccurate CRC calculations for me. Timing issue may be a problem for you if you're in a loop calling other functions and querying the RS-232 port.
As I said before this is just a shot in the dark.
Check out http://zorc.breitbandkatze.de/crc.html
Bob
I have been seen some CRC look up tables that are 16 bit and others that are two 8 bit tables which is basically the 16 bit table broken down. Can you tell me why they do this and which way is better? Also, if you can, can you lead me to the website that explains more about this?
Thanks
Last edited by NewGuy100; 09-12-2005 at 07:55 AM.