Page 1 of 1

PostPosted: Wed Mar 07, 2007 12:00 am
by samps
Hi all,

I'm writing an app that needs the screen of my Tungsten to be on for more than the 3 minutes that I can set in Prefs.

Any idea how I do that? Is there some hardware hook? or will I have to simulate graffiti strokes to keep it 'alive'? If so, any pointers to that?


PostPosted: Wed Mar 07, 2007 12:20 am
by dewey
Try resetaot().

PostPosted: Wed Mar 07, 2007 7:21 am
by samps
I knew that!

Thanks, Dewey.

That was straight from page 1 of the friendly, but sadly neglected, manual, wasn't it?

Giving back, here's the snippet I used it for:

Code: Select all
   if ((!auto_off.checked) && (battery(false)>50)) {

a checkbox called auto_off toggles between honouring the Palm Auto-Off timer or ignoring it until the battery reaches 50% of its capacity.


PostPosted: Thu Mar 08, 2007 5:14 am
by nmc
You have to do that in a timer (every 2:95 mins if auto off is set to 3:00 mins), because it <i>resets </i>the auto off timer but does not disable it.

PostPosted: Thu Mar 08, 2007 7:01 am
by samps
I do indeed call it from within a timer. I probably showed too little of the surrounding context in my example. Sorry 'bout that.