This isn’t really Xojo related, although I’m sure that someone is/has or will delve into this subject if not already…
I am playing with Apples MultipeerConnectivity, and have most everything working… but I’d like to know which device was the first to start the app.
Here is the flow as best I can tell…
- Device A starts up the app… it adds its connection info to an internal dictionary, and waits
- Device A advertises its existence… gets no response
- Device B starts up the app… and it add its connection (remember the dictionary are local to each device)
- Device B advertises its existence and Device A invites it to the party, and both devices add the other to their respective dictionary
at first I thought I could go by, if it were the first entry into an empty dictionary… but each device ends up first in its own
plus if there are a dozen devices, and whoever was “first” goes away, another device needs to take its place…
A Master/Slave arrangement for lack of a more politically correct description.
It is to insure that only one person in the “network” can perform certain “admin” events. Since its BT, everyone will most likely be in the same room, but the app requires a “master” active at all times, even if its the only device running.