pub struct Rng {
    pub regs: RNG,
}
Expand description

Represents a RNG peripheral.

Fields

regs: RNG

Implementations

Initialize a RNG peripheral, including configuration register writes, and enabling and resetting its RCC peripheral clock.

Load a random number from the data register

Return true if a reading is available.

Enable an interrupt. An interrupt isgenerated when a random number is ready or when an error occurs. Therefore at each interrupt, check that: No error occured (SEIS and CEIS bits should be set to 0 in the RNG_SR register. A random number is ready. The DRDY bit must be set to 1 in the RNG_SR register.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.