7 Replies
      Latest reply on Jan 28, 2019 7:04 AM by Henrik@ tetrapak
      newguy1124 Level 1 Level 1 (0 points)

        Hi all, I have been coding a project for a while and now that I am testing it. The multipeer connectivity seems to work great when  the two devices are on a wifi connection. But nothing seems to work when I am only on bluetooth both iphones don't seem to find eachother, I have made sure both iphones are discoverable on bluetooth but nothing. Each phone just has its " searching " on the Multipeer on the app. I have no idea why. Does bluetooth not work anymore. sorry if this is a dumb question is just really don't know and can find any answers. Lastly, if bluetooth doesnt work are there any other options I can use to have two phones connect without the use of wifi. Or can I use Multipeer to have phones connect through carrier network connection like verizon and stuff idk. I really dont wan't to recode this project I spent a lot of time lol . Any help is great help. Thanks again for your replies.

        • Re: multipeer connectivity, wifi connection works great but bluetooth seems to be dead
          eskimo Apple Staff Apple Staff (12,285 points)

          Does bluetooth not work anymore.

          In iOS 11 we disabled peer-to-peer networking over Bluetooth [1].  See this post, and the mailing list post it references, for details.

          if bluetooth doesnt work are there any other options I can use to have two phones connect without the use of wifi.

          Is your concern Wi-Fi in general, or infrastructure Wi-Fi.  Multipeer Connectivity continues to work just fine over peer-to-peer Wi-Fi.

          Share and Enjoy

          Quinn “The Eskimo!”
          Apple Developer Relations, Developer Technical Support, Core OS/Hardware
          let myEmail = "eskimo" + "1" + "@apple.com"

          [1] At the NSNetService level, which affects Multipeer Connectivity as well.  The underlying support is still present, accessible via the <dns_sd.h> API, but it’s not hard to imagine it go away at some point in the future.

            • Re: multipeer connectivity, wifi connection works great but bluetooth seems to be dead
              newguy1124 Level 1 Level 1 (0 points)

              Hello @eskimo,

              Thank you for your reply. Well, I have a few concerns I guess. If bluetooth doesn't work is there any way I can use network connection in multipeer? if so, How? I haven't tried it. Is there any other solution. Becasue Wifi limits the use because to my understanding and I could be wrong. For peer-to-peer under multipeer to work over Wifi don't both iphone devices have to be connected to the same network or no?. And if there is any way I could just use network connection it would solve the issue. I just don't know if that is possible under multipeer but again I have not tried it. What are my possible alternatives? I really like multipeer connectivity.

               

              Thank you

                • Re: multipeer connectivity, wifi connection works great but bluetooth seems to be dead
                  eskimo Apple Staff Apple Staff (12,285 points)

                  Apple platforms support peer-to-peer Wi-Fi, which allows devices to communicate even if they’re not on the same infrastructure Wi-Fi network.  This technology is used by AirPlay, AirDrop, and so on.  You shouldn’t notice any difference between this and peer-to-peer Bluetooth (except that it’s faster, and has longer range :-).

                  I’d advise you try this out for yourself:

                  1. Take your existing Multipeer Connectivity app and run it on two devices.

                  2. On both devices, turn off Bluetooth (in Settings, not Control Center).

                  3. Then go to Settings > Wi-Fi > YourNetwork>, and tap Forget This Network.

                  4. Repeat step 3 as long as iOS keeps auto joining networks.

                  5. Run your app on both devices and wonder at the fabulosity that is peer-to-peer Wi-Fi!

                  Share and Enjoy

                  Quinn “The Eskimo!”
                  Apple Developer Relations, Developer Technical Support, Core OS/Hardware
                  let myEmail = "eskimo" + "1" + "@apple.com"

                    • Re: multipeer connectivity, wifi connection works great but bluetooth seems to be dead
                      newguy1124 Level 1 Level 1 (0 points)

                      Hi, @eskimo ,

                       

                      thanks for all your help. I have one last question. Is there any work around to use network connection? or any alternatives, that allow both wifi and network connection to allow two devices to connection?

                       

                      Thanks

                      • Re: multipeer connectivity, wifi connection works great but bluetooth seems to be dead
                        Lucky7 Level 1 Level 1 (0 points)

                        One case scenario when MultiPeer Connectivity doesn't work:

                         

                        - On iPhone, enable Personal Hotspot

                        - On iPad, connect to Personal Hotspot

                        - Try to connect via MultiPeer Connectivity

                         

                        Result:

                         

                        2018-10-24 13:31:09.142264-0400 MyApp[8841:3514757]  [ERROR] ICEStopConnectivityCheck:2688 ICEStopConnectivityCheck() found no ICE check with call id (1336709656)
                        peer <MCPeerID: 0x281ad83b0 DisplayName = iPad Pro> didChangeState: Connecting
                        2018-10-24 13:31:09.261354-0400 MyApp[8841:3514757] [MCNearbyServiceBrowser] Browser got invite response with nil connectionData.
                        2018-10-24 13:31:19.301376-0400 MyApp[8841:3514844] [GCKSession] Not in connected state, so giving up for participant [4FAC9218] on channel [0].
                        2018-10-24 13:31:19.301648-0400 MyApp[8841:3514844]  [ERROR] ICEStopConnectivityCheck:2688 ICEStopConnectivityCheck() found no ICE check with call id (1336709656)
                        2018-10-24 13:31:19.301930-0400 MyApp[8841:3514844] [GCKSession] Not in connected state, so giving up for participant [4FAC9218] on channel [1].
                        2018-10-24 13:31:19.302219-0400 MyApp[8841:3514844]  [ERROR] ICEStopConnectivityCheck:2688 ICEStopConnectivityCheck() found no ICE check with call id (1336709656)
                        2018-10-24 13:31:19.302405-0400 MyApp[8841:3514844] [GCKSession] Not in connected state, so giving up for participant [4FAC9218] on channel [2].
                        2018-10-24 13:31:19.302594-0400 MyApp[8841:3514844]  [ERROR] ICEStopConnectivityCheck:2688 ICEStopConnectivityCheck() found no ICE check with call id (1336709656)
                        peer <MCPeerID: 0x281ad83b0 DisplayName = iPad Pro> didChangeState: NotConnected
                        

                        The same app works fine when wi-fi is enabled on both devices. The app runs on iOS 12.

                        • Re: multipeer connectivity, wifi connection works great but bluetooth seems to be dead
                          Henrik@ tetrapak Level 1 Level 1 (0 points)

                          My MultiPeer Connectivity works fine on wifi but when using Personal Hotspot it cant connect.

                          - On iPhone, enable Personal Hotspot

                          - On iPhone, connect to Personal Hotspot

                          - Try to connect via MultiPeer Connectivity

                           

                          1. InvitePeer gets called

                          2. DidReceiveInvitationFromPeer is called and invitationHandler(true, session) is called

                          3.Session DidChangeState gets called with connecting

                          4. Session DidChangeState gets called with NotConnected and connection failes.

                           

                          Everything works as expected on WIFI is there somthing else i need to do on Personal Hotspot ?