Rockbox Technical Forums

Rockbox Development => Starting Development and Compiling => Topic started by: hydroo on January 22, 2008, 07:50:46 AM

Title: Accurate timing?!
Post by: hydroo on January 22, 2008, 07:50:46 AM
Hi,

I am thinking about creating a game for rockbox.
I have been playing around a bit, and have some questions.

Is there kernel-timer ("current_tick" reliable? - steady and 100 ticks/sec ?)

Are there platformdifferences?

Can the tickfrequency change?

What would be the best way to get a steady, accurate clock?

(I am using the sansae200, if that matters)

regards
Title: Re: Accurate timing?!
Post by: LinusN on January 22, 2008, 08:21:21 AM
Yes, the tick timer is reliable, and it ticks with HZ ticks per second (currently 100, not likely to change)

There is also a possibility to use one of the hardware timers if you need better resolution.

All targets have the same tick timer, but not all have available hardware timers to use.