HAL XSPI Overview

Introducing XSPI

group XSPI_Introduction

  • This introduction is under development.

Module and files

The following diagram illustrates the XSPI module and its associated files.

Module and files diagram

Component diagram

The following diagram illustrates the software components involved in the XSPI module. It shows the interactions between the user application, HAL drivers, low-level drivers, and the hardware components.



@startuml

<style>

componentDiagram {

   arrow {

      FontSize 8

   }

}

</style>



title XSPI Software Component Diagram



package "HAL" {

    [HAL_SERVICE]

    [HAL_XSPI]

    [HAL_DMA]

}



package "Low Layer" {

    [LL_DLYB]

    [CMSIS]

    [XSPI Interrupt routine service]

    [DMA Interrupt routine service]

}



package "HW" {

    [STM32_HW]

}



[Appli] --> [HAL_XSPI] : HAL XSPI API

[Appli] <-- [HAL_XSPI] : XSPI callback

[HAL_XSPI] --> [LL_DLYB] : LL DLYB API

[HAL_XSPI] -r-> [HAL_DMA] : HAL DMA_Start_IT\nHAL_DMA_Abort_IT

[HAL_XSPI] -l-> [HAL_SERVICE] : HAL_GetTick

[HAL_XSPI] <-- [XSPI Interrupt routine service]

[HAL_XSPI] <-r- [HAL_DMA]:Half transfer complete\nTransfer complete\nError

[HAL_XSPI] --> [CMSIS]:XSPI register def

[HAL_DMA] <-d- [DMA Interrupt routine service]

[STM32_HW] -u--> [XSPI Interrupt routine service]: XSPIx Irq

[STM32_HW] -u--> [DMA Interrupt routine service] : DMA Channel Irq

[STM32_HW] <-u--> [HAL_XSPI] : XSPI registers R/W

@enduml

Configuration table

The following table lists the configuration defines for the HAL XSPI module, specifying their locations, default values, and descriptions:

group XSPI_Configuration_Table

Configuration inside the XSPI driver

Config defines

Description

Default value

Note

PRODUCT

from IDE

NA

The selected device (Ex: STM32U5XX)

USE_HAL_XSPI_MODULE

from hal_conf.h

1

Allows to use HAL XSPI module

USE_ASSERT_DBG_PARAM

from IDE

NA

Allows to use the assert check parameters

USE_ASSERT_DBG_STATE

from IDE

NA

Allows to use the assert check states

USE_HAL_CHECK_PARAM

from hal_conf.h

0

Allows to use the run-time checks parameters

USE_HAL_CHECK_PROCESS_STATE

from hal_conf.h

0

Allows to use the load and store exclusive

USE_HAL_XSPI_DMA

from hal_conf.h

1

Allows to use DMA mode

USE_HAL_XSPI_HYPERBUS

from hal_conf.h

1

Allows to use HYPERBUS protocol

USE_HAL_XSPI_OTFDEC

from hal_conf.h

0

Allows to use OTFDEC peripheral

USE_HAL_SECURE_CHECK_PARAM

from hal_conf.h

0

Parameters run-time check for sensitive APIs

USE_HAL_XSPI_REGISTER_CALLBACKS

from hal_conf.h

0

Allows to use register callbacks

USE_HAL_XSPI_CLK_ENABLE_MODEL

from hal_conf.h

HAL_CLK_ENABLE_NO

Allows to use the clock enable model