English
Language : 

AN975 Datasheet, PDF (5/11 Pages) STMicroelectronics – As part of a process of continuous improvement
UPGRADING FROM ST625X/6XB TO ST625X/6XC
1.2 COMPATIBILITY ISSUES AND RECOMMENDATIONS
1.2.1 EEPROM
ST625X/6XC have been designed to ensure data EEPROM integrity as long as the applica-
tion designer follows the guidelines described in application note AN671.
In general, EEPROM data corruption occurs whenever the reset signal is not well controlled
when the power supply goes either up or down. This is particularly true with a slow power
supply ramp-up and/or fall time, since the device may be in a supply voltage range where its
functionality is not guaranteed. If the device is not kept in reset state during both the power up
or down sequence then the microcontroller core may start writing to the EEPROM.
To avoid EEPROM data corruption, it is therefore highly recommended to disable the
EEPROM when it is not used. Note that the EEPROM is automatically enabled on reset
(EECTL reset state = 00H).
It is also possible to prevent unwanted EEPROM write accesses by enabling the on-chip LVD
which will reset the ST6 when the voltage is out of the device operating range.
Caution: When writing parallel data (E2PAR2 bit set), the EEPROM page must not be
changed (no access to the DRBR register is allowed).
1.2.2 I/O ports
This section gives some important recommendations on using I/O ports. These recommenda-
tions also apply to B devices but are even more important for C devices.
– Do NOT use single-bit instructions on port Data Registers.
– Configure the I/O ports following the safe I/O state switching sequence.
1.2.2.1 Instructions NOT to be used to access Port Data registers (SET, RES, INC and
DEC)
DO NOT USE SINGLE-BIT INSTRUCTIONS (SET, RES, INC and DEC) ON PORT DATA
REGISTERS IF ANY PIN OF THE PORT IS CONFIGURED IN INPUT MODE.
These instructions make an implicit read and write back of the entire register. In port input
mode, however, the data register reads from the input pins directly, and not from the data reg-
ister latches. Since data register information in input mode is used to set the characteristics of
the input pin (interrupt, pull-up, analog input), these may be unintentionally reprogrammed de-
pending on the state of the input pins.
As a general rule, it is better to only use single bit instructions on data registers when the
whole (8-bit) port is in output mode. In the case of inputs or of mixed inputs and outputs, it is
advisable to keep a copy of the data register in RAM. Single bit instructions may then be used
on the RAM copy, after which the whole copy register can be written to the port data register:
5/11