Multiplayer Connectivity: iOS and Android

I work with a team in a cross-platform application (Android and iOS).

This application is intended to use the concept of beacons and / or mesh networking or multipeer-connectivity . At the moment, our team uses Xamarin as our development environment to create a single code base.

After significant research (obviously not significant enough), I was able to find only the following resources.

http://altbeacon.org/

http://altbeacon.imtqy.com/android-beacon-library

https://github.com/octoblu/meshblu

https://github.com/octoblu/MeshbluKit-iOS

https://github.com/octoblu/MeshbluKit-Android

https://github.com/CharruaLab/AltBeacon

https://blog.xamarin.com/play-find-the-monkey-with-ios-7-ibeacons/

A few questions:

Does AltBeacon support cross-platform communication?

Is there a built-in way to create Multipeer / Mesh networks in Xamarin / C #?

Is Estimote required to use stickers / rating beacons or can a smartphone act as a beacon?

What I'm looking for:

  • A way to establish connections between iOS and Android devices when users do not have a Wi-Fi connection or โ€œdataโ€.

  • In fact, each device will act as a โ€œbeaconโ€ to each other.

  • Xamarin / C # is a must (although I will hear other solutions if they are convincing)

  • This scenario:

Two people go against each other. Both applications work on their phones. One person has an iphone and the other has an android. Their applications run in the background (their phones are in their pockets or in their hands and are locked .. that is, not in "use"). When people pass each other, their phones detect each other and send / receive text from each other.

Prior to this event, User 1 used the application to save a note containing the following information ...

"The reservoir is operating normally."

While User 2 used the application on his device to save a note containing the following information ...

"Hand rail slightly damaged"


After users switched to each other, the next time they open their application, they should see one updated note ...

"Vodophone is working fine

Hand rail slightly damaged. "


Possible solutions: TBD

Rejected Solutions: TBD

-

Current Findings: Currently there are applications such as FireChat, ViewRanger (I believe), or the Xamarin Find a Monkey example. Apple uses iBeacons in its stores, while others use AltBeacon for Android devices. I came to the conclusion that this is certainly possible, but I am looking for how to perform it best when both platforms serve as these beacons to each other.

+7
android c # ios xamarin altbeacon
source share
2 answers

From the description of your scripts, you can break it into two simple steps:

  • Nearby device discovery
  • Exchange simple data upon detection

Mandatory: this should work on the i-th platform of i-OS and Android

I believe that the best way to approach this is to use BLE, which is supported by both platforms (some are better than others).

On iOS, the device can act simultaneously as BLE Central and BLE Peripheral, while on Android, the situation is more complicated, because not all devices support the state of the BLE peripheral device. In addition, the Android BLE stack is very unstable.

If your use case has a feature, I would suggest looking at Frameworks and libraries that can achieve this for you, without having to create it from scratch.

For example: http://www.p2pkit.io , http://www.intromi.co and http://www.underdark.io or google nearby

As for using native code with Xamarin, you can just create a bridge (binding: https://developer.xamarin.com/guides/ios/advanced_topics/binding_objective-c/ ).

Disclaimer: I work for Uepaa, developing p2pkit.io for Android and iOS.

+3
source share

โ€œWhat I'm looking for: A way to establish connections between iOS and Android devices when users donโ€™t have Wi-Fi orโ€œ data. โ€In fact, each device will act as a beacon to each other. Xamarin / C # is mandatory (although I will hear other decisions if they are convincing) "

BLE (Bluetooth Low Energy) is what you are looking for, not just a part of iBeacon.

iBeacon is built on top of the BLE stack, setting the "vendor specific data" (which Apple did) of the BLE ad package. iBeacon operates in BLE broadcast mode and transmits only three UUIDs of data, primary (16-bit), minor (16-bit). In addition, RSSI (signal strength is transmitted / calculated).

The bad news is that if you use the location of the iOS kernel or any other iBeacon library, it will work with the UUID, primary, secondary, RSSI. You cannot transfer any additional data using the standard iBeacon protocol.

  • What you are looking for is CoreBluetooth for iOS or the Bluetooth Low Energy Library on Android.
  • You probably need to create your own profile using the GATT / ATT BLE layers (since none of the existing ones will probably suit your request)
  • You need to develop an application for setting up BLE profiles.

Remember that BLE is low power and low communication speed, where you can expect (from my tests on different platforms) up to 20 bytes every 25-30 ms

Hope this helps ...

+2
source share

All Articles