else if ((CANctrl & 0x07) == 3) // Acceptance Filter 3 (RXF3) = CAN ID 4E1
{
// The VIN can be constructed by taking the number "1" and converting the CAN IDs 4E1 and 514 to ASCII.
// So with "4E1 4255313032363839" and "514 4731524436453436",
// you would end up with 42 55 31 30 32 36 38 39 47 31 52 44 36 45 34 36,
// where 42 is ASCII for B, 55 is U, etc.
for (k=0;k<8;k++)
car_vin[k+9] = can_databuffer[k];
car_vin[17] = 0;
}
else if ((CANctrl & 0x07) == 4) // Acceptance Filter 4 (RXF4) = CAN ID 514
{
car_vin[0] = '1';
for (k=0;k<8;k++)
car_vin[k+1] = can_databuffer[k];
//car_vin[16] = 0;
}
Burn it to the Module. Active since 21:09 CET (UTC+1) 26.12.2012