Hi all, I have a question about certain specifics of Motorola MC68HC908AZ60 mask 2J74Y microcontroller which are still not clear after reading the datasheet.
TLDR (very short description):
There are two important configuration registers in that microcontroller:
EEPROM nonvolatile register EENVR1 0xfe1c
EEPROM nonvolatile register EENVR2 0xfe18
According to the datasheet, there is EEPRTCT bit as bit 4 in both EENVR1 and EENVR2 registers which is used to protect 16 bytes at 0x08f0 - 0x08ff
Once programmed EEPRTCT bit to 0 the protection becomes permanent and can not be disabled.
The problem is - I've bought a few brand new MC68HC908AZ60 mask 2J74Y and they have EEPRTCT bit in EENVR1 programmed as high from the factory as it should be but EEPRTCT bit in EENVR2 is low which would normally mean "protected".
However, the datasheet doesn't mention what happens if EEPRTCT bit in EENVR1 is not the same as EEPRTCT bit in EENVR2 which is the case.
Detailed description:
All early MC68HC908AZ60 mask 2J74Y microcontrollers installed in CIM modules of Opel Vectra C have the problem with data retention where after certain ammount of time some of the flash locations could be read without error only when the microcontroller is hot. The consequence is when the temperature is low some instruction opcodes stored in flash are read with an error causing watchdog reset.
The problem could be solved by reading the flash while heating the microcontroller and then reprograming the flash - the microcontroller then works well for a few years until the same happens again. However, there is a chance some bytes would be read with an error even when the microcontroller is hot and if it is then reprogrammed with the wrong bytes the original flash contents is lost.
That's why I'd like to keep the original MC68HC908AZ60s from the device (there are two of them on the PCB) as a backup and to program the brand new ones with the correct flash + EEPROM data which as I read in some 15 years old forum posts could be done.
But the problem is, as I mentioned, I am not sure if the brand new MC68HC908AZ60s that I've bought will be usable because EEPRTCT bit in EENVR2 is not the same as EEPRTCT bit in EENVR1.
In the picture is how the EEPRTCT bit in EENVR1 is read by the programmer from the original mictrocontroller. The same is when reading the EENVR2. But when I read EENVR1 and EENVR2 from the brand new microcontrollers I've bought then EEPRTCT bit in EENVR2 is not checked.
Reprogramming or replacing MC68HC908AZ60s is my only option because there aren't new CIM modules on the market anymore and every module I can use will have or already has the same problem. CIM modules produced after year 2005 don't have the same problem because they changed the microcontroller type but with my car I can use only a module produced before year 2005.