http://www.freescale.com/files/microcontrollers/doc/app_note/AN3490.pdf
Some notes:
Flash:
The algorithm of writing to flash is different comparing to S12XD. The S12XE flash module provides ECC
– Error Correction Code that can resolve single bit fault and that can detect double bit fault. The ECC implementation requires that programming can be done on an aligned 8 byte basis (so called phrase). It’s very simple – we just have to write flash command, global address and data to appropriate registers and then launch the command. EEPROM:There are two ways how to access the EEPROM:
- Direct access to Data Flash. The algorithm is very similar to writing to flash (described above). The disadvantage is that the erase sector is 256 bytes (the sector size of S12XD is 4 bytes).
- Using of Emulated EEPROM (S12XS doesn’t have this feature). In short - there’s a "Buffer RAM" which behaves like EEPROM
– the internal mechanism copies the data from Data Flash to Buffer RAM after reset and stores data written to Buffer RAM to Data Flash. The user doesn’t care about this operation, just the initialization of Emulated EEPROM is necessary.Regards,
Nina