[linux-dvb] CRC 32 information for MPEG checksum
Paolo Pasquali
pquadro79 at gmail.com
Wed Mar 14 12:37:15 CET 2007
Hi to all,
I'm doing an application to off-line analyze and edit a generic DVB TS. I
have a lot og problems with CRC32 calculation on PSI/SI tables.
I'm using a fast calculation CRC32:
poly: 0x04c11db7
table: 0x00000000, 0x04c11db7, 0x09823b6e, 0x0d4326d9, 0x130476dc,
0x17c56b6b, etc.............
algorithm:
public long CRC(byte[] by)
{
ulong ulCRC = 0xFFFFFFFF;
long len;
len = by.Length;
for(long i = 0; i < len; i++)
{
ulCRC = (ulCRC >> 8) ^ crcLookup[by[i] ^ (ulCRC & 0xFF) ];
}
return Convert.ToInt64( ulCRC ^ 0xFFFFFFFF);
}
Anyway the CRC32 value is different from CRC32 value in the last 4 byte of
the packet. Which packet bytes I have to use for CRC calculation?
Could you help me please? I'm going crazy for CRC32.....:-(
Best regards,
Paolo
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.linuxtv.org/pipermail/linux-dvb/attachments/20070314/4e1d8a68/attachment.htm
More information about the linux-dvb
mailing list