If I change data in PROM, do I need to change checksum??

Mike P. trinity at golden.net
Mon Nov 30 04:01:42 GMT 1998


>
>  generally, do ECU's check the checksum of the PROM data before starting
>  and not start, or go into limp mode if checksum is incorrect???
>
>  .... if so, where is the checksum generally stored on PROM, over what
>  range is it calculated, and what algorithm is used??? is it just a 16-bit
>  XOR??
>
>  cheers,
>  Warren Crowther
>  '91 Rx-7 13B Turbo
>

Yes, the PCM checks the PROM checksum on startup and it will enter a
failsafe mode when the cum is incorrect. In my Ford Probe GT, the (Mazda)
MECS-II PCM does a simple 16-bit addition of all words in the PROM, from
8000 to FFFE inclusive. Rollouts from the MSB of the 16-bit sum are ignored.
The sum is then compared to a value encoded in the program itself.
Interestingly, the sum compare value is included in the sum itself.

I chose to leave the sum-check intact instead of disabling it in the code.
In GM PROMs (for one), a byte can be altered in the calibration data to
"disable" the PROM checksum error. Usually a 0xAA in this position will
disable the checksum error. In the case of my PGT, I chose instead to
allocate 2 previously unused bytes in the calibration data to "adjust" the
overall sum. That is, after all my modifications, I'd zero these two bytes
and then run a checksum of the image. The resulting sum will be incorrect
compared to the canned value. I'd then calculate a 16-bit value based on the
canned value and the current sum and place it in these two bytes to make the
original sum work out again. This way I still get a check of the PROM on
each startup.


--- 
Mike
94PGT
http://www.golden.net/~trinity




More information about the Diy_efi mailing list