Re: Safely SHUTDOWN Device from Application
- From: Neo <prideray@xxxxxxxxx>
- Date: Fri, 19 Sep 2008 09:03:49 -0700 (PDT)
On Sep 18, 7:48 pm, "Chris Tacke, eMVP" <ctacke.at.opennetcf.dot.com>
wrote:
Well the first thing you have to define is "shut down". What does that mean
in your context? CE devices don't generally have a shut down state, but
rather a suspend state. In that case sending a VK_POWEROFF usually is all
you need (no clue if the emulator supports this though - IIRC Bruce Eitman
blogged about doing this recently). If you mean "shut all power off" then
that's going to be device dependent and the OEM would be the only one who
could tell you how. If you mean a hard reset then a call to KernelIoControl
is a common way to achieve it, but again the device must have support for
it.
--
Chris Tacke, Embedded MVP
OpenNETCF Consulting
Giving back to the embedded communityhttp://community.OpenNETCF.com
"Neo" <pride...@xxxxxxxxx> wrote in message
news:132d7334-f76b-4d71-b9bd-054b3cb82efd@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Hi!
I am working with WinCE 5.0 and x86 Emulator. I wish to write an
application to safely shutdown the device. After a few searches I
could note that I need to use IOCTLs (if I'm not wrong!) and there
are existing implementations of Suspend, Reboot but nothing for safely
shutting down the device.I have identified some of the functions that
might be useful like:
void OEMPowerOff(void)
void OALCPUPowerOff(void)
IOCTL_POWER_SET
IOCTL_POWER_GET
IOCTL_REGISTER_POWER_RELATIONSHIP
KernelIOControl()
I wish to know what all things I need to know, apart from these and
how do I put all these things together!
Regards,
-- Neo
By 'Safe Shutdown', I meant that any application writing/reading to/
from the Flash should be notified about the system going down for a
shut down (instead of aborting it) so that the application gets a fair
chance for it's graceful exit and then a regular shutdown (power off)
of the platform should be carried. I think, second part of the issue
(shutting down the platform) might be specific to the Device but, I
think we should be able to perform the 1st step (notifying all the
applications interacting with the Flash resulting in their graceful
exit). How can we achieve this? Please guide me on this.
Thanks,
Neo
.
- Follow-Ups:
- Re: Safely SHUTDOWN Device from Application
- From: Chris Tacke, eMVP
- Re: Safely SHUTDOWN Device from Application
- References:
- Safely SHUTDOWN Device from Application
- From: Neo
- Re: Safely SHUTDOWN Device from Application
- From: Chris Tacke, eMVP
- Safely SHUTDOWN Device from Application
- Prev by Date: Re: Safely SHUTDOWN Device from Application
- Next by Date: WindowsCE 6.0 + OTG support
- Previous by thread: Re: Safely SHUTDOWN Device from Application
- Next by thread: Re: Safely SHUTDOWN Device from Application
- Index(es):
Loading