For a couple weeks we've been trying to release a Bluetooth version of our game (iSamurai), but have been experiencing strange network problems ever since compiling for the 3.0 GM Seed. We've now had enough breakthroughs on our network struggles to share some (hopefully) useful info, and I'd like to see if anyone else has anything to add to the mixing pot.
We submitted a bug report and answered one of their follow-up questions, and started an official support request - and have been going back and forth with an Apple rep on this. He has provided some good direction and interesting tests, but there is no good solution yet and in fact
the latest recommendation is to NOT use the GameKit framework.
To cut right to the main issue:
- With the release of 3.0 GM seed, a service discovery process is now running that will look for peers over EITHER WiFi or Bluetooth, (switching back and forth using the single antenna available for both.)
- When that process is actively looking, various problems are caused with a current network connection that has already been established. Lags, and sometime even big lags and dropped packets.
- To stop the service discovery, you do something like [self.netServiceBrowser stop] after you've made the connection,
however it doesn't stop network problems from happening during the initial discovery process, which sometimes hangs one or both of the phones.
- When you turn off either WiFi or Bluetooth on the phones, the other type of connection (that you didn't turn off) is great, probably because the discovery process doesn't even try - no lags, no problems. Unfortunately this is something the user must do in their Settings (Right? Not sure what other options there are here.).
The leads to the amazing fact:
A bluetooth connection can be made using the 2.2.1 and earlier WiFi Picker, on Phones running 3.0, regardless of whether the new GameKit framework is used or not. People can get a Bluetooth connection with 2.2.1 apps just by upgrading to 3.0!
I have verified that a Bluetooth connection is possible with our currently available app, with phones that (now) have 3.0 - albeit not obvious, the Bluetooth connection is made using the WiFi Picker interface, and our Apple-mandated "No Network Found" message comes up.
To make absolutely sure, this last test was done and works even with WiFi off on both phones and all possible WAPs turned off - it IS a Bluetooth connection, being made with an app compiled to run on 2.2.1!
Any other solutions out there?
-Robert
http://toykite.com