[−][src]Struct msp430fr2x5x_hal::watchdog::Wdt
Watchdog timer which can be configured to watchdog or interval (timer) mode
Implementations
impl Wdt<WatchdogMode>
[src]
pub fn constrain(wdt: WDT_A) -> Self
[src]
Convert WDT peripheral into a watchdog timer (watchdog mode) and disable the watchdog. Set clock source to VLOCLK.
impl<MODE: WatchdogSelect> Wdt<MODE>
[src]
pub fn set_aclk(&mut self, _clks: &Aclk) -> &mut Self
[src]
Set watchdog clock source to ACLK and halt timer.
pub fn set_vloclk(&mut self) -> &mut Self
[src]
Set watchdog clock source to VLOCLK and halt timer.
pub fn set_smclk(&mut self, _clks: &Smclk) -> &mut Self
[src]
Set watchdog clock source to SMCLK and halt timer.
impl Wdt<WatchdogMode>
[src]
pub fn to_interval(self) -> Wdt<IntervalMode>
[src]
Convert to interval mode and pause timer
impl Wdt<IntervalMode>
[src]
pub fn to_watchdog(self) -> Wdt<WatchdogMode>
[src]
Convert to watchdog mode and pause timer
pub fn enable_interrupts(&mut self) -> &mut Self
[src]
Enable interrupts for watchdog, which fires when the watchdog interrupt flag is set in interval mode. This setting does nothing in watchdog mode, but will carry over when switching to interval mode.
pub fn disable_interrupts(&mut self) -> &mut Self
[src]
Disable interrupts for watchdog.
Trait Implementations
impl Cancel for Wdt<IntervalMode>
[src]
type Error = Void
Error returned when a countdown can't be canceled.
pub fn cancel(&mut self) -> Result<(), Self::Error>
[src]
This implementation will never return error even if watchdog has already been paused, hence
the Void
error type.
impl CountDown for Wdt<IntervalMode>
[src]
type Time = WdtClkPeriods
The unit of time used by this timer
pub fn start<T>(&mut self, count: T) where
T: Into<Self::Time>,
[src]
T: Into<Self::Time>,
pub fn wait(&mut self) -> Result<(), Void>
[src]
If called while timer is not running, this will always return WouldBlock.
impl Periodic for Wdt<IntervalMode>
[src]
impl Watchdog for Wdt<WatchdogMode>
[src]
impl WatchdogDisable for Wdt<WatchdogMode>
[src]
impl WatchdogEnable for Wdt<WatchdogMode>
[src]
Auto Trait Implementations
impl<MODE> Send for Wdt<MODE> where
MODE: Send,
[src]
MODE: Send,
impl<MODE> !Sync for Wdt<MODE>
[src]
impl<MODE> Unpin for Wdt<MODE> where
MODE: Unpin,
[src]
MODE: Unpin,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,