Forum Index
HomeZBasic Home   Forum RulesForum Rules   Forum FAQForum FAQ   MemberlistMemberlist   UsergroupsUsergroups   RSS FeedRSS Feed
Site SearchSite Search   LinksLinks   DownloadDownload   Digests and SubscriptionsDigests and Subscriptions
ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in   RegisterRegister
Force an interval expiration

 
Post new topic   Reply to topic    Forum Index -> ZBasic Language
Author Message
Tim



Joined: 27 Feb 2010
Posts: 6

Posted: 13 March 2010, 2:35 AM    Post subject: Force an interval expiration Reply with quote

I am using the the command "SetInterval(1)" to force an interval expiration on a task using WaitForInterval. However, this causes a delay of up to 1 RTC tick before the task resumes. Is there a way I can force an immediate interval expiration?
Back to top
dkinzer
Site Admin


Joined: 03 Sep 2005
Posts: 2499
Location: Portland, OR

Posted: 13 March 2010, 2:56 AM    Post subject: Re: Force an interval expiration Reply with quote

Tim wrote:
Is there a way I can force an immediate interval expiration?
I suspect that ResumeTask() will serve your purpose. You'll have to pass the task stack of the task that is awaiting the interval expiration (unless it is the Main() task).
Back to top
Tim



Joined: 27 Feb 2010
Posts: 6

Posted: 13 March 2010, 3:04 AM    Post subject: Reply with quote

Aha! Thats what I wanted. Not sure how I missed that function. I'm still new to working with tasks.

Thank you much.
Back to top
Display posts from previous:   
Post new topic   Reply to topic    Forum Index -> ZBasic Language Time synchro. with the server - Timezone/DST with your computer
Page 1 of 1

 


All content Copyright © 2005-2012 Elba Corp. All Rights Reserved.
Opinions expressed in posts are those of the author and not necessarily those of Elba Corp.
Powered by phpBB © 2001, 2005 phpBB Group