Initialization, configuration and call-back functions.
More...
Initialization, configuration and call-back functions.
===============================================================================
##### Initialization and de-initialization functions #####
===============================================================================
[..] This section provides functions allowing to:
(+) Initialize the HASH according to the specified parameters
in the HASH_InitTypeDef and create the associated handle
(+) DeInitialize the HASH peripheral
(+) Initialize the HASH MCU Specific Package (MSP)
(+) DeInitialize the HASH MSP
[..] This section provides as well call back functions definitions for user
code to manage:
(+) Input data transfer to Peripheral completion
(+) Calculated digest retrieval completion
(+) Error management
◆ HAL_HASH_DeInit()
◆ HAL_HASH_DgstCpltCallback()
◆ HAL_HASH_ErrorCallback()
Error callback.
- Note
- Code user can resort to hhash->Status (HAL_ERROR, HAL_TIMEOUT,...) to retrieve the error type.
- Parameters
-
- Return values
-
Definition at line 534 of file stm32f4xx_hal_hash.c.
◆ HAL_HASH_InCpltCallback()
Input data transfer complete call back.
- Note
- HAL_HASH_InCpltCallback() is called when the complete input message has been fed to the Peripheral. This API is invoked only when input data are entered under interruption or through DMA.
-
In case of HASH or HMAC multi-buffer DMA feeding case (MDMAT bit set), HAL_HASH_InCpltCallback() is called at the end of each buffer feeding to the Peripheral.
- Parameters
-
- Return values
-
Definition at line 500 of file stm32f4xx_hal_hash.c.
◆ HAL_HASH_Init()
Initialize the HASH according to the specified parameters in the HASH_HandleTypeDef and create the associated handle.
- Note
- Only MDMAT and DATATYPE bits of HASH Peripheral are set by HAL_HASH_Init(), other configuration bits are set by HASH or HMAC processing APIs.
-
MDMAT bit is systematically reset by HAL_HASH_Init(). To set it for multi-buffer HASH processing, user needs to resort to __HAL_HASH_SET_MDMAT() macro. For HMAC multi-buffer processing, the relevant APIs manage themselves the MDMAT bit.
- Parameters
-
- Return values
-
Definition at line 328 of file stm32f4xx_hal_hash.c.
◆ HAL_HASH_MspDeInit()
◆ HAL_HASH_MspInit()
◆ HAL_HASH_RegisterCallback()
Register a User HASH Callback To be used instead of the weak (surcharged) predefined callback.
- Parameters
-
hhash | HASH handle |
CallbackID | ID of the callback to be registered This parameter can be one of the following values:
|
pCallback | pointer to the Callback function |
- Return values
-
Definition at line 559 of file stm32f4xx_hal_hash.c.
◆ HAL_HASH_UnRegisterCallback()
Unregister a HASH Callback HASH Callback is redirected to the weak (surcharged) predefined callback.
- Parameters
-
hhash | HASH handle |
CallbackID | ID of the callback to be unregistered This parameter can be one of the following values:
|
- Return values
-
Definition at line 651 of file stm32f4xx_hal_hash.c.