STM32H735xx HAL User Manual
Functions
Initialization and de-initialization functions
CRYP Exported Functions

CRYP Initialization and Configuration functions. More...

Functions

HAL_StatusTypeDef HAL_CRYP_Init (CRYP_HandleTypeDef *hcryp)
 Initializes the CRYP according to the specified parameters in the CRYP_ConfigTypeDef and creates the associated handle.
HAL_StatusTypeDef HAL_CRYP_DeInit (CRYP_HandleTypeDef *hcryp)
 De-Initializes the CRYP peripheral.
HAL_StatusTypeDef HAL_CRYP_SetConfig (CRYP_HandleTypeDef *hcryp, CRYP_ConfigTypeDef *pConf)
 Configure the CRYP according to the specified parameters in the CRYP_ConfigTypeDef.
HAL_StatusTypeDef HAL_CRYP_GetConfig (CRYP_HandleTypeDef *hcryp, CRYP_ConfigTypeDef *pConf)
 Get CRYP Configuration parameters in associated handle.
__weak void HAL_CRYP_MspInit (CRYP_HandleTypeDef *hcryp)
 Initializes the CRYP MSP.
__weak void HAL_CRYP_MspDeInit (CRYP_HandleTypeDef *hcryp)
 DeInitializes CRYP MSP.
HAL_StatusTypeDef HAL_CRYP_RegisterCallback (CRYP_HandleTypeDef *hcryp, HAL_CRYP_CallbackIDTypeDef CallbackID, pCRYP_CallbackTypeDef pCallback)
 Register a User CRYP Callback To be used instead of the weak predefined callback.
HAL_StatusTypeDef HAL_CRYP_UnRegisterCallback (CRYP_HandleTypeDef *hcryp, HAL_CRYP_CallbackIDTypeDef CallbackID)
 Unregister an CRYP Callback CRYP callabck is redirected to the weak predefined callback.

Detailed Description

CRYP Initialization and Configuration functions.

  ========================================================================================
     ##### Initialization, de-initialization and Set and Get configuration functions #####
  ========================================================================================
    [..]  This section provides functions allowing to:
      (+) Initialize the CRYP
      (+) DeInitialize the CRYP
      (+) Initialize the CRYP MSP
      (+) DeInitialize the CRYP MSP
      (+) configure CRYP (HAL_CRYP_SetConfig) with the specified parameters in the CRYP_ConfigTypeDef
          Parameters which are configured in This section are :
          (++) Key size
          (++) Data Type : 32,16, 8 or 1bit
          (++) AlgoMode : for CRYP1 IP
                 ECB and CBC in DES/TDES Standard
                 ECB,CBC,CTR,GCM/GMAC and CCM in AES Standard.
      (+) Get CRYP configuration (HAL_CRYP_GetConfig) from the specified parameters in the CRYP_HandleTypeDef



Function Documentation

HAL_StatusTypeDef HAL_CRYP_DeInit ( CRYP_HandleTypeDef hcryp)

De-Initializes the CRYP peripheral.

Parameters:
hcryp,:pointer to a CRYP_HandleTypeDef structure that contains the configuration information for CRYP module
Return values:
HALstatus

Definition at line 485 of file stm32h7xx_hal_cryp.c.

References __HAL_CRYP_DISABLE, CRYP_PHASE_READY, __CRYP_HandleTypeDef::CrypHeaderCount, __CRYP_HandleTypeDef::CrypInCount, __CRYP_HandleTypeDef::CrypOutCount, HAL_CRYP_MspDeInit(), HAL_CRYP_STATE_RESET, __CRYP_HandleTypeDef::MspDeInitCallback, __CRYP_HandleTypeDef::Phase, and __CRYP_HandleTypeDef::State.

HAL_StatusTypeDef HAL_CRYP_GetConfig ( CRYP_HandleTypeDef hcryp,
CRYP_ConfigTypeDef pConf 
)

Get CRYP Configuration parameters in associated handle.

Parameters:
pConf,:pointer to a CRYP_ConfigTypeDef structure
hcryp,:pointer to a CRYP_HandleTypeDef structure that contains the configuration information for CRYP module
Return values:
HALstatus

Definition at line 604 of file stm32h7xx_hal_cryp.c.

References CRYP_ConfigTypeDef::Algorithm, CRYP_ConfigTypeDef::B0, CRYP_ConfigTypeDef::DataType, CRYP_ConfigTypeDef::DataWidthUnit, __CRYP_HandleTypeDef::ErrorCode, HAL_CRYP_ERROR_BUSY, HAL_CRYP_STATE_BUSY, HAL_CRYP_STATE_READY, CRYP_ConfigTypeDef::Header, CRYP_ConfigTypeDef::HeaderSize, __CRYP_HandleTypeDef::Init, CRYP_ConfigTypeDef::KeySize, CRYP_ConfigTypeDef::pInitVect, CRYP_ConfigTypeDef::pKey, and __CRYP_HandleTypeDef::State.

HAL_StatusTypeDef HAL_CRYP_Init ( CRYP_HandleTypeDef hcryp)

DeInitializes CRYP MSP.

Parameters:
hcryp,:pointer to a CRYP_HandleTypeDef structure that contains the configuration information for CRYP module
Return values:
None

Definition at line 672 of file stm32h7xx_hal_cryp.c.

Referenced by HAL_CRYP_DeInit(), and HAL_CRYP_UnRegisterCallback().

Initializes the CRYP MSP.

Parameters:
hcryp,:pointer to a CRYP_HandleTypeDef structure that contains the configuration information for CRYP module
Return values:
None

Definition at line 656 of file stm32h7xx_hal_cryp.c.

Referenced by HAL_CRYP_Init(), and HAL_CRYP_UnRegisterCallback().

HAL_StatusTypeDef HAL_CRYP_RegisterCallback ( CRYP_HandleTypeDef hcryp,
HAL_CRYP_CallbackIDTypeDef  CallbackID,
pCRYP_CallbackTypeDef  pCallback 
)

Register a User CRYP Callback To be used instead of the weak predefined callback.

Parameters:
hcrypcryp handle
CallbackIDID of the callback to be registered This parameter can be one of the following values:
pCallbackpointer to the Callback function
Return values:
status

Definition at line 697 of file stm32h7xx_hal_cryp.c.

References __CRYP_HandleTypeDef::ErrorCallback, __CRYP_HandleTypeDef::ErrorCode, HAL_CRYP_ERROR_CB_ID, HAL_CRYP_ERROR_INVALID_CALLBACK, HAL_CRYP_INPUT_COMPLETE_CB_ID, HAL_CRYP_MSPDEINIT_CB_ID, HAL_CRYP_MSPINIT_CB_ID, HAL_CRYP_OUTPUT_COMPLETE_CB_ID, HAL_CRYP_STATE_READY, HAL_CRYP_STATE_RESET, __CRYP_HandleTypeDef::InCpltCallback, __CRYP_HandleTypeDef::MspDeInitCallback, __CRYP_HandleTypeDef::MspInitCallback, __CRYP_HandleTypeDef::OutCpltCallback, and __CRYP_HandleTypeDef::State.

HAL_StatusTypeDef HAL_CRYP_SetConfig ( CRYP_HandleTypeDef hcryp,
CRYP_ConfigTypeDef pConf 
)
HAL_StatusTypeDef HAL_CRYP_UnRegisterCallback ( CRYP_HandleTypeDef hcryp,
HAL_CRYP_CallbackIDTypeDef  CallbackID 
)

Unregister an CRYP Callback CRYP callabck is redirected to the weak predefined callback.

Parameters:
hcrypcryp handle
CallbackIDID of the callback to be unregistered This parameter can be one of the following values:
Return values:
status

Definition at line 791 of file stm32h7xx_hal_cryp.c.

References __CRYP_HandleTypeDef::ErrorCallback, __CRYP_HandleTypeDef::ErrorCode, HAL_CRYP_ERROR_CB_ID, HAL_CRYP_ERROR_INVALID_CALLBACK, HAL_CRYP_ErrorCallback(), HAL_CRYP_InCpltCallback(), HAL_CRYP_INPUT_COMPLETE_CB_ID, HAL_CRYP_MspDeInit(), HAL_CRYP_MSPDEINIT_CB_ID, HAL_CRYP_MspInit(), HAL_CRYP_MSPINIT_CB_ID, HAL_CRYP_OutCpltCallback(), HAL_CRYP_OUTPUT_COMPLETE_CB_ID, HAL_CRYP_STATE_READY, HAL_CRYP_STATE_RESET, __CRYP_HandleTypeDef::InCpltCallback, __CRYP_HandleTypeDef::MspDeInitCallback, __CRYP_HandleTypeDef::MspInitCallback, __CRYP_HandleTypeDef::OutCpltCallback, and __CRYP_HandleTypeDef::State.