PocketMatrix forums

A read-only archive of the PocketMatrix forums (2001–2014). Posting and accounts are closed.

Keep backlight on

So what's the trick to keeping the backlight on? I really hope this isn't a proprietary OEM mess, which is how things are looking. I'm already stuffing keyboard events with keybd_event, and that is not keeping the backlight on. PocketTV keeps the backlight on properly on an a716, but PocketMVP does not. Since PocketTV can do it I at least know it is possible.

Dan East
joshbu [MSFT] · 26 Apr 2004, 17:26 UTC
Good news, Bad news.

Good News:

On a standard CE system, SetSystemPowerState should do the trick (in pm.h)

Bad News:

PPC and SP might use a completely different power setup becuase all of the "standard" CE components are presented as "samples" for OEMs to override if they choose. So it might be there, it might not.

Good luck.

edit: cleanup errant UBB tag.
SystemIdleTimerReset()

Look for this function. I saw mention of it in an MSDN chat:

http://msdn.microsoft.com/chats/embedde ... 103102.asp

Hope this help.

Regards,
Kornalius
joshbu, I'm not sure how to use that to keep the backlight on. It appears to cause the device to suspend or hibernate.

kornalius, that will prevent the a716 from powering down, but the backlight will still go off. So at least it is a step in the right direction.

Dan East
I know that Compaq released a proprietary SDK in order to control the backlight on the iPAQs. That was for PPC2000, I believe. So I'm doubtful that they had anything "clean" in their WinCE implementation to achieve the same effect. Things may have changed since, of course...
joshbu [MSFT] · 28 Apr 2004, 19:59 UTC
I was thinking that SetSystemPowerState(NULL, POWER_STATE_ON, 0); might do the trick.

I suppose you could also try hitting up the display driver directly. On CE, the backlight would be one of the "lower" power states of the display driver. The power management controls the driver via driver escapes, which you can also call through via ExtEscape.

The escapes are IOCTL_POWER_CAPABILITIES, IOCTL_POWER_QUERY, IOCTL_POWER_SET and IOCTL_POWER_GET.

These 4 should be in the docs (just search MSDN.)
I know my BenQ pad and keyboard on my iPaq lights up the screen, if that helps narrow it down a little bit. Perhaps reverse engineering/disassembling can help you find something.
Bingo. Fortunately a certain BetaPlayer was released recently. After trying it out I noticed the backlight stays on during playback. Even more fortunate, the source code is available.

Basically the technique is to modify the registry, then set an event to tell the display driver to honor the new display settings. After a quick search for the event name (BackLightChangeEvent) used in BetaPlayer I found this:

http://msdn.microsoft.com/library/defau ... klight.asp

Dan East
I've integrated this technique into my PSX adapter driver and it works perfectly, on both a classic iPaq 3630 (stock Pocket PC 2000) and an Asus a716. So I would expect it to work on everything inbetween.

Dan East
My backlight problem is similar: I have developed a driver to HP foldable-keyboard and micro keyboard with layout of central european languages. The mentioned way not well because I have to turn on backlight only on keypress, not all.

Have somebody any idea?