alif/system_tick: Use a UTIMER for system ticks and timing.

Includes an implementation of `system_tick_wfe_with_timeout_us()`.

Signed-off-by: Damien George <damien@micropython.org>
This commit is contained in:
Damien George
2024-01-10 14:37:52 +11:00
parent ccc5935234
commit 40ff0c2f27
5 changed files with 184 additions and 23 deletions

View File

@@ -38,6 +38,7 @@
#include "mpuart.h"
#include "ospi_flash.h"
#include "pendsv.h"
#include "system_tick.h"
extern uint8_t __StackTop, __StackLimit;
extern uint8_t __GcHeapStart, __GcHeapEnd;
@@ -53,7 +54,7 @@ NORETURN void panic(const char *msg) {
}
void _start(void) {
SysTick_Config(SystemCoreClock / 1000);
system_tick_init();
MICROPY_BOARD_STARTUP();