简体   繁体   中英

Communication between Desktop Application and Windows Mobile Compact Framework c#

I am writing a desktop application that will have to communicate with a windows mobile application in the compact framework 3.5. The communication must occur over the internet between these two applications to send data between them on command if the connection is available.

The system will send messages and objects like Images between device and desktop application and check to see if the desktop can see the device by sending a command and have a timeout on response. (Application will then know that the device is not available). The mobile device will send a message to the desktop application when online as well that the desktop knows that the mobile is connected(Type of registering for communication)

Can someone please inform me of the best way to follow to accomplish this.

I did some research and found this site is near to something like event based driven communication I would want but do not have the availability of setting up an email on each device.

Battery life and internet open on device is not an issue.

Should I check in on working with the System.Net.Socket class for this type of communication between the two application and if so how will I set up so firewalls will not interfere and have my desktop application be seen over the internet by the mobile application ?

Hope someone can spread some light over this for me, if you have a answer please provide a link so I can read up on it.

your description is something basic. OK, regardless of what TCP/IP communication you decide for (HTTP, sockets) you must always have your internet router forward packages on a specified incoming port to your PC and the firwall must accept these incoming requests.

So, the device will have to send data to the PC and vice versa. So you need a server and a client on the PC and on the PC.

Possibly you can use an already available cloud like Dropbox to exchange files between PC and device.

What are about your skills in socket programming? The main server (PC) must be written multithread to be able to server multiple device client requests.

A simple socket comm is done in my SocketWedge [http://www.hjgode.de/wp/2010/05/27/transmit-data-from-winmo-device-to-pc-socketwedge-and-socketsend/]. A way of multithreaded communication using a web server on the device is available here [http://www.hjgode.de/wp/2012/10/19/windows-mobile-a-simple-web-server-with-extended-features/].

Will SQL with data synchronization be a possible choice?

Can you describe the application in more detail?

~josef

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM