stm32-metapac

Crates

git

Versions

stm32h533re

Flavors

Struct stm32_metapac::flash::regs::Optsr

#[repr(transparent)]
pub struct Optsr(pub u32);
Expand description

FLASH option status register

Tuple Fields§

§0: u32

Implementations§

§

impl Optsr

pub const fn bor_lev(&self) -> OptsrBorLev

Brownout level option status bit These bits reflects the power level that generates a system reset. 00 or 11: BOR Level 1, the threshold level is low (around 2.1�V)

pub fn set_bor_lev(&mut self, val: OptsrBorLev)

Brownout level option status bit These bits reflects the power level that generates a system reset. 00 or 11: BOR Level 1, the threshold level is low (around 2.1�V)

pub const fn borh_en(&self) -> bool

Brownout high enable

pub fn set_borh_en(&mut self, val: bool)

Brownout high enable

pub const fn iwdg_sw(&self) -> OptsrIwdgSw

IWDG control mode option status bit

pub fn set_iwdg_sw(&mut self, val: OptsrIwdgSw)

IWDG control mode option status bit

pub const fn wwdg_sw(&self) -> OptsrWwdgSw

WWDG control mode option status bit

pub fn set_wwdg_sw(&mut self, val: OptsrWwdgSw)

WWDG control mode option status bit

pub const fn nrst_stop(&self) -> OptsrNrstStop

Core domain Stop entry reset option status bit

pub fn set_nrst_stop(&mut self, val: OptsrNrstStop)

Core domain Stop entry reset option status bit

pub const fn nrst_stdby(&self) -> OptsrNrstStdby

Core domain Standby entry reset option status bit

pub fn set_nrst_stdby(&mut self, val: OptsrNrstStdby)

Core domain Standby entry reset option status bit

pub const fn product_state(&self) -> u8

Life state code (based on Hamming 8,4). More information in Section�7.6.11: Product state transitions.

pub fn set_product_state(&mut self, val: u8)

Life state code (based on Hamming 8,4). More information in Section�7.6.11: Product state transitions.

pub const fn io_vdd_hslv(&self) -> OptsrIoVddHslv

High-speed IO at low VDD voltage configuration bit. This bit can be set only with VDD below 2.7�V.

pub fn set_io_vdd_hslv(&mut self, val: OptsrIoVddHslv)

High-speed IO at low VDD voltage configuration bit. This bit can be set only with VDD below 2.7�V.

pub const fn io_vddio2_hslv(&self) -> OptsrIoVddioHslv

High-speed IO at low VDDIO2 voltage configuration bit. This bit can be set only with VDDIO2 below 2.7�V.

pub fn set_io_vddio2_hslv(&mut self, val: OptsrIoVddioHslv)

High-speed IO at low VDDIO2 voltage configuration bit. This bit can be set only with VDDIO2 below 2.7�V.

pub const fn iwdg_stop(&self) -> OptsrIwdgStop

IWDG Stop mode freeze option status bit When set the independent watchdog IWDG is in system Stop mode.

pub fn set_iwdg_stop(&mut self, val: OptsrIwdgStop)

IWDG Stop mode freeze option status bit When set the independent watchdog IWDG is in system Stop mode.

pub const fn iwdg_stdby(&self) -> OptsrIwdgStdby

IWDG Standby mode freeze option status bit When set the independent watchdog IWDG is frozen in system Standby mode.

pub fn set_iwdg_stdby(&mut self, val: OptsrIwdgStdby)

IWDG Standby mode freeze option status bit When set the independent watchdog IWDG is frozen in system Standby mode.

pub const fn boot_ube(&self) -> OptsrBootUbe

Available only on cryptography enabled devices. Unique boot entry control, selects either ST or OEM iRoT for secure boot.

pub fn set_boot_ube(&mut self, val: OptsrBootUbe)

Available only on cryptography enabled devices. Unique boot entry control, selects either ST or OEM iRoT for secure boot.

pub const fn swap_bank(&self) -> OptsrSwapBank

Bank swapping option status bit SWAP_BANK reflects whether Bank1 and Bank2 are swapped or not. SWAP_BANK is loaded to SWAP_BANK of FLASH_OPTCR after a reset.

pub fn set_swap_bank(&mut self, val: OptsrSwapBank)

Bank swapping option status bit SWAP_BANK reflects whether Bank1 and Bank2 are swapped or not. SWAP_BANK is loaded to SWAP_BANK of FLASH_OPTCR after a reset.

Trait Implementations§

§

impl Clone for Optsr

§

fn clone(&self) -> Optsr

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
§

impl Default for Optsr

§

fn default() -> Optsr

Returns the “default value” for a type. Read more
§

impl PartialEq for Optsr

§

fn eq(&self, other: &Optsr) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
§

impl Copy for Optsr

§

impl Eq for Optsr

§

impl StructuralPartialEq for Optsr

Auto Trait Implementations§

§

impl Freeze for Optsr

§

impl RefUnwindSafe for Optsr

§

impl Send for Optsr

§

impl Sync for Optsr

§

impl Unpin for Optsr

§

impl UnwindSafe for Optsr

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> CloneToUninit for T
where T: Clone,

source§

unsafe fn clone_to_uninit(&self, dst: *mut T)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dst. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

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

source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

source§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.