Generic Serial Flash Interface Intel® FPGA IP User Guide

ID 683419
Date 11/09/2023
Public

A newer version of this document is available. Customers should click here to go to the newest version.

Document Table of Contents

1.9. Intel HAL Driver

The HAL API is available for this controller in the following software files:
  • intel_generic_serial_flash_interface_top.h
  • intel_generic_serial_flash_interface_top.c

These files implement the Generic Serial Flash Interface core device driver for the HAL system library.

Intel HAL supports a number of generic device model classes including one for device flashes. Developing against these generic classes gives a consistent interface for driver functions so that the HAL can access the driver functions uniformly.

A HAL API application begins by calling alt_flash_open_dev() to open the flash device, which returns a file handle to a flash device. You can obtain the IP name from system.h. All offset-related variables are based on absolute addressing to the flash memory.

HAL API supports the following QSPI flash device families:

  • Micron (MT25QL and MT25QU variants)
  • Cypress (S25FL-S and S25FS-S variants)
  • Macronix (MX25L and MX66U variants)
  • Winbond (W25Q variant)
  • GigaDevice (GD55LB variant)
  • ISSI (I25LP and I25WP variants)
Note: The Intel HAL Driver is supported in Intel® Quartus® Prime Pro Edition software only.
Note: Enable altera_safelib in BSP Software Package from BSP Editor to use the HAL API for Intel® Quartus® Prime Pro Edition software version prior to 21.4.
Note: Flash_Timeout is configurable in the Board Support Package Editor with the default value of 700000 microseconds (0.7 seconds).