free web page counters

Windows Mobile Pocket PC Smartphone Programming

==>Click here for the SiteMap<==. Original contents with decent amount of source codes.

Monday, April 24, 2006

Emulator Troubleshooting/Tip 02: Emulator Connecting to Internet (Internet Pass-through Connectivity) Issue

====>SiteMap of this Blog<===

Emulator Troubleshooting/Tip 02: Emulator Connecting to Internet (Internet Pass-through Connectivity) Issue

The post "Emulator Troubleshooting/Tip 01: To Cradle or Not to Cradle?" is mainly regarding basic knowledge of the new Emulators. Essentially DMA channel is used by Visual Studio and Remote Tools to communicate with the Emulator. It is really NOT that necessary to always ActiveSync an emulator.

Internet Pass-through Connectivity

However, in a lot of cases, the emulator needs to be cradled and ActiveSync'ed. One common requirement is that the emulator wants to use host PC's networking capability, as if it were its own. You can use this feature to perform tasks such as downloading POP3 or IMAP4 email messages, to connect directly with a remote server, or to browse the Internet. This feature is called "Internet Pass-Through". My post briefly talks about how to make it. An excellent post from a Microsoft employee shows much detailed steps with screen cuts.

However, the Microsoft post and a lot of other similar articles only mention what to do in the emulator side. I want to emphasize here that you also need to take care of the ActiveSync side. ActiveSync needs to be instructed whether the host computer is connected to "Work Network" or "The Internet". See below for a screen cut and how to do it:

  1. Click Connection Settings.
  2. Select Open ActiveSync when my device connects.
  3. In the This computer is connected to list, select a connection to which this computer should connected when passing through ActiveSync.

If you are not sure what network to use, choose "Automatic". Hopefully ActiveSync can automatically find out which network the host PC is connected and adjust emulator's setting accordingly.

My Use Case

I am not the lucky one that ActiveSync magically finds out the network to use. It took me 30 minutes to figure out why all of a sudden the emulator in my home PC could not browse internet. Basically the ActiveSync setting is somewhat mysteriously changed to either "Work Network" or "The Internet". Here is my story:

I am using Comcast cable for internet access at home. Occasionally, when I work from home, I run a VPN software in my home PC to place it into the company's intranet. Once in the intranet, any external web site can only be accessed via a proxy server.

Therefore, the emulator in my home PC needs to have internet access in two distinct cases:

  • My home PC is inside the corporate intranet. In the emulator side, a proxy server must be configured. In ActiveSync side, "Work Network" or "Automatic" must be used. The emulator cannot browse internet if "The Internet" is chosen in ActiveSync.
  • After business hour, my home PC is directly connected to the public internet. In the emulator side, no special action needs to be taken. In ActiveSync side, "The Internet" or "Automatic" must be chosen. Again, the emulator won't connect if "Work Network" is chosen in ActiveSync.

Wrap Up

Next time when you fight with your emulator that cannot browse a public site, not only check whether the emulator is cradled and ActiveSync'ed successfully, but also check whether ActiveSync side is setup properly!

====>SiteMap of this Blog<===




[ [permalink] ]

3 Comments:

At October 13, 2006 2:09 PM, Anonymous Anonymous said...

Hello Lao,
great article, i am developing on a WM 5.0 device using VS 2005, i am working on GPRS connectivity through the connection manager.

i understand i need Active Sync in-order for VS tools/debugger to work and to step through code, but if the phone is cradled it will access the Internet through this "pass through" connection via the PC and not through my GPRS connection.

i want to force it to use my GPRS connection and not the Internet connection it gets from the PC over Active Sync. how can i do that?
Regards

 
At February 04, 2007 9:29 PM, Anonymous Anonymous said...

Hi Mohamad, did you find the solution for your problem, if so please publish it, I'm also facing the same problem

 
At February 10, 2009 12:35 AM, Anonymous Anonymous said...

i have a windows mobile emulator on a laptop which is not connected to any network...why i cannot acces a web page in internet explorer.On the laptop i have a website on IIS which is running...where should be the problem?

 

Post a Comment

<< Home