File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -72,6 +72,14 @@ void svc_call(void) {
7272 exit (0 );
7373}
7474
75+ #if LIB_PICO_AON_TIMER
76+ static bool aon_timer_done = false;
77+ void spoop (void ) {
78+ printf ("XXXX YARGLE XXXX\n" );
79+ aon_timer_done = true;
80+ }
81+ #endif
82+
7583int main (void ) {
7684 spiggle ();
7785
@@ -137,15 +145,14 @@ int main(void) {
137145#endif
138146#if LIB_PICO_AON_TIMER
139147 aon_timer_start_with_timeofday ();
140- void spoop (void );
141148 struct timespec ts ;
142- ts .tv_sec = 6 ;
149+ ts .tv_sec = 2 ;
143150 ts .tv_nsec = 1000000000 / 2 ;
144151 aon_timer_enable_alarm (& ts , spoop , false);
145- while (true ) {
152+ while (! aon_timer_done ) {
146153 aon_timer_get_time (& ts );
147154 printf ("%ld %ld\n" , (long )ts .tv_sec , ts .tv_nsec );
148- busy_wait_ms (4000 );
155+ busy_wait_ms (500 );
149156 }
150157#endif
151158#ifndef __riscv
@@ -156,9 +163,3 @@ int main(void) {
156163 puts ("PASSED" );
157164#endif
158165}
159-
160- #if LIB_PICO_AON_TIMER
161- void spoop (void ) {
162- printf ("XXXX YARGLE XXXX\n" );
163- }
164- #endif
You can’t perform that action at this time.
0 commit comments