简体   繁体   中英

Peer to Peer communication between iOS and Android devices

So I am a relatively new iOS developer but thanks to Stackoverflow, i managed to get peer to peer data communication for my app working without the need of a server using gamekit/GKSessions. Basically, one iOS device acts as a server and others just connect to it to receive app specific data.

Now, the app is currently being ported on Android and I was wondering if there is a way that I can make an Android device connect to the iOS app and behave the same way as ios app does. Android developers suggested alljoyn to be an optimum solution for android but that doesn't seem to be available yet for iOS.

Please suggest if you have any ideas on this front. If there is a solution that involves rework on iOS side as well then I am open to it!

In case, you or others tackling the same question in Jan 2013 needs an answer, AllJoyn is now ready for iOS too, amongst other platforms.

https://www.alljoyn.org/docs-and-downloads

I didn't have time to wait for alljoyn to be launched for iOS and sensing no other feasible solution that would fit on my timeline, I implemented a relay server in between to achieve this.

For others though, iOS binding is now available for alljoyn (www.alljoyn.org). I haven't tried it yet but the android version of my app works with alljoyn and it works perfectly so I assume it will do the same for iOS as well.

One limitation to be considered using alljoyn is that it cannot communicate between devices that are behind different subnets.

Venkat i suggest you to read and get some detailed information regarding P2P. This is a Good source , because you might get stuck if both devices are behind multiple Nat. but if your willing to go forward there is always a way. My suggestion would be an Relay, but you need to have a server, but the relay behaves like P2P. Look at the source above to get ideas.

我认为IOS和Android的最大对等连接数(最多8个对等连接)是有限制的,IOS和Android设备之间没有使用alljoyn测试连接性

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