SDE and network server apps.

D

David Thornley

An issue for the gurus: -

How can I debug and test an application (using PocketPC 2003) which exposes
a network service on the emulator? For example a simple app using a
TCPListener, accepts a connection and dumps data to a listbox.

The code was quite easy to write, however... The big problem I have found is
getting a device or emulator to be debugged and accessible from my LAN. I
imagine I could solve this simply by using my iPaq with a network adapter
(say ethernet CF card, wlan) and then use activesync to debug along with
having a LAN based IP address on the network to serve to my tcplistener. As
a sort of challenge, at the moment my only 2 options are an ipaq 3970 with
bluetooth and the PPC2003 emulator. I don't think you can do this at all
with the 2002 emulator.

Bluetooth is a complete ass (Ipaq 3970 with PPC2003), if I connect to my
PC's PAN service and then connect via activesync (either via the cradle or
using bluetooth activesync) the PAN connection dies or becomes mute. I did
some testing by enumerating the current hostname ip addresses using the Dns
class, it seems activesync overrides the PAN IP address with it's own
internal IP address or flat out drops the connection. Now I can't claim to
be an expert here but I gave up citing bluetooth/pocketpc 2003 connection
issues, most likely related to the activesync pass through function (WHICH
CAN'T BE DISABLED BTW). Isn't the passthrough is great for outgoing
connections but useless for incoming (to device)?

Next in line, the emulator in SDE really has me confused, it installs
PocketPC2003 targets in VS.NET2003 which almost work fine... Unfortunately,
I am fairly sure VS.NET2003/SDE is currently using the 4.1 Emulator.exe to
run the CE.NET 4.2 pocketpc 2003 image (why!). This means that the new (4.2)
virtualswitch option is not available. The virtualswitch network option
allows the emulator to be accessible on my LAN by giving it a LAN accessible
IP address, the default alternative is a NAT style adapter (only useful for
outgoing originated connections like PIE, and similar to activesync
passthrough) subsequently totally useless for my TCPListener service.
Anyhow, the virtualswitch function also uses a network plug-in which seems
ONLY evc4.0 SP1/SP2 (possibly SDE too) installs into the PC's primary
network interface "Virtual PC Emulated Ethernet Switch". I wonder why they
didn't use a virtual adapter like widcomm have done in their bluetooth
drivers? That would be neat... you could bridge or use ICS or whatever.

The PPC2003 emulator from my current EVC4.0 install, doesn't seem to work at
the moment although I imagine I just need to remove everything and
reinstall. However it does gives me the option for virtualswitch which
causes the emulator to have its own LAN accessible IP address. Great in
principle and the main thing is I have managed to get it working manually by
invoking the emulator myself from the command line. Although I can't seem to
get SDE to debug to the manually executed emulator, obviously it needs
activesync. I have seen an article which mentions using the emuAScfg.exe but
I could not get this to work at all (Any info would be greatly appreciated).
I suppose I could setup the partnership with a serial cable...

I combed the newsgroups and found other people with similar problems
although more complex I guess (some using UDP). However nothing suggests a
working solution to this problem, is it just that this sort of thing is
"?uncommon?" so far with the compact framework?

Conclusively the only options I can think of are: -

1. Give in and use a physical device and a network adapter and activesync
over the network.
2. Get the command line invoked emulator to activesync so I can debug
(serial or emuascfg.exe).
3. Complain a little that Microsoft needs to fix the SDE integration in
VS.NET2003 particularly in regards to the emulator integration for PPC2003.
I had a look at the assemblies in the CF folder like
ConMan.dll,ConManDataStore.dll... man that is a highly detailed integration!

I hope this generates some discussion for people who maybe have run into
similar problems. I am still new to the .NET framework and SDE in
particular. I just wish this was a little more easy in cases like this.

Any corrections/further info would be greatly appreciated.

Regards,

David.
 
P

Paul G. Tobey [eMVP]

Don't forget that working successfully in the emulator, although it means
more now than it did a year or two ago, doesn't mean much about whether the
application will work on the actual hardware or not. Testing on the
emulator is *not* a substitute for testing on the target device(s).

Paul T.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top