summaryrefslogtreecommitdiffstatshomepage
path: root/shared/runtime
diff options
context:
space:
mode:
authorAngus Gratton <angus@redyak.com.au>2024-01-02 12:19:33 +1100
committerDamien George <damien@micropython.org>2024-05-31 16:43:52 +1000
commit74fb42aa82d537b6fefb463907274bd660c6ce8d (patch)
treed7c3c358a75ab1c9d4916d939b25e3aa39f8d919 /shared/runtime
parent2926001b60fb5060727f3d8034c84cfb014a5dca (diff)
downloadmicropython-74fb42aa82d537b6fefb463907274bd660c6ce8d.tar.gz
micropython-74fb42aa82d537b6fefb463907274bd660c6ce8d.zip
rp2: Refactor soft timer to use hardware timer alarm.
Progress towards removing pico-sdk alarm pool, due to a known issue. This work was funded through GitHub Sponsors. Signed-off-by: Angus Gratton <angus@redyak.com.au>
Diffstat (limited to 'shared/runtime')
-rw-r--r--shared/runtime/softtimer.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/shared/runtime/softtimer.h b/shared/runtime/softtimer.h
index fe5d02b907..6921c9f47d 100644
--- a/shared/runtime/softtimer.h
+++ b/shared/runtime/softtimer.h
@@ -81,6 +81,9 @@ static inline void soft_timer_reinsert(soft_timer_entry_t *entry, uint32_t initi
// pend-SV IRQ level, or equivalent.
uint32_t soft_timer_get_ms(void);
void soft_timer_schedule_at_ms(uint32_t ticks_ms);
+
+// Optional port-specific initialisation function (provided and called by the port if needed).
+void soft_timer_init(void);
#endif
#endif // MICROPY_INCLUDED_SHARED_RUNTIME_SOFTTIMER_H