We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents eabeb63 + 308567f commit 7715962Copy full SHA for 7715962
cores/arduino/zephyrCommon.cpp
@@ -293,8 +293,12 @@ void delay(unsigned long ms) { k_sleep(K_MSEC(ms)); }
293
void delayMicroseconds(unsigned int us) { k_sleep(K_USEC(us)); }
294
295
unsigned long micros(void) {
296
+#ifdef CONFIG_TIMER_HAS_64BIT_CYCLE_COUNTER
297
return k_cyc_to_us_floor32(k_cycle_get_64());
-}
298
+#else
299
+ return k_cyc_to_us_floor32(k_cycle_get_32());
300
+#endif
301
+ }
302
303
unsigned long millis(void) { return k_uptime_get_32(); }
304
0 commit comments