diff options
author | Luke T. Shumaker <lukeshu@lukeshu.com> | 2025-02-02 02:01:30 -0700 |
---|---|---|
committer | Luke T. Shumaker <lukeshu@lukeshu.com> | 2025-02-09 22:22:28 -0700 |
commit | 4a6fbecab34616a7b16a859f9458a21b339bb6b0 (patch) | |
tree | 4ffc6a8f2732ac29e6e75d0677c93c2213db6948 /cmd/sbc_harness | |
parent | fa10ceb13e66309ba24605dd5df91c4d626f0614 (diff) |
Have main() set `bootclock`
Diffstat (limited to 'cmd/sbc_harness')
-rw-r--r-- | cmd/sbc_harness/main.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/cmd/sbc_harness/main.c b/cmd/sbc_harness/main.c index b17725d..4580acc 100644 --- a/cmd/sbc_harness/main.c +++ b/cmd/sbc_harness/main.c @@ -10,7 +10,9 @@ #include <hardware/flash.h> /* pico-sdk:hardware_flash: for flash_get_unique_id() */ #include <libcr/coroutine.h> +#include <libhw/generic/alarmclock.h> /* so we can set `bootclock` */ #include <libhw/rp2040_hwspi.h> +#include <libhw/rp2040_hwtimer.h> #include <libhw/w5500.h> #include <libmisc/hash.h> #include <libmisc/vcall.h> @@ -131,6 +133,7 @@ COROUTINE init_cr(void *) { } int main() { + bootclock = rp2040_hwtimer(0); stdio_uart_init(); /* char *hdr = "=" * (80-strlen("info : MAIN: ")); */ infof("==================================================================="); |