SM CODE RAM_SM_0
Detailed implementation
To enhance the coverage on SRAM data cells and to ensure adequate coverage for
permanent faults affecting the address decoder it is required to execute a periodic software
test on the system RAM memory. The selection of the algorithm must ensure the target SFF
coverage for both the RAM cells and the address decoder. Evidences of the effectiveness of
the coverage of the selected method must be also collected
Error reporting Depends on implementation
Fault detection time Depends on implementation
Addressed fault model Permanent
Dependency on Device configuration RAM size can change according to the part number.
Initialization Depends on implementation
Periodicity Periodic
Test for the diagnostic
Self-diagnostic capabilities can be embedded in the software, according to the test
implementation design strategy chosen.
Multiple-fault protection CPU_SM_0: Periodic core self-test software
Recommendations and known limitations
Usage of a March test C- is recommended.
Because the nature of this test can be destructive, RAM contents restore must be
implemented. Possible interferences with interrupt-serving routines fired during test execution
must be also considered (such routines can access to RAM invalid contents).
Startup execution of this safety mechanism is recommended for multiple fault mitigations -
refer to Section 4.1.3 Notes on multiple-fault scenario.
Unused RAM section can be excluded by the testing, under End user responsibility on actual
RAM usage by final Application software.
Table 17. RAM_SM_1
SM CODE RAM_SM_1
Description Parity on SRAM2
Ownership ST
Detailed implementation
Internal SRAM2 is protected by additional parity bits (1 bit per byte). The parity bits are
computed and stored when writing into the SRAM.
Error reporting
Error flag SYSCFG_CFGR2 set
NMI raised
Fault detection time Parity bits are checked during a reading.
Addressed fault model Permanent/transient
Dependency on Device configuration None
Initialization End user must enable the parity check using the option bit SYSCFG_CFGR2, after the boot.
Periodicity Continuous
Test for the diagnostic
Direct test procedure for SRAM2 parity function is not available. SRAM2 parity-related run-
time hardware failures leading to disabling such protection fall into multiple-fault scenario,
from IEC61508 perspective. Related failures are adequately mitigated by the combination of
safety mechanisms reported in this table, field Multiple-fault protection.
Multiple-fault protection
DIAG_SM_0: Periodic read-back of hardware diagnostics configuration registers.
RAM_SM_0: Periodic software test for static random access memory (SRAM).
Recommendations and known limitations
It is advised to initialize by software the whole SRAM2 memory at Application software
startup, to avoid getting parity errors when reading non-initialized locations.
As parity protection is restricted to SRAM2, End user is encouraged to store all safety-related
data in SRAM2 (if possible), in order to get benefit of such additional hardware-based fast
diagnostic.
UM2305
Hardware and software diagnostics
UM2305 - Rev 10
page 18/110