Re: Accuracy of timers?
Re: Accuracy of timers?
- Subject: Re: Accuracy of timers?
- From: "Jeremy W. Sherman" <email@hidden>
- Date: Thu, 23 Apr 2009 00:49:11 -0400
Timers can only fire when your app is running in the run loop mode that they
are part of. You can investigate alarm(3) and setitimer(3), but I don't know
how much more accurate they will be. Mac OS X is not a real-time OS.
—Jeremy
On Thu, Apr 23, 2009 at 12:31 AM, M Pulis <email@hidden> wrote:
> Expect the same here. I believe they are not guaranteed for accuracy...
> from Apple:
>
> "Because of the various input sources a typical run loop manages, the
> effective resolution of the time interval for a timer is limited to on the
> order of 50-100 milliseconds."
>
> Reference google for NSTimer class reference.
>
> gary
>
>
>
>
> On Apr 22, 2009, at 9:19 PM, Eric E. Dolecki wrote:
>
> I'm wondering generally how accurate timers can be expected to be. Are
>> they
>> generally accurate within a few ms depending on what else is going on in
>> an
>> application? Is threading an answer to most accurate timing? Just curious
>> here. I'm coming from another language where timers can be off fairly
>> significantly depending on drawing activity.
>> Eric
>> _______________________________________________
>>
>> Cocoa-dev mailing list (email@hidden)
>>
>> Please do not post admin requests or moderator comments to the list.
>> Contact the moderators at cocoa-dev-admins(at)lists.apple.com
>>
>> Help/Unsubscribe/Update your Subscription:
>>
>> This email sent to email@hidden
>>
>
> _______________________________________________
>
> Cocoa-dev mailing list (email@hidden)
>
> Please do not post admin requests or moderator comments to the list.
> Contact the moderators at cocoa-dev-admins(at)lists.apple.com
>
> Help/Unsubscribe/Update your Subscription:
>
>
> This email sent to email@hidden
>
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden