hello to every body
I`m developing a program that get the GPS data and i used the GPS library of Microsoft.
My problem is when the device into the sleep mode, the GPS device get the same position for 7 minute and then does not get any position,
for solve this i used this code :
CoreDLL.PowerPolicyNotify(PPNMessage.PPN_UNATTENDEDMODE, -1);
const int POWER_NAME = 0x00000000;
int notify = CoreDLL.DevicePowerNotify(GpsDeviceName, CEDEVICE_POWER_STATE.D0, POWER_NAME);
IntPtr power = CoreDLL.SetDevicePower(GpsDeviceName, DevicePowerFlags.POWER_NAME, CEDEVICE_POWER_STATE.D0);
and this code:
<br />
CEDEVICE_POWER_STATE state = CEDEVICE_POWER_STATE.D0;<br />
CoreDLL.GetDevicePower(GpsDeviceName, DevicePowerFlags.POWER_NAME, out state);<br />
CoreDLL.SetPowerRequirement(GpsDeviceName, CEDEVICE_POWER_STATE.D0,<br />
DevicePowerFlags.POWER_NAME | DevicePowerFlags.POWER_FORCE,<br />
IntPtr.Zero, 0);<br />
<br />
but this work in HTC touch2 and acer E101,s200 and Xperia and .....
but doesn`t work on HTC HD2,,,,
What can i do??
Please Help..
Thanks