Skip to content

Commit d1eb971

Browse files
committed
feat: adds get_interrupt to Timer
1 parent b6c7f4c commit d1eb971

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/timer.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -678,6 +678,10 @@ impl<TIM: Instance> Timer<TIM> {
678678
self.tim.clear_interrupt_flag(event);
679679
}
680680

681+
pub fn get_interrupt(&mut self) -> Event {
682+
self.tim.get_interrupt_flag()
683+
}
684+
681685
/// Stops listening for an `event`
682686
pub fn unlisten(&mut self, event: Event) {
683687
self.tim.listen_interrupt(event, false);

0 commit comments

Comments
 (0)