pub struct Wdt<TG> { /* private fields */ }Expand description
Watchdog timer
Implementations§
Source§impl<TG> Wdt<TG>where
TG: TimerGroupInstance,
impl<TG> Wdt<TG>where
TG: TimerGroupInstance,
Watchdog driver
Sourcepub unsafe fn set_wdt_enabled(&mut self, enabled: bool)
pub unsafe fn set_wdt_enabled(&mut self, enabled: bool)
Forcibly enable or disable the watchdog timer
§Safety
This bypasses the usual ownership rules for the peripheral, so users must take care to ensure that no driver instance is active for the timer.
Sourcepub fn set_timeout(&mut self, stage: MwdtStage, timeout: MicrosDurationU64)
pub fn set_timeout(&mut self, stage: MwdtStage, timeout: MicrosDurationU64)
Set the timeout, in microseconds, of the watchdog timer
Sourcepub fn set_stage_action(&mut self, stage: MwdtStage, action: MwdtStageAction)
pub fn set_stage_action(&mut self, stage: MwdtStage, action: MwdtStageAction)
Set the stage action of the MWDT for a specific stage.
This function modifies MWDT behavior only if a custom bootloader with the following modifications is used:
ESP_TASK_WDT_ENparameter disabledESP_INT_WDTparameter disabled
Trait Implementations§
Source§impl<TG> InterruptConfigurable for Wdt<TG>where
TG: TimerGroupInstance,
impl<TG> InterruptConfigurable for Wdt<TG>where
TG: TimerGroupInstance,
Source§fn set_interrupt_handler(&mut self, handler: InterruptHandler)
fn set_interrupt_handler(&mut self, handler: InterruptHandler)
Set the interrupt handler Read more
Source§impl<TG> WatchdogDisable for Wdt<TG>where
TG: TimerGroupInstance,
impl<TG> WatchdogDisable for Wdt<TG>where
TG: TimerGroupInstance,
Source§impl<TG> WatchdogEnable for Wdt<TG>where
TG: TimerGroupInstance,
impl<TG> WatchdogEnable for Wdt<TG>where
TG: TimerGroupInstance,
Auto Trait Implementations§
impl<TG> Freeze for Wdt<TG>
impl<TG> RefUnwindSafe for Wdt<TG>where
TG: RefUnwindSafe,
impl<TG> Send for Wdt<TG>where
TG: Send,
impl<TG> Sync for Wdt<TG>where
TG: Sync,
impl<TG> Unpin for Wdt<TG>where
TG: Unpin,
impl<TG> UnwindSafe for Wdt<TG>where
TG: UnwindSafe,
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
Mutably borrows from an owned value. Read more