/serial-flash

The Serial Flash library provides functions for communicating with external memory connected via a Single/Dual/Quad/Octal SPI interface.

Primary LanguageCApache License 2.0Apache-2.0

Serial Flash

Overview

Provides functions for interacting with an external flash connected through its Single SPI/Dual SPI/Quad SPI/Octal SPI interface. The flash operations read, write, and erase are implemented as blocking functions. This library accepts the configuration generated using the QSPI Configurator tool but supports only one memory slot. Note that PSoC 6 supports up to 4 memory slots on the same QSPI block.

Features

  • Accepts the configuration generated by the QSPI Configurator tool
  • Supports Execute-in-Place (XIP) mode of operation
  • Provides information about the external memory to the programming tool for it to be able to program the memory, for example, when user wants to place the code into the external memory for XIP operation.
  • Allows for programming external memory if CY_ENABLE_XIP_PROGRAM is defined when building the application

Quick Start

  1. Add #include "cy_serial_flash_qspi.h"
  2. See the PSoC 6 MCU: QSPI Flash Read and Write code example to learn using this library

NOTE: If you delete the contents of the GeneratedSource directory inside the BSP, you must re-generate the memory configuration files cycfg_qspi_memslot.c/.h. To do this from inside the ModusToolbox IDE, open the QSPI Configurator tool from the Quick Panel and press Ctrl+S or click File > Save. If you open the tool outside the IDE, you need to first open the design.cyqspi file in the tool. To do this, click File > Import and then locate the file inside the BSP under COMPONENT_BSP_DESIGN_MODUS directory.

More information


© Cypress Semiconductor Corporation, 2019-2020.