F
fl
Hi,
I do not understand the index variable 'j' function below. How deos j
control to end of the for loop?
It cycles 8 times from step tracking. When does j equal 0, it ends the
loop. I do not understand why it ends when j==0.
Thanks in advance
..............
for (j=0x80; j; j>>=1) {
bit = crc & crchighbit;
crc<<= 1;
if (c & j)
crc|= 1;
if (bit)
crc^= polynom;
}
I do not understand the index variable 'j' function below. How deos j
control to end of the for loop?
It cycles 8 times from step tracking. When does j equal 0, it ends the
loop. I do not understand why it ends when j==0.
Thanks in advance
..............
for (j=0x80; j; j>>=1) {
bit = crc & crchighbit;
crc<<= 1;
if (c & j)
crc|= 1;
if (bit)
crc^= polynom;
}