Discussion Board

Results 1 to 5 of 5

Thread: Timer query

  1. #1
    Regular Contributor kumar_sai123's Avatar
    Join Date
    Oct 2007
    Posts
    73
    Hi all,
    i am using active objects in my application. In the RunL function i am using RTimer object to generate the event.
    Code:
    void CGenerateText::RunL()
    	{
    	// Change visibility of app view text
    	ShowText(EFalse);
    
    	// Re-issue request
    	iTimer.After(iStatus, iHalfPeriod);
    	SetActive();
    	}
    Here iTimer is of type RTimer and iHalfPeriod is of type TTimeIntervalMicroSeconds32.

    It is working perfectly allright but the range for the time interval is 35 minutes 47 sec. But i want a larger range (say 2hours). I want to know what kind of timers should i use for the larger range of time interval.

    thanks and regards,
    Krishna.

  2. #2
    Registered User yogpan's Avatar
    Join Date
    Jun 2006
    Location
    India
    Posts
    1,043
    Hi,
    Have you tried using
    RTimer::At(). Check the SDK documentation for this if it suits your purpose.
    Maximus
    S60 Developer
    Impossible is nothing

  3. #3
    Nokia Developer Champion qxiaoyuan's Avatar
    Join Date
    Jul 2007
    Location
    ShenZhen, China
    Posts
    4,346
    ....................
    ----------------------------
    坚持学习, 坚持编码
    http://www.devdiv.net/
    qxiaoyuan

  4. #4
    Regular Contributor emailatravi's Avatar
    Join Date
    Dec 2006
    Location
    Noida, India
    Posts
    115
    Hi,,


    I had previously faced the same problem. You need to implement the counter which gets incremented say every 30 min. ad then reset the counter AND perform the task when threshold for your counter has reached.
    Thanks and Regards,
    Ravi

  5. #5
    Registered User sriky27's Avatar
    Join Date
    Dec 2005
    Posts
    1,236
    Hi Kumar,

    yes After will not work after 35min and 47 it is mentioned in the documentation of TTimeIntervalMicroSeconds32 here. However there is solution for your problem you should be using RTimer::At() pass the time you want. For example

    you want a call back after 2 hours. Then you should try sth like
    Code:
    TTime time;
    time.HomeTime();
    time += aTime;
    iTimer.At( time );
    Regards,
    Sriky

Similar Threads

  1. When can you set the screensaver's Refresh Timer Value?
    By azhrei in forum Symbian Tools & SDKs
    Replies: 6
    Last Post: 2008-08-23, 10:12
  2. [Announce] Timer Sample (code)
    By JOM in forum Python
    Replies: 5
    Last Post: 2008-06-15, 00:23
  3. Crash with multiple ao_timer
    By noreli in forum Python
    Replies: 2
    Last Post: 2007-11-01, 06:18
  4. Timer delay between playbacks???
    By lalitsharma in forum Symbian C++
    Replies: 3
    Last Post: 2005-09-09, 11:45
  5. Timer to a query
    By vaiski79 in forum Symbian C++
    Replies: 0
    Last Post: 2003-12-03, 12:14

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Nokia Developer aims to help you create apps and publish them so you can connect with users around the world.

京ICP备05048969号  © Copyright Nokia 2013 All rights reserved