Includes standalone modules for the TIMER and RTC peripherals exposing most but not all of their functionality (the main missing feature is the TIMERs' counter mode).
Provides new implementations of the embedded-hal CountDown and Delay traits based on these modules.
These support using all three TIMERs, or either RTC, at any frequency supported by the hardware.
Includes backwards-compatible timer::Timer and delay::Delay types.
The approach is loosely based on PR #12 but the implementation is new, with the 'driver' code separated from the countdown/delay support, and no macros.
The hardware restriction to no more than 16-bit mode for TIMER1 and TIMER2 is enforced statically.
Includes standalone modules for the TIMER and RTC peripherals exposing most but not all of their functionality (the main missing feature is the TIMERs' counter mode).
Provides new implementations of the embedded-hal
CountDown
andDelay
traits based on these modules.These support using all three TIMERs, or either RTC, at any frequency supported by the hardware.
Includes backwards-compatible
timer::Timer
anddelay::Delay
types.The approach is loosely based on PR #12 but the implementation is new, with the 'driver' code separated from the countdown/delay support, and no macros.
The hardware restriction to no more than 16-bit mode for TIMER1 and TIMER2 is enforced statically.
There are usage examples in the rustdoc and in
test_timer.rs
andtest_countdown.rs
on the mattheww/microbit timer-test-examples branch (which is based on the droogmic/microbit timer-rtc branch).