Freigeben über


GPS and the DeviceEmulator, Part 2 - Using GPS receiver hardware from the emulator

Using GPS receiver hardware from inside the DeviceEmulator is actually more straightforward than using the virtual GPS receiver from Part 1.  Here is how:

  • Plug your GPS receiver into a serial port on your PC.
  • Launch the Windows Mobile 5.0 PocketPC emulator
  • In the emulator's Tools/Options dialog, switch to the Peripherals Tab, and point "Serial Port 0" to the PC serial port where your GPS device is plugged in.  In my case, this was COM3:.
  • Inside Windows Mobile, go to Start/Settings and on the System tab, click on GPS.  On the Hardware tab, select COM1 as the GPS Hardware Port, and pick the baud rate that matches your GPS hardware's expectation (usually 4800).  Click OK.

Now, if you use a GPS-aware application, such as the sample in " C:\Program Files\Windows CE Tools\wce500\Windows Mobile 5.0 Pocket\PC SDK\Samples\Cs\Gps\Gps.sln", the application will report updated location information about once per second.

Shameless plug:  There is a programmatic interface to Windows Live Local, where you plug in latitude/longitude values into the URL to retrieve aerial photos... https://local.live.com/default.aspx?v=2&cp=47.693636~-122.058903&style=o&lvl=2 should drop you right on top of my alpaca farm.  Unfortunately, the whole herd appears to be hiding under the trees so they are hard to pick out in the photos.

Comments