Some code to get Winsock working over GPRS on a PPC 2003?
October 4, 2006 5:05 AM   Subscribe

How do I program Winsock to work right over a GPRS connection on a PPC 2003?

So I have a Pocket PC 2003 and it's also a mobile phone (one of the new HP iPaqs Cingular offers).

I'm looking for some code to start and process a connection with the ConnectionManager, then connect and send/receive bytes with Winsock (socket, connect, send, recv). I can initiate a connection with EstablishConnectionSync and check the status, and even get the IP address, but when I try to do a DNS lookup with Winsock it gives me addresses that don't make sense, and it won't connect to remote IPs. I'm even binding to the IP I get from the Connection Manager (as has been suggested when you have a multihomed computer and want to use a specific interface), and I think it's right because I can ping google.com from Pocket Ping and it registers the same local IP I get from the ConnectionManager.

I've been searching for about a week and I can't find an example of anything that attaches to GPRS, makes a connection over Winsock and sends and receives data. Do I have to use the Wininet API (ugh) or can I stick with my regular winsock code that works perfectly on my desktop PC? I'm using eVC++ 3.0.

What critical step am I missing here??!?

Thanks very much in advance...
posted by ostranenie to Computers & Internet (4 answers total)
 
I'm afriad I can't help you, but you might want to consider posting your question to one of the newsgroups - microsoft.public.pocketpc.developer for example.
posted by mr_silver at 5:55 AM on October 4, 2006


Is there an init string for the GPRS-modem you might miss? Just so you are really entering the internet zone defined by your telecom operator?

When I use my phone as a GPRS modem for a laptop, that's the one thing always troubling me.
posted by ijsbrand at 6:33 AM on October 4, 2006


I'm surprised there's no sample code in eVC that shows how to do this. It seems like a simple task. Try looking for sample code.

My experience with a PPC using Bluetooth over a phone is that apps don't start the connections themselves - they either just open the socket, triggering an automatic initiation of the default connection or they fail and require the connection to be started manually.

Also, the dev newgroup posted by mr_silver is probably a much better bet than here.
posted by GuyZero at 7:21 AM on October 4, 2006


Not sure if this will be useful to you, since it appears that you are handrolling something, but I also use my phone as a 'GPRS' modem for my laptop.* My data plan w/ t mobile requires me to use a WAP proxy to connect to any sites, although I will get a "connected" indication right when I link up. It took me a bit of searching to discover that this proxy existed, so maybe you are in the same situation.

See here for more info.

* quote unquote GPRS because I only get WAP speeds with my service plan.
posted by fishfucker at 10:18 AM on October 4, 2006


« Older How to fix my credit card?   |   Who said this? Was it Hitchcock? Newer »
This thread is closed to new comments.