Invariable Memory Test - Flash Rom - Renesas RL78 Series Application Note

Vde certified self test library
Hide thumbs Also See for RL78 Series:
Table of Contents

Advertisement

RL78 Family
2.2
Invariable Memory Test – Flash ROM
This section describes the Flash memory test using CRC routines. CRC is a fault / error control technique which
generates a single word or checksum to represent the contents of memory. A CRC checksum is the remainder of a
binary division with no bit carry (XOR used instead of subtraction), of the message bit stream, by a predefined (short)
bit stream of length n + 1, which represents the coefficients of a polynomial with degree n. Before the division "n"
zeros are appended to the message stream. CRCs are popular because they are simple to implement in binary hardware
and are easy to analyse mathematically.
The Flash ROM test can be verified by generating a reference CRC value for the contents of the ROM and storing this
in memory. During the memory self test the same CRC algorithm is used to generate a CRC value, which is compared
with the reference CRC value. The technique recognises all one-bit errors and a high percentage of multi-bit errors.
The complicated part of using CRCs is if you need to generate a CRC value that will then be compared with other CRC
values produced by other CRC generators. This proves difficult because there are a number of factors that can change
the resulting CRC value even if the basic CRC algorithm is the same. This includes the combination of the order that
the data is supplied to the algorithm, the assumed bit order in any look-up table used and the required order of the bits
of the actual CRC value. Both the hardware and software self test functions are able to executed iteratively, thus
allowing the option of a full CRC calculation to be made or a CRC calculation of a smaller segments suitable to the
operation of the end application.. For a full calculation (or first part of an iterative calculation), a starting value of
h'0000 is used or the previous partial result is provided as the starting point for the next calculation stage.
The software implementation will produce the same result as the IAR Embedded workbench Standard tool chain using
the "extra options" as provided in the Linker configuration menu for CRC test harness projects. Therefore if you are
using the IAR tool chain to automatically insert a reference CRC into the ROM the value can be compared directly with
the one calculated.
The hardware module while using the same fundamental CRC algorithm uses a different data format for calculating the
reference CRC value. Here a compatible CRC calculation routine is provided as part of the test harness for reference.
2.2.1
CRC16-CCITT Algorithm
The RL78 includes a CRC module that includes support for the CRC16-CCITT. Using this software to drive the CRC
module produces this 16-bit CRC16-CCITT:
Software Algorithm
CCITT 16 Polynomial = 0x1021 (x
Input Data Width = 8 bits
Data Input = Not Bit Reversed
Initial value = 0x0000 or 16 bit previous partial result
Calculated Result = 16 bits (not bit reversed)
Hardware Algorithm
CCITT 16 Polynomial = 0x1021 (x
Input Data Width = 8 bits
Data Input = Bit Reversed
Initial value = 0x0000 or 16 bit previous partial result
Calculated Result = 16 bits (Bit reversed)
R01AN0749EG0201 Rev.2.01
Mar 04, 2014
VDE Certified IEC60730/60335 Self Test Library
16
12
5
+ x
+ x
+ 1)
16
12
5
+ x
+ x
+ 1)
Page 12 of 50

Advertisement

Table of Contents
loading

This manual is also suitable for:

Iec60730Iec60335

Table of Contents