|
| 1 | +/* USER CODE BEGIN Header */ |
| 2 | +/** |
| 3 | + ****************************************************************************** |
| 4 | + * @file : stm32_extmem_conf.h |
| 5 | + * @version : 1.0.0 |
| 6 | + * @brief : Header for extmem.c file. |
| 7 | + ****************************************************************************** |
| 8 | + * @attention |
| 9 | + * |
| 10 | + * Copyright (c) 2025 STMicroelectronics. |
| 11 | + * All rights reserved. |
| 12 | + * |
| 13 | + * This software is licensed under terms that can be found in the LICENSE file |
| 14 | + * in the root directory of this software component. |
| 15 | + * If no LICENSE file comes with this software, it is provided AS-IS. |
| 16 | + * |
| 17 | + ****************************************************************************** |
| 18 | + */ |
| 19 | +/* USER CODE END Header */ |
| 20 | + |
| 21 | +/* Define to prevent recursive inclusion -------------------------------------*/ |
| 22 | +#ifndef __STM32_EXTMEM_CONF__H__ |
| 23 | +#define __STM32_EXTMEM_CONF__H__ |
| 24 | + |
| 25 | +#ifdef __cplusplus |
| 26 | +extern "C" { |
| 27 | +#endif |
| 28 | + |
| 29 | +/* Includes ------------------------------------------------------------------*/ |
| 30 | + |
| 31 | +/* |
| 32 | + @brief management of the driver layer enable |
| 33 | +*/ |
| 34 | + |
| 35 | +#define EXTMEM_DRIVER_NOR_SFDP 1 |
| 36 | +#define EXTMEM_DRIVER_PSRAM 0 |
| 37 | +#define EXTMEM_DRIVER_SDCARD 0 |
| 38 | +#define EXTMEM_DRIVER_USER 0 |
| 39 | + |
| 40 | +/* |
| 41 | + @brief management of the sal layer enable |
| 42 | +*/ |
| 43 | +#define EXTMEM_SAL_XSPI 1 |
| 44 | +#define EXTMEM_SAL_SD 0 |
| 45 | + |
| 46 | +/* Includes ------------------------------------------------------------------*/ |
| 47 | +#include "stm32n6xx_hal.h" |
| 48 | + |
| 49 | +#include "stm32_extmem_type.h" |
| 50 | +#include "boot/stm32_boot_lrun.h" |
| 51 | + |
| 52 | +/* USER CODE BEGIN INCLUDE */ |
| 53 | + |
| 54 | +/* USER CODE END INCLUDE */ |
| 55 | +/* Private variables ---------------------------------------------------------*/ |
| 56 | +extern XSPI_HandleTypeDef hxspi2; |
| 57 | + |
| 58 | +/* USER CODE BEGIN PV */ |
| 59 | + |
| 60 | +/* USER CODE END PV */ |
| 61 | + |
| 62 | +/* Exported constants --------------------------------------------------------*/ |
| 63 | +/** @defgroup EXTMEM_CONF_Exported_constants EXTMEM_CONF exported constants |
| 64 | + * @{ |
| 65 | + */ |
| 66 | +enum { |
| 67 | + EXTMEMORY_1 = 0 /*!< ID=0 for the first memory */ |
| 68 | +}; |
| 69 | + |
| 70 | +/* |
| 71 | + @brief management of the boot layer |
| 72 | +*/ |
| 73 | + |
| 74 | +#define EXTMEM_LRUN_SOURCE EXTMEMORY_1 |
| 75 | +#define EXTMEM_LRUN_SOURCE_ADDRESS 0x00100000u |
| 76 | +#define EXTMEM_LRUN_SOURCE_SIZE 0x10000u |
| 77 | +#define EXTMEM_LRUN_DESTINATION_INTERNAL 1 |
| 78 | +#define EXTMEM_LRUN_DESTINATION_ADDRESS 0x34000000u |
| 79 | + |
| 80 | +/* USER CODE BEGIN PV */ |
| 81 | + |
| 82 | +/* USER CODE END PV */ |
| 83 | + |
| 84 | +/* Exported configuration --------------------------------------------------------*/ |
| 85 | +/** @defgroup EXTMEM_CONF_Exported_configuration EXTMEM_CONF exported configuration definition |
| 86 | + * @{ |
| 87 | + */ |
| 88 | + |
| 89 | +extern EXTMEM_DefinitionTypeDef extmem_list_config[1]; |
| 90 | +#if defined(EXTMEM_C) |
| 91 | +EXTMEM_DefinitionTypeDef extmem_list_config[1]; |
| 92 | +#endif /* EXTMEM_C */ |
| 93 | + |
| 94 | +/** |
| 95 | + * @} |
| 96 | + */ |
| 97 | + |
| 98 | +/* Private function prototypes -----------------------------------------------*/ |
| 99 | +/* USER CODE BEGIN PFP */ |
| 100 | + |
| 101 | +/* USER CODE END PFP */ |
| 102 | + |
| 103 | +/* |
| 104 | + * -- Insert your variables declaration here -- |
| 105 | + */ |
| 106 | +/* USER CODE BEGIN VARIABLES */ |
| 107 | + |
| 108 | +/* USER CODE END VARIABLES */ |
| 109 | + |
| 110 | +/* |
| 111 | + * -- Insert functions declaration here -- |
| 112 | + */ |
| 113 | +/* USER CODE BEGIN FD */ |
| 114 | + |
| 115 | +/* USER CODE END FD */ |
| 116 | + |
| 117 | +#ifdef __cplusplus |
| 118 | +} |
| 119 | +#endif |
| 120 | + |
| 121 | +#endif /* __STM32_EXTMEM_CONF__H__ */ |
0 commit comments