I calculate CRC using this code:
private float CreateCRC(ByteBuffer bb)
{
CRC32 checksum=new CRC32();
for(int i=0;i<bb.capacity()-4;i++)
{
checksum.update(bb.get(i));
}
return checksum.getValue();
}
Then I add value to last 4 bytes of buffer. Is this right way?>