Search Archive

Saving CorePlayer playlist on TESTMODE shutdown. (F500)

By EEGeek · Oct 16, 2009in Hacks/Mods💬 2 posts👁️ 1,455 views
Posted Oct 16, 2009 · 21:50 UTC#1

Coreplayer has the option to save the playlist across sessions, which is great. But, the function doesn't work when the system shuts down without coreplayer being closed manually first. This happens in testmode with leetlauncher when you turn your car off. With its battery, the F500 can stay up for a couple seconds after you turn your car off before the shutdown occurs. In that time, I'd like to write an app that runs in the background and detects the power state change and closes coreplayer nicely so it saves the playlist and track position.

 

I know this is possible because the Igo8 version that comes with leetlauncher detects it and asks if you really want to shutdown when the power from the car goes away. (Granted it kills everything independent of what you select, but it detected it!)

 

I found the "RequestPowerNotifications()" Windows CE api call that is supposed to register your app with the power manager so you are notified of power state changes. I used example code and got something running but it detects nothing when the power turns off, before the system shuts down. I really want to see the Igo code that achieves this!

 

Anyone have a solution?