Struct stm32_metapac::tamp::regs::Seccfgr
#[repr(transparent)]pub struct Seccfgr(pub u32);
Expand description
TAMP secure mode register
Tuple Fields§
§0: u32
Implementations§
§impl Seccfgr
impl Seccfgr
pub const fn bkprwsec(&self) -> u8
pub const fn bkprwsec(&self) -> u8
Backup registers read/write protection offset. Protection zone 1 is defined for backup registers from BKP0R to BKPxR (x = BKPRWSEC-1, from 0 to 128). if TZEN=1, these backup registers can be read and written only with secure access. If TZEN=0: the protection zone 1 can be read and written with non-secure access. If BKPRWSEC = 0: there is no protection zone 1. If BKPRWPRIV is set, BKPRWSEC[7:0] can be written only in privileged mode.
pub fn set_bkprwsec(&mut self, val: u8)
pub fn set_bkprwsec(&mut self, val: u8)
Backup registers read/write protection offset. Protection zone 1 is defined for backup registers from BKP0R to BKPxR (x = BKPRWSEC-1, from 0 to 128). if TZEN=1, these backup registers can be read and written only with secure access. If TZEN=0: the protection zone 1 can be read and written with non-secure access. If BKPRWSEC = 0: there is no protection zone 1. If BKPRWPRIV is set, BKPRWSEC[7:0] can be written only in privileged mode.
pub fn set_cnt1sec(&mut self, val: bool)
pub fn set_cnt1sec(&mut self, val: bool)
Monotonic counter 1 secure protection
pub const fn bkpwsec(&self) -> u8
pub const fn bkpwsec(&self) -> u8
Backup registers write protection offset. Protection zone 2 is defined for backup registers from BKPyR (y = BKPRWSEC, from 0 to 128) to BKPzR (z = BKPWSEC-1, from 0 to 128, BKPWSECBKPRWSEC): if TZEN=1, these backup registers can be written only with secure access. They can be read with secure or non-secure access. Protection zone 3 defined for backup registers from BKPtR (t = BKPWSEC, from 0 to 127). They can be read or written with secure or non-secure access. If TZEN=0: the protection zone 2 can be read and written with non-secure access. If BKPWSEC = 0 or if BKPWSEC BKPRWSEC: there is no protection zone 2. If BKPWPRIV is set, BKPRWSEC[7:0] can be written only in privileged mode.
pub fn set_bkpwsec(&mut self, val: u8)
pub fn set_bkpwsec(&mut self, val: u8)
Backup registers write protection offset. Protection zone 2 is defined for backup registers from BKPyR (y = BKPRWSEC, from 0 to 128) to BKPzR (z = BKPWSEC-1, from 0 to 128, BKPWSECBKPRWSEC): if TZEN=1, these backup registers can be written only with secure access. They can be read with secure or non-secure access. Protection zone 3 defined for backup registers from BKPtR (t = BKPWSEC, from 0 to 127). They can be read or written with secure or non-secure access. If TZEN=0: the protection zone 2 can be read and written with non-secure access. If BKPWSEC = 0 or if BKPWSEC BKPRWSEC: there is no protection zone 2. If BKPWPRIV is set, BKPRWSEC[7:0] can be written only in privileged mode.
pub const fn bhklock(&self) -> bool
pub const fn bhklock(&self) -> bool
Boot hardware key lock. This bit can be read and can only be written to 1 by software. It is cleared by hardware together with the backup registers following a tamper detection event or when the readout protection (RDP) is disabled.
pub fn set_bhklock(&mut self, val: bool)
pub fn set_bhklock(&mut self, val: bool)
Boot hardware key lock. This bit can be read and can only be written to 1 by software. It is cleared by hardware together with the backup registers following a tamper detection event or when the readout protection (RDP) is disabled.
pub const fn tampsec(&self) -> bool
pub const fn tampsec(&self) -> bool
Tamper protection (excluding monotonic counters and backup registers). Note: Refer to for details on the read protection.
pub fn set_tampsec(&mut self, val: bool)
pub fn set_tampsec(&mut self, val: bool)
Tamper protection (excluding monotonic counters and backup registers). Note: Refer to for details on the read protection.
Trait Implementations§
impl Copy for Seccfgr
impl Eq for Seccfgr
impl StructuralPartialEq for Seccfgr
Auto Trait Implementations§
impl Freeze for Seccfgr
impl RefUnwindSafe for Seccfgr
impl Send for Seccfgr
impl Sync for Seccfgr
impl Unpin for Seccfgr
impl UnwindSafe for Seccfgr
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)