the original guy was trying to update a label.... this doesn't take 1 second
of processing.

so if you call EvtGetEvent( &event, SysTicksPerSecond( ) ) in a loop it will
solve this problem. He was calling it with 0 as the timeout parameter
before.

you're over-complifying a simple problem.

cyril.

----- Original Message ----- 
From: "Aaron Ardiri" <[EMAIL PROTECTED]>
To: "Palm Developer Forum" <[EMAIL PROTECTED]>
Sent: Saturday, December 06, 2003 4:17 PM
Subject: Re: Using nilEvent to update a timer


> > call EvtGetEvent( &event, SysTicksPerSecond( ) );
> > this will generate a nil event every second.
>
> wrong.. it'll generate an event exactly one second after you call this.
> so, if you do:
>
> {
>   EvtGetEvent().
>   // 1 second of processing
> }
>
> then, it'll actually be 2 seconds between each nilEvent. :) i have
> posted code on how to do clocks/timers/animation using nilEvent many
> times in the past; go check the archives.
>
> the resolution of the timer doesn't allow you to get exactly 1 second.
> you'll probably get within 1/100th of a second, best case :)
>
> ---
> Aaron Ardiri
> [EMAIL PROTECTED]
> http://www.mobilewizardry.com/members/aaron_ardiri.php [profile]
>
> -- 
> For information on using the Palm Developer Forums, or to unsubscribe,
please see http://www.palmos.com/dev/support/forums/
>

-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/support/forums/

Reply via email to