I am not sure if nil events will prevent shutoff, but I know another method of 
preventing it. Before the device powers off, it sends a keydown event of 'autoOffChr'. 
Delete the event before it gets to the system.

>> Actually don't do "Always on". �Not necessary with Palm OS.
>> 
>> 1) Use the Event handler to generate nilEvents every, say, 5 �seconds
>> 
>> � � � � �EventType event;
>> � � � � �EvtGetEvent (&event, SysTicksPerSecond () * 5L);
>> 
>> 2) When you receive a nilEvent, check how much time has elapsed since the 
>> last nilEvent. �If enough time has passed, (say 15 seconds) check if 
>> anything is received on the socket.
>
>But shouldn't this turn off the device, too, unless you set to not
>auto-off at all or not to turn off while a network connection is
>established? Simply waiting for nil events won't keep the unit awake.
>
>-- 
>Daniel Seifert <[EMAIL PROTECTED]>
>


__________________________________________________________________
McAfee VirusScan Online from the Netscape Network.
Comprehensive protection for your entire computer. Get your free trial today!
http://channels.netscape.com/ns/computing/mcafee/index.jsp?promo=393397

Get AOL Instant Messenger 5.1 free of charge.  Download Now!
http://aim.aol.com/aimnew/Aim/register.adp?promo=380455

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

Reply via email to