AsherGlick/AVRFID — Issue #1: Error in converision code
Author: AsherGlick
Created: 2011-10-29 04:29:09+00:00
State: open

int convertInput (int array[45]) {
int result = 0;
if (array[28]) result += 32768;
if (array[29]) result += 16348;
if (array[30]) result += 8192;
if (array[31]) result += 4096;
if (array[32]) result += 2048;
if (array[33]) result += 1024;
if (array[34]) result += 512;
if (array[35]) result += 256;
if (array[36]) result += 128;
if (array[37]) result += 64;
if (array[38]) result += 32;
if (array[39]) result += 16;
if (array[40]) result += 8;
if (array[41]) result += 4;
if (array[42]) result += 2;
if (array[43]) result += 1;
return result;
}

The last two numbers in [29] are wrong and should in fact be
if (array[29]) result += 16384;