stm32f7xx_hal_sram.h
Go to the documentation of this file.
1 
20 /* Define to prevent recursive inclusion -------------------------------------*/
21 #ifndef __STM32F7xx_HAL_SRAM_H
22 #define __STM32F7xx_HAL_SRAM_H
23 
24 #ifdef __cplusplus
25  extern "C" {
26 #endif
27 
28 /* Includes ------------------------------------------------------------------*/
29 #include "stm32f7xx_ll_fmc.h"
30 
38 /* Exported typedef ----------------------------------------------------------*/
39 
46 typedef enum
47 {
55 
59 #if (USE_HAL_SRAM_REGISTER_CALLBACKS == 1)
60 typedef struct __SRAM_HandleTypeDef
61 #else
62 typedef struct
63 #endif /* USE_HAL_SRAM_REGISTER_CALLBACKS */
64 {
77 #if (USE_HAL_SRAM_REGISTER_CALLBACKS == 1)
78  void (* MspInitCallback) ( struct __SRAM_HandleTypeDef * hsram);
79  void (* MspDeInitCallback) ( struct __SRAM_HandleTypeDef * hsram);
80  void (* DmaXferCpltCallback) ( DMA_HandleTypeDef * hdma);
81  void (* DmaXferErrorCallback) ( DMA_HandleTypeDef * hdma);
82 #endif
84 
85 #if (USE_HAL_SRAM_REGISTER_CALLBACKS == 1)
86 
89 typedef enum
90 {
91  HAL_SRAM_MSP_INIT_CB_ID = 0x00U,
92  HAL_SRAM_MSP_DEINIT_CB_ID = 0x01U,
93  HAL_SRAM_DMA_XFER_CPLT_CB_ID = 0x02U,
94  HAL_SRAM_DMA_XFER_ERR_CB_ID = 0x03U
95 }HAL_SRAM_CallbackIDTypeDef;
96 
100 typedef void (*pSRAM_CallbackTypeDef)(SRAM_HandleTypeDef *hsram);
101 typedef void (*pSRAM_DmaCallbackTypeDef)(DMA_HandleTypeDef *hdma);
102 #endif
103 
107 /* Exported constants --------------------------------------------------------*/
108 /* Exported macro ------------------------------------------------------------*/
109 
118 #if (USE_HAL_SRAM_REGISTER_CALLBACKS == 1)
119 #define __HAL_SRAM_RESET_HANDLE_STATE(__HANDLE__) do { \
120  (__HANDLE__)->State = HAL_SRAM_STATE_RESET; \
121  (__HANDLE__)->MspInitCallback = NULL; \
122  (__HANDLE__)->MspDeInitCallback = NULL; \
123  } while(0)
124 #else
125 #define __HAL_SRAM_RESET_HANDLE_STATE(__HANDLE__) ((__HANDLE__)->State = HAL_SRAM_STATE_RESET)
126 #endif
127 
132 /* Exported functions --------------------------------------------------------*/
141 /* Initialization/de-initialization functions ********************************/
146 
155 /* I/O operation functions ***************************************************/
156 HAL_StatusTypeDef HAL_SRAM_Read_8b(SRAM_HandleTypeDef *hsram, uint32_t *pAddress, uint8_t *pDstBuffer, uint32_t BufferSize);
157 HAL_StatusTypeDef HAL_SRAM_Write_8b(SRAM_HandleTypeDef *hsram, uint32_t *pAddress, uint8_t *pSrcBuffer, uint32_t BufferSize);
158 HAL_StatusTypeDef HAL_SRAM_Read_16b(SRAM_HandleTypeDef *hsram, uint32_t *pAddress, uint16_t *pDstBuffer, uint32_t BufferSize);
159 HAL_StatusTypeDef HAL_SRAM_Write_16b(SRAM_HandleTypeDef *hsram, uint32_t *pAddress, uint16_t *pSrcBuffer, uint32_t BufferSize);
160 HAL_StatusTypeDef HAL_SRAM_Read_32b(SRAM_HandleTypeDef *hsram, uint32_t *pAddress, uint32_t *pDstBuffer, uint32_t BufferSize);
161 HAL_StatusTypeDef HAL_SRAM_Write_32b(SRAM_HandleTypeDef *hsram, uint32_t *pAddress, uint32_t *pSrcBuffer, uint32_t BufferSize);
162 HAL_StatusTypeDef HAL_SRAM_Read_DMA(SRAM_HandleTypeDef *hsram, uint32_t *pAddress, uint32_t *pDstBuffer, uint32_t BufferSize);
163 HAL_StatusTypeDef HAL_SRAM_Write_DMA(SRAM_HandleTypeDef *hsram, uint32_t *pAddress, uint32_t *pSrcBuffer, uint32_t BufferSize);
164 
167 
168 #if (USE_HAL_SRAM_REGISTER_CALLBACKS == 1)
169 /* SRAM callback registering/unregistering */
170 HAL_StatusTypeDef HAL_SRAM_RegisterCallback(SRAM_HandleTypeDef *hsram, HAL_SRAM_CallbackIDTypeDef CallbackId, pSRAM_CallbackTypeDef pCallback);
171 HAL_StatusTypeDef HAL_SRAM_UnRegisterCallback(SRAM_HandleTypeDef *hsram, HAL_SRAM_CallbackIDTypeDef CallbackId);
172 HAL_StatusTypeDef HAL_SRAM_RegisterDmaCallback(SRAM_HandleTypeDef *hsram, HAL_SRAM_CallbackIDTypeDef CallbackId, pSRAM_DmaCallbackTypeDef pCallback);
173 #endif
174 
183 /* SRAM Control functions ****************************************************/
186 
195 /* SRAM State functions ******************************************************/
197 
214 #ifdef __cplusplus
215 }
216 #endif
217 
218 #endif /* __STM32F7xx_HAL_SRAM_H */
219 
220 /************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/
HAL_SRAM_MspInit
void HAL_SRAM_MspInit(SRAM_HandleTypeDef *hsram)
__IO
#define __IO
Definition: imxrt1050/imxrt1050-evkb/CMSIS/core_cm7.h:237
HAL_StatusTypeDef
HAL_StatusTypeDef
HAL Status structures definition
Definition: stm32f407/stm32f407g-disc1/Drivers/STM32F4xx_HAL_Driver/Inc/stm32f4xx_hal_def.h:40
HAL_SRAM_Read_32b
HAL_StatusTypeDef HAL_SRAM_Read_32b(SRAM_HandleTypeDef *hsram, uint32_t *pAddress, uint32_t *pDstBuffer, uint32_t BufferSize)
Timing
static FMC_SDRAM_TimingTypeDef Timing
Definition: stm32f769i_discovery_sdram.c:124
HAL_SRAM_DMA_XferCpltCallback
void HAL_SRAM_DMA_XferCpltCallback(DMA_HandleTypeDef *hdma)
__DMA_HandleTypeDef
DMA handle Structure definition.
Definition: stm32f407/stm32f407g-disc1/Drivers/STM32F4xx_HAL_Driver/Inc/stm32f4xx_hal_dma.h:139
HAL_SRAM_Read_16b
HAL_StatusTypeDef HAL_SRAM_Read_16b(SRAM_HandleTypeDef *hsram, uint32_t *pAddress, uint16_t *pDstBuffer, uint32_t BufferSize)
HAL_SRAM_Init
HAL_StatusTypeDef HAL_SRAM_Init(SRAM_HandleTypeDef *hsram, FMC_NORSRAM_TimingTypeDef *Timing, FMC_NORSRAM_TimingTypeDef *ExtTiming)
HAL_SRAM_StateTypeDef
HAL_SRAM_StateTypeDef
HAL SRAM State structures definition
Definition: stm32f7xx_hal_sram.h:46
HAL_SRAM_STATE_READY
@ HAL_SRAM_STATE_READY
Definition: stm32f7xx_hal_sram.h:49
HAL_LockTypeDef
HAL_LockTypeDef
HAL Lock structures definition
Definition: stm32f407/stm32f407g-disc1/Drivers/STM32F4xx_HAL_Driver/Inc/stm32f4xx_hal_def.h:51
FMC_NORSRAM_TypeDef
#define FMC_NORSRAM_TypeDef
Definition: stm32f7xx_ll_fmc.h:383
HAL_SRAM_MspDeInit
void HAL_SRAM_MspDeInit(SRAM_HandleTypeDef *hsram)
FMC_NORSRAM_TimingTypeDef
FMC NORSRAM Timing parameters structure definition
Definition: stm32f7xx_ll_fmc.h:460
HAL_SRAM_Write_16b
HAL_StatusTypeDef HAL_SRAM_Write_16b(SRAM_HandleTypeDef *hsram, uint32_t *pAddress, uint16_t *pSrcBuffer, uint32_t BufferSize)
SRAM_HandleTypeDef::Init
FMC_NORSRAM_InitTypeDef Init
Definition: stm32f7xx_hal_sram.h:69
SRAM_HandleTypeDef::Lock
HAL_LockTypeDef Lock
Definition: stm32f7xx_hal_sram.h:71
HAL_SRAM_GetState
HAL_SRAM_StateTypeDef HAL_SRAM_GetState(SRAM_HandleTypeDef *hsram)
HAL_SRAM_WriteOperation_Disable
HAL_StatusTypeDef HAL_SRAM_WriteOperation_Disable(SRAM_HandleTypeDef *hsram)
HAL_SRAM_DMA_XferErrorCallback
void HAL_SRAM_DMA_XferErrorCallback(DMA_HandleTypeDef *hdma)
HAL_SRAM_Write_8b
HAL_StatusTypeDef HAL_SRAM_Write_8b(SRAM_HandleTypeDef *hsram, uint32_t *pAddress, uint8_t *pSrcBuffer, uint32_t BufferSize)
SRAM_HandleTypeDef::State
__IO HAL_SRAM_StateTypeDef State
Definition: stm32f7xx_hal_sram.h:73
SRAM_HandleTypeDef::Instance
FMC_NORSRAM_TypeDef * Instance
Definition: stm32f7xx_hal_sram.h:65
SRAM_HandleTypeDef::Extended
FMC_NORSRAM_EXTENDED_TypeDef * Extended
Definition: stm32f7xx_hal_sram.h:67
SRAM_HandleTypeDef
SRAM handle Structure definition.
Definition: stm32f7xx_hal_sram.h:62
HAL_SRAM_Read_8b
HAL_StatusTypeDef HAL_SRAM_Read_8b(SRAM_HandleTypeDef *hsram, uint32_t *pAddress, uint8_t *pDstBuffer, uint32_t BufferSize)
HAL_SRAM_STATE_RESET
@ HAL_SRAM_STATE_RESET
Definition: stm32f7xx_hal_sram.h:48
HAL_SRAM_Write_DMA
HAL_StatusTypeDef HAL_SRAM_Write_DMA(SRAM_HandleTypeDef *hsram, uint32_t *pAddress, uint32_t *pSrcBuffer, uint32_t BufferSize)
HAL_SRAM_STATE_BUSY
@ HAL_SRAM_STATE_BUSY
Definition: stm32f7xx_hal_sram.h:50
HAL_SRAM_STATE_PROTECTED
@ HAL_SRAM_STATE_PROTECTED
Definition: stm32f7xx_hal_sram.h:52
FMC_NORSRAM_InitTypeDef
FMC NORSRAM Configuration Structure definition.
Definition: stm32f7xx_ll_fmc.h:396
stm32f7xx_ll_fmc.h
Header file of FMC HAL module.
FMC_NORSRAM_EXTENDED_TypeDef
#define FMC_NORSRAM_EXTENDED_TypeDef
Definition: stm32f7xx_ll_fmc.h:384
HAL_SRAM_Read_DMA
HAL_StatusTypeDef HAL_SRAM_Read_DMA(SRAM_HandleTypeDef *hsram, uint32_t *pAddress, uint32_t *pDstBuffer, uint32_t BufferSize)
SRAM_HandleTypeDef::hdma
DMA_HandleTypeDef * hdma
Definition: stm32f7xx_hal_sram.h:75
HAL_SRAM_Write_32b
HAL_StatusTypeDef HAL_SRAM_Write_32b(SRAM_HandleTypeDef *hsram, uint32_t *pAddress, uint32_t *pSrcBuffer, uint32_t BufferSize)
HAL_SRAM_WriteOperation_Enable
HAL_StatusTypeDef HAL_SRAM_WriteOperation_Enable(SRAM_HandleTypeDef *hsram)
HAL_SRAM_DeInit
HAL_StatusTypeDef HAL_SRAM_DeInit(SRAM_HandleTypeDef *hsram)
HAL_SRAM_STATE_ERROR
@ HAL_SRAM_STATE_ERROR
Definition: stm32f7xx_hal_sram.h:51


picovoice_driver
Author(s):
autogenerated on Fri Apr 1 2022 02:14:53