0

I was wondering what the best way to open a data channel between a phone and a laptop doesn't have to guaranty that the packets make it (ie UDP) and only has to be one way laptop -> phone. This is to provide key live information that occurs in my software on the phone. old data is useless so a 'reliable' like TCP. The devices I want to support are Android for phone and Windows for the laptop. This application doesn't get used where a access point is available so the connection will be peer to peer. The current method I have is to get the user to setup a wifi adhoc connection on their laptop and connect there phone from there but this is to many steps and I would rather a zero config solution. It can use bluetooth or wifi. I am using dot net on both pc and android (xamiran). cheers

Saspiron
  • 180
  • 1
  • 10

1 Answers1

0

You probably want to look at something on the lines of these the Network Service Discovery. I don't have an example to hand sorry but there seems to be ample of code examples and documentation.

Android:

Network Service Discovery

http://developer.android.com/training/connect-devices-wirelessly/nsd-wifi-direct.html

Computer App:

Network Service Discovery Broadcaster in C#

C# How to do Network discovery using UDP Broadcast

Basically your app will listen to network broadcasts on the wifi (sent to the subnet mask) and if it gets one perform a given action.

Here are some relevant Stack overflow posts as well:

Network Service Discovery

Hope this helps!

Community
  • 1
  • 1
JodiMiddleton
  • 310
  • 1
  • 8