STM32H735xx HAL User Manual
|
Header file of RNG HAL module. More...
Go to the source code of this file.
Data Structures | |
struct | RNG_InitTypeDef |
struct | __RNG_HandleTypeDef |
Defines | |
#define | RNG_IT_DRDY RNG_SR_DRDY |
#define | RNG_IT_CEI RNG_SR_CEIS |
#define | RNG_IT_SEI RNG_SR_SEIS |
#define | RNG_FLAG_DRDY RNG_SR_DRDY |
#define | RNG_FLAG_CECS RNG_SR_CECS |
#define | RNG_FLAG_SECS RNG_SR_SECS |
#define | RNG_CED_ENABLE 0x00000000U |
#define | RNG_CED_DISABLE RNG_CR_CED |
#define | HAL_RNG_ERROR_NONE 0x00000000U |
#define | HAL_RNG_ERROR_INVALID_CALLBACK 0x00000001U |
#define | HAL_RNG_ERROR_TIMEOUT 0x00000002U |
#define | HAL_RNG_ERROR_BUSY 0x00000004U |
#define | HAL_RNG_ERROR_SEED 0x00000008U |
#define | HAL_RNG_ERROR_CLOCK 0x00000010U |
#define | __HAL_RNG_RESET_HANDLE_STATE(__HANDLE__) |
Reset RNG handle state. | |
#define | __HAL_RNG_ENABLE(__HANDLE__) ((__HANDLE__)->Instance->CR |= RNG_CR_RNGEN) |
Enables the RNG peripheral. | |
#define | __HAL_RNG_DISABLE(__HANDLE__) ((__HANDLE__)->Instance->CR &= ~RNG_CR_RNGEN) |
Disables the RNG peripheral. | |
#define | __HAL_RNG_GET_FLAG(__HANDLE__, __FLAG__) (((__HANDLE__)->Instance->SR & (__FLAG__)) == (__FLAG__)) |
Check the selected RNG flag status. | |
#define | __HAL_RNG_CLEAR_FLAG(__HANDLE__, __FLAG__) /* dummy macro */ |
Clears the selected RNG flag status. | |
#define | __HAL_RNG_ENABLE_IT(__HANDLE__) ((__HANDLE__)->Instance->CR |= RNG_CR_IE) |
Enables the RNG interrupts. | |
#define | __HAL_RNG_DISABLE_IT(__HANDLE__) ((__HANDLE__)->Instance->CR &= ~RNG_CR_IE) |
Disables the RNG interrupts. | |
#define | __HAL_RNG_GET_IT(__HANDLE__, __INTERRUPT__) (((__HANDLE__)->Instance->SR & (__INTERRUPT__)) == (__INTERRUPT__)) |
Checks whether the specified RNG interrupt has occurred or not. | |
#define | __HAL_RNG_CLEAR_IT(__HANDLE__, __INTERRUPT__) (((__HANDLE__)->Instance->SR) = ~(__INTERRUPT__)) |
Clear the RNG interrupt status flags. | |
#define | IS_RNG_IT(IT) |
#define | IS_RNG_FLAG(FLAG) |
#define | IS_RNG_CED(__MODE__) |
Verify the RNG Clock Error Detection mode. | |
Typedefs | |
typedef struct __RNG_HandleTypeDef | RNG_HandleTypeDef |
typedef void(* | pRNG_CallbackTypeDef )(RNG_HandleTypeDef *hrng) |
HAL RNG Callback pointer definition. | |
typedef void(* | pRNG_ReadyDataCallbackTypeDef )(RNG_HandleTypeDef *hrng, uint32_t random32bit) |
Enumerations | |
enum | HAL_RNG_StateTypeDef { HAL_RNG_STATE_RESET = 0x00U, HAL_RNG_STATE_READY = 0x01U, HAL_RNG_STATE_BUSY = 0x02U, HAL_RNG_STATE_TIMEOUT = 0x03U, HAL_RNG_STATE_ERROR = 0x04U } |
enum | HAL_RNG_CallbackIDTypeDef { HAL_RNG_ERROR_CB_ID = 0x00U, HAL_RNG_MSPINIT_CB_ID = 0x01U, HAL_RNG_MSPDEINIT_CB_ID = 0x02U } |
HAL RNG Callback ID enumeration definition. More... | |
Functions | |
HAL_StatusTypeDef | HAL_RNG_Init (RNG_HandleTypeDef *hrng) |
Initializes the RNG peripheral and creates the associated handle. | |
HAL_StatusTypeDef | HAL_RNG_DeInit (RNG_HandleTypeDef *hrng) |
DeInitializes the RNG peripheral. | |
__weak void | HAL_RNG_MspInit (RNG_HandleTypeDef *hrng) |
Initializes the RNG MSP. | |
__weak void | HAL_RNG_MspDeInit (RNG_HandleTypeDef *hrng) |
DeInitializes the RNG MSP. | |
HAL_StatusTypeDef | HAL_RNG_RegisterCallback (RNG_HandleTypeDef *hrng, HAL_RNG_CallbackIDTypeDef CallbackID, pRNG_CallbackTypeDef pCallback) |
Register a User RNG Callback To be used instead of the weak predefined callback. | |
HAL_StatusTypeDef | HAL_RNG_UnRegisterCallback (RNG_HandleTypeDef *hrng, HAL_RNG_CallbackIDTypeDef CallbackID) |
Unregister an RNG Callback RNG callabck is redirected to the weak predefined callback. | |
HAL_StatusTypeDef | HAL_RNG_RegisterReadyDataCallback (RNG_HandleTypeDef *hrng, pRNG_ReadyDataCallbackTypeDef pCallback) |
Register Data Ready RNG Callback To be used instead of the weak HAL_RNG_ReadyDataCallback() predefined callback. | |
HAL_StatusTypeDef | HAL_RNG_UnRegisterReadyDataCallback (RNG_HandleTypeDef *hrng) |
UnRegister the Data Ready RNG Callback Data Ready RNG Callback is redirected to the weak HAL_RNG_ReadyDataCallback() predefined callback. | |
HAL_StatusTypeDef | HAL_RNG_GenerateRandomNumber (RNG_HandleTypeDef *hrng, uint32_t *random32bit) |
Generates a 32-bit random number. | |
HAL_StatusTypeDef | HAL_RNG_GenerateRandomNumber_IT (RNG_HandleTypeDef *hrng) |
Generates a 32-bit random number in interrupt mode. | |
uint32_t | HAL_RNG_ReadLastRandomNumber (RNG_HandleTypeDef *hrng) |
Read latest generated random number. | |
void | HAL_RNG_IRQHandler (RNG_HandleTypeDef *hrng) |
Handles RNG interrupt request. | |
__weak void | HAL_RNG_ErrorCallback (RNG_HandleTypeDef *hrng) |
RNG error callbacks. | |
__weak void | HAL_RNG_ReadyDataCallback (RNG_HandleTypeDef *hrng, uint32_t random32bit) |
Data Ready callback in non-blocking mode. | |
HAL_RNG_StateTypeDef | HAL_RNG_GetState (RNG_HandleTypeDef *hrng) |
Returns the RNG state. | |
uint32_t | HAL_RNG_GetError (RNG_HandleTypeDef *hrng) |
Return the RNG handle error code. | |
HAL_StatusTypeDef | RNG_RecoverSeedError (RNG_HandleTypeDef *hrng) |
RNG sequence to recover from a seed error. |
Header file of RNG HAL module.
Copyright (c) 2017 STMicroelectronics. All rights reserved.
This software is licensed under terms that can be found in the LICENSE file in the root directory of this software component. If no LICENSE file comes with this software, it is provided AS-IS.
Definition in file stm32h7xx_hal_rng.h.