Can't do the getevent timeout - I have asynch data coming in an RS-232 port.
Looks like this will be a "quick and dirty"...
Ah, the joys of "real time" code :)
-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]] On Behalf Of Richard
Anderson
Sent: Thursday, December 07, 2000 8:05 AM
To: Palm Developer Forum
Subject: RE: [W] Multiple Threads under Codewarrior
If you setup you main event loop to send nil events at least every second
(timeout in get event) you can check the time then every five seconds call
your routine or post yourself an event. Theres lots of stuff about timing in
the archives, but not much in the manuals.
Rik
> -----Original Message-----
> From: Steve Stover [SMTP:[EMAIL PROTECTED]]
> Sent: 07 December 2000 17:46
> To: Palm Developer Forum
> Subject: RE: [W] Multiple Threads under Codewarrior
>
> Cool, but...
>
> I have a data collection routine that operates at (relatively) long
> intervals. It would be nice if I could say
> Get Data;
> Sleep(5sec)
> Repeat
> And keep it separate from the other code.
>
> If I understand your event queue correctly, I still need the main loop to
> calculate timing somehow, and a running (or idling) event loop to handle
> the
> special event. Or is there some way to call a specific event handler when
> needed? But that wouldn't buy me anything I don't already have. It's the
> timing calculation that would be simplified in a separate thread, to run
> different parts of the code at different rates...
>
> Am I missing the point?
<snip>
--
For information on using the Palm Developer Forums, or to unsubscribe, please see
http://www.palmos.com/dev/tech/support/forums/