Libraries/STM32F4xx_StdPeriph_Driver/src/stm32f4xx_rng.c File Reference

This file provides firmware functions to manage the following functionalities of the Random Number Generator (RNG) peripheral:

More...

#include "stm32f4xx_rng.h"
#include "stm32f4xx_rcc.h"

Functions

void RNG_DeInit (void)
 Deinitializes the RNG peripheral registers to their default reset values.
void RNG_Cmd (FunctionalState NewState)
 Enables or disables the RNG peripheral.
uint32_t RNG_GetRandomNumber (void)
 Returns a 32-bit random number.
void RNG_ITConfig (FunctionalState NewState)
 Enables or disables the RNG interrupt.
FlagStatus RNG_GetFlagStatus (uint8_t RNG_FLAG)
 Checks whether the specified RNG flag is set or not.
void RNG_ClearFlag (uint8_t RNG_FLAG)
 Clears the RNG flags.
ITStatus RNG_GetITStatus (uint8_t RNG_IT)
 Checks whether the specified RNG interrupt has occurred or not.
void RNG_ClearITPendingBit (uint8_t RNG_IT)
 Clears the RNG interrupt pending bit(s).

Detailed Description

This file provides firmware functions to manage the following functionalities of the Random Number Generator (RNG) peripheral:

Author:
MCD Application Team
Version:
V1.0.2
Date:
05-March-2012
  *                               
  *          ===================================================================      
  *                                   How to use this driver
  *          ===================================================================          
  *          1. Enable The RNG controller clock using 
  *            RCC_AHB2PeriphClockCmd(RCC_AHB2Periph_RNG, ENABLE) function.
  *              
  *          2. Activate the RNG peripheral using RNG_Cmd() function.
  *          
  *          3. Wait until the 32 bit Random number Generator contains a valid 
  *            random data (using polling/interrupt mode). For more details, 
  *            refer to "Interrupts and flags management functions" module 
  *            description.
  *           
  *          4. Get the 32 bit Random number using RNG_GetRandomNumber() function
  *          
  *          5. To get another 32 bit Random number, go to step 3.       
  *
  *         
  *              
  *  
Attention:

© COPYRIGHT 2012 STMicroelectronics

Licensed under MCD-ST Liberty SW License Agreement V2, (the "License"); You may not use this file except in compliance with the License. You may obtain a copy of the License at:

http://www.st.com/software_license_agreement_liberty_v2

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Generated on Fri Jun 22 00:58:29 2012 for STM32F4xx_StdPeriph_Driver by  doxygen 1.6.3