Microsemi DG0388 SmartFusion2 SoC FPGA Error Detection and Correction of eSRAM Memory User Guide

June 9, 2024
Microsemi

DG0388 SmartFusion2 SoC FPGA Error
Detection and Correction of Seram Memory

User Guide

©2021 Microsemi, a wholly owned subsidiary of Microchip Technology Inc. All rights reserved. Microsemi and the Microsemi logo are registered trademarks of Microsemi Corporation. All other trademarks and service marks are the property of their respective owners.
Microsemi makes no warranty, representation, or guarantee regarding the information contained herein or the suitability of its products and services for any particular purpose, nor does Microsemi assume any liability whatsoever arising out of the application or use of any product or circuit. The products sold hereunder and any other products sold by Microsemi have been subject to limited testing and should not be used in conjunction with mission-critical equipment or applications. Any performance specifications are believed to be reliable but are not verified, and Buyer must conduct and complete all performance and other testing of the products, alone and together with, or installed in, any end-products. Buyer shall not rely on any data and performance specifications or parameters provided by Microsemi. It is the Buyer’s responsibility to

independently determine suitability of any products and to test and verify the same. The information provided by Microsemi hereunder is provided “as is, where is” and with all faults, and the entire risk associated with such information is entirely with the Buyer. Microsemi does not grant, explicitly or implicitly, to any party any patent rights, licenses, or any other IP rights, whether with regard to such information itself or anything described by such information. Information provided in this document is proprietary to Microsemi, and Microsemi reserves the right to make any changes to the information in this document or to any products and services at any time without notice.
About Microsemi
Microsemi, a wholly owned subsidiary of Microchip Technology Inc. (Nasdaq: MCHP), offers a comprehensive portfolio of semiconductor and system solutions for aerospace & defense, communications, data center and industrial markets. Products include high-performance and radiation-hardened analog mixed-signal integrated circuits, FPGAs, SoCs and ASICs; power management products; timing and synchronization devices and precise time solutions, setting the world’s standard for time; voice processing devices; RF solutions; discrete components; enterprise storage and communication solutions, security technologies and scalable anti-tamper products; Ethernet solutions; Power- over-Ethernet ICs and midspans; as well as custom design capabilities and services. Learn more at www.microsemi.com.

Revision History

The revision history describes the changes that were implemented in the document. The changes are listed by revision, starting with the current publication.
1.1 Revision 11.0
The following is a summary of the changes made in this revision.

  • Updated the document for Libero SoC v12.6.
  • Removed the references to Libero version numbers.

1.2 Revision 10.0
Updated the document for Libero SoC v11.8 SP1 software release.
1.3 Revision 9.0
Updated the document for Libero SoC v11.8 software release.
1.4 Revision 8.0
Updated the document for Libero SoC v11.7 software release (SAR 77402).
1.5 Revision 7.0
Updated the document for Libero SoC v11.6 software release (SAR 72777).
1.6 Revision 6.0
Updated the document for Libero SoC v11.5 software release (SAR 64979).
1.7 Revision 5.0
Updated the document for Libero SoC v11.4 software release (SAR 60476).
1.8 Revision 4.0
Updated the document for Libero SoC v11.3 software release (SAR 56852).
1.9 Revision 3.0
Updated the document for Libero SoC v11.2 software release (SAR 52960).
1.10 Revision 2.0
Updated the document for Libero SoC v11.0 software release (SAR 47858).
1.11 Revision 1.0
The first publication of this document.
SmartFusion2 SoC FPGA – Error Detection and Correction of Seram Memory

Introduction

This document describes the Error Detection and Correction (EDAC) capabilities of the SmartFusion® 2 devices on the embedded static random access memory (Seram). The EDAC controllers implemented in the SmartFusion2 devices support Single-Error Correction and Double-Error Detection (SECDED). All memories within the Microcontroller Subsystem (MSS) of the SmartFusion2 are protected by SECDED. The Seram memory can be eSRAM_0 or eSRAM_1. The address range of eSRAM_0 is 0x20000000 to 0x20007FFF and the address range of eSRAM_1 is 0x20008000 to 0x2000FFFF.
When SECDED is enabled:

  • A write operation computes and adds 8 bits of SECDED code to every 32 bits of data.
  • A read operation reads and checks the data against the stored SECDED code to support 1-bit error correction and 2-bit error detection.

In this demo, the EDAC can be identified by the blinking Light-Emitting Diode (LED) on the board and by the Graphical User Interface (GUI). The EDAC of eSRAM supports the following features:

  1. SECDED mechanism
  2. Provides interrupts to the ARM Cortex- M3 processor and FPGA fabric upon the detection of a 1-bit error or 2-bit error.
  3. Stores the number of 1-bit and 2-bit errors to the error counter registers.
  4. Stores the address of the last 1-bit or 2-bit error affected memory location.
  5. Stores 1-bit or 2-bit error data into the SECDED registers.
  6. Provides error bus signals to the FPGA fabric.

Refer to the EDAC chapter of the UG0443: SmartFusion2 and IGLOO2 FPGA Security and Reliability User Guide and the Seram chapter of the UG0331: SmartFusion2 Microcontroller Subsystem User Guide.
2.2 Demo Requirements
The following table lists the hardware and software requirements for running the demo design.
Table 1 • Design Requirements

Requirement Version
Operating System 64 bit Windows 7 and10
Hardware

SmartFusion2 Security Evaluation Kit:
• FlashPro4 programmer
• USB A to Mini – B USB cable
• 12 V Adapter| Rev D or later
Software

FlashPro Express| Refer to the readme.txt file provided in the design files
for the software versions used with this reference design.
Libero
 System-on-Chip (SoC) software
SoftConsole
Host PC Drivers| USB to UART drivers
For launching demo GUI| Microsoft.NET Framework 4 client

Note: Libero Smart Design and configuration screen shots shown in this guide are for illustration purpose only.
Open the Libero design to see the latest updates.
2.3 Prerequisites
Before you begin:
Download and install Libero SoC (as indicated in the website for this design) on the host PC from the following location.
https://www.microsemi.com/product-directory/design-resources/1750-libero-soc
2.3.1 Design Files
The demo design files are available for download from the following path in the Microsemi website: http://soc.microsemi.com/download/rsc/?f=m2s_dg0388_df
Design files include:

  • GUI Executable
  • Libero Project
  • Programming Job
  • Readme file

The following figure shows the top-level structure of the design files. For further details, refer to the readme.txt file. 2.4 Demo Design Description
Each Seram within the MSS is protected by a dedicated EDAC controller. EDAC detects a 1-bit error or 2-bit error when data is read from the memory. If EDAC detects the 1-bit error, the EDAC controller corrects the same error bit. If EDAC is enabled for all the 1-bit and 2-bit errors, corresponding error counters in the system registers are incremented and corresponding interrupts and error bus signals to the FPGA fabric are generated.
In a Single Event Upset (SEU) susceptible environment, Random Access Memory (RAM) is prone to transient errors caused by heavy ions. This happens in real- time. To demonstrate this, an error is introduced manually and detection and correction is observed.
This demo design involves implementation of following tasks:

  • Enable EDAC
  • Write data to Seram
  • Read data from Seram
  • Disable EDAC
  • Corrupt one or two bits
  • Write data to Seram
  • Enable EDAC
  • Read the data
  • In the case of a 1-bit error, the EDAC controller corrects the error, updates the corresponding status registers, and gives the data written in step 2 at the read operation done at step 8.
  • In the case of a 2-bit error, a corresponding interrupt is generated, and the application must correct the data or take the appropriate action in the interrupt handler. These two methods are demonstrated in this demo.
    Two tests are implemented in this demo: loop test and manual test, and they are applicable to both 1-bit and 2-bit errors.

2.4.1 Loop Test
Loop Test is executed when the SmartFusion2 receives a loop test command from the GUI. Initially, all the error counters and EDAC related registers are placed in the RESET state.
The following steps are executed for each iteration:

  1. Enable the EDAC controller.
  2. Write the data to the specific Seram memory location.
  3. Disable the EDAC controller.
  4. Write the 1-bit or 2-bit error induced data to the same Seram memory location.
  5. Enable the EDAC controller.
  6. Read the data from the same Seram memory location.
  7. Send the 1-bit or 2-bit error detection and 1-bit error correction data in case of 1-bit error to the GUI.

2.4.2 Manual Test
This method allows manual testing for enabling or disabling EDAC and write or read operation. Using this method, 1-bit or 2-bit errors can be introduced to any location within the seam. Enable the EDAC and write data to the specified address using the GUI fields. Disable the EDAC and write 1-bit or 2-bit corrupted data to the same address location. Enable the EDAC and read the data from the same address location then the LED on the board toggles to notify the detection and correction of errors. The corresponding error counter is displayed on the GUI. The GUI Serial Console logs all the actions performed in SmartFusion2.
The following figure shows the Seram EDAC demo operations. 2.5 Running the Demo
This section describes the SmartFusion2 Security Evaluation Kit board setup, the GUI options, and how to execute the demo design.
2.5.1 Demo Setup
The following steps describe how to setup the demo:

  1. Connect the FlashPro4 programmer to the J5 connector of SmartFusion2 Security Evaluation Kit board.

  2. Connect one end of the USB mini-B cable to the J18 connector provided in the SmartFusion2 Security Evaluation Kit board. Connect the other end of the USB cable to the host PC. Ensure that the USB to UART Bridge drivers are automatically detected (can be verified in the Device Manager), as shown in Figure 4, page 7.
    Note: Copy the COM port number for serial port configuration. Ensure that the COM port Location is specified as on USB Serial Converter D, as shown in the following figure.

  3. If USB to UART bridge drivers are not installed, download and install the drivers from www.microsemi.com/soc/documents/CDM_2.08.24_WHQL_Certified.zip

  4. Connect the jumpers on the SmartFusion2 Security Evaluation Kit board, as shown in the following figure. The power supply switch SW7 must be switched OFF while making the jumper connections.
    Table 2 • SmartFusion2 Security Evaluation Kit Jumper Settings****

Jumper Pin (From) Pin (To) Comments
J22, J23, J24, J8, J3 1 (default) 2 These are the default jumper settings

of the SmartFusion2 Security Evaluation Kit board. Ensure that these jumpers are set accordingly.
5.  Connect the power supply to J18 connector.

The following figure shows the board setup for running the demo on the SmartFusion2 SecuEvaluation Kit. 2.5.2 Graphical User Interface
The following section describes about Seram – EDAC demo GUI.

The GUI supports the following features:

  1. Selection of COM port and Baud Rate.
  2.  Selection of 1-bit error correction tab or 2-bit error detection tab.
  3. Selection of eSRAM0 or eSRAM1.
  4. Address field to write or read data to or from specified Seram address.
  5. Data field to write or read data to or from specified Seram address.
  6.  Serial Console section to print the status information received from the application.
  7. EDAC ON/OFF: Enables or disables the EDAC.
  8. Write: Allows writing data to the specified address.
  9. Read: Allows reading data from the specified address.
  10. LOOP test ON/OFF: Allows testing the EDAC mechanism in a loop method.

2.5.3 Running the Design
The following steps describe how to run the design:

  1. Switch ON the supply switch, SW7.
  2. Program the SmartFusion2 Security Evaluation kit board with the job file provided as part of the design files (\Programming job\eSRAM_0\eSRAM0.job or \Programming job\eSRAM_1\eSRAM1.job) using FlashPro Express software, refer to Appendix: Programming the Device Using FlashPro Express, page 12.
  3. Press SW6 switch to reset the board after successful programming.
  4. Launch the EDAC_eSRAM Demo GUI executable file available in the design files (\GUI Executable\ EDAC_eSRAM.exe). The GUI window is displayed, as shown in Figure 6, page 9.
  5. Select the appropriate COM port (to which USB to UART Bridge drivers are pointed) from the COM Port drop-down list.
  6. Select the Baud Rate as 57600 and click Connect. After establishing the connection, Connect changes to Disconnect.
  7. Select Seram 0 or Seram 1 depending upon the programming file selected in step 2.
  8. Select the 1-bit Error Correction tab or 2-bit Error Detection tab, as shown in Figure 7, page 10. and Figure 8, page 11.
  9. Two types of tests can be performed: Manual and Loop.

2.5.3.1 Performing Loop Test
Click Loop Test ON. It runs in loop mode where continuous correction and detection of errors is done. The loop runs for 200 iterations. All actions performed in SmartFusion2 are logged in the Serial Console section of the GUI. The 2-bit error detection loop test prints the error affected Seram address offset in Serial Console. Click Loop Test OFF after 200 iterations are completed.
Table 3 • Seram Memory Addresses Used in Loop Test

Memory 1 1-Bit Error Correction 2-Bit Error Detection
eSRAM0 0x20000000 0x20002000
eSRAM1 0x20008000 0x2000A000

2.5.3.2 Performing Manual Test
In this method, errors are introduced manually using GUI. Use the following steps to execute 1-bit error correction or 2-bit error detection:

  1. Input Address and Data fields (use 32-bit Hexadecimal values).
  2. Click EDAC ON.
  3. Click Write.
  4. Click EDAC OFF.
  5. Just change 1-bit (in case of 1-bit error correction) or 2 bits (in case of 2-bit error detection) in Data field (introducing error).
  6. Click Write.
  7. Click EDAC ON.
  8. Click Read.
  9. Observe Error Count display and Data field in the GUI. The error count value increases by 1.

All the actions performed in SmartFusion2 are logged in Serial Console section of GUI.
Note: To switch from 1-bit Error Correction tab to 2-bit Error Detection tab or vice versa in EDAC_eSRAM Demo GUI, reset the hardware board.

2.6 Conclusion
This demo shows SmartFusion2 SECDED capabilities of the Seram.

Appendix: Programming the Device Using FlashPro Express

This section describes how to program the SmartFusion2 device with the programming job file using FlashPro Express.
To program the device, perform the following steps:

  1. Ensure that the jumper settings on the board are the same as those listed in Table 2, page 7.
    Note: The power supply switch must be switched off while making the jumper connections.

  2. Connect the power supply cable to the J6 connector on the board.

  3. Power ON the power supply switch SW7.

  4. On the host PC, launch the FlashPro Express software.

  5. Click New or select New Job Project from FlashPro Express Job from Project menu to create a new job project, as shown in the following figure.

  6. Enter the following in the New Job Project from FlashPro Express Job dialog box:
    • Programming job file: Click Browse, and navigate to the location where the .job file is located and select the file. The default location is:

    \m2s_dg0388_df\Programming Job • FlashPro Express job project name: Click Browse and navigate to the location where you want to save the project.
  7. Click OK. The required programming file is selected and ready to be programmed in the device.

  8. The FlashPro Express window appears as shown in the following figure. Confirm that a programmer number appears in the Programmer field. If it does not, confirm the board connections and click Refresh/Rescan Programmers.

  9. Click RUN. When the device is programmed successfully, a RUN PASSED status is displayed as shown in the following figure.

  10. Close FlashPro Express or in the Project tab, click Exit.

Microsemi Headquarters
One Enterprise, Aliso Viejo,
CA 92656 USA
Within the USA: +1 800-713-4113
Outside the USA: +1 949-380-6100
Sales: +1949-380-6136
Fax: +1949-215-4996
Email: sales.support@microsemi.com
www.microsemi.com
Microsemi Proprietary DG0388 Revision 11.0

References

Read User Manual Online (PDF format)

Read User Manual Online (PDF format)  >>

Download This Manual (PDF format)

Download this manual  >>

Related Manuals