Rockbox mail archiveSubject: Re: DEV timer? GetTicks?
Re: DEV timer? GetTicks?
From: Björn Stenberg <bjorn_at_haxx.se>
Date: Mon, 22 Sep 2003 10:17:59 +0200
Minuk Choi wrote:
> Hiya, I'm playing around with the source files... and I was
> wondering... is there a way to grab the current number of ticks or
Yes. The variable 'current_tick' is incremented HZ times per second.
> I want to write something that implements a time based (in milliseconds)
You should use sleep(HZ/fraction) for that. Busy waiting does not work since we don't use preemptive scheduling.
-- BjörnReceived on 2003-09-22
Page was last modified "Sat May 23 08:12:40 2020" The Rockbox Crew