pub type TimerIsrCallback = IsrCallback<TimerIsrFunction, bool>;
Aliased Type§
enum TimerIsrCallback {
Nop(bool),
Function(fn(_: Isolated, _: TimerIdentity, _: u16, _: Option<*const dyn Any>) -> bool),
WithData(fn(_: Isolated, _: TimerIdentity, _: u16, _: Option<*const dyn Any>) -> bool, *const dyn Any),
}
Variants§
Nop(bool)
No Operation - dummy callback that evaluates to a fixed constant return value.
Function(fn(_: Isolated, _: TimerIdentity, _: u16, _: Option<*const dyn Any>) -> bool)
A function/closure callback. This will be called when the interrupt
service routine needs it; the function signature is context dependent,
however the last parameter will always be an Option<&'static dyn Any>
user-data field, which will be given a None
value.
The first parameter must be an isolation token
(avr_oxide::concurrency::Isolated
)
WithData(fn(_: Isolated, _: TimerIdentity, _: u16, _: Option<*const dyn Any>) -> bool, *const dyn Any)
A function/closure callback. This will be called when the interrupt
service routine needs it; the function signature is context dependent,
however the last parameter will always be an Option<&'static dyn Any>
user-data field, into which the given data will be passed as Some()
value.
The first parameter must be an isolation token
(avr_oxide::concurrency::Isolated
)