Dave
Dave

Reputation: 8631

Communicating information from one iOS device to another

I am new to iOS development, I have a C#/.NET background so please excuse my ignorance. What are my options for communicating information from one iOS device (iphone/ipad) to another? To give some background and motivation, suppose I wanted a simple program with the following features to test students in math.

  1. Teacher enters some math problems and answers (3+4, 9*2, etc.). The "test" is sent/pushed to all students in the class (who could be at home, in another state. i.e. NO Bluetooth!).
  2. Students complete test and results are pushed/sent back to teacher. Here, I think sending the results via email would be fine.
  3. Students should not have to know when to go looking for tests or have to pull some file out of an email. In fact, they should get some notification when there is a new test ready to take, and their program should be able to pull the new test down.

My actual idea is more complicated. I felt this simple example gives the general idea and the challenges without giving away to much business information.

I suppose I could use a WebService and have the students interact with that. The students could get an email alerting them that a test is ready to take. I have no problem with the email alert, but I'm not keen on the WebService. It seems like an exta part that could fail (webserver down, etc.). I've researched this somewhat and come up with a couple of ideas which I would welcome feedback on. Or perhaps there is a much simpler way?

  1. Game Center is designed to transfer state information from one phone to another when a game is going on. At least that's my initial read of it. I'm not sure how you go about entering the ids or emails or something of all the phones you want to push some data to, and I'm not sure if it's appropriate to my case, but it seems promising. Reference: http://developer.apple.com/library/ios/#documentation/NetworkingInternet/Conceptual/GameKit_Guide/Introduction/Introduction.html#//apple_ref/doc/uid/TP40008304-CH1-SW1

  2. Run a web server on the master phone/ipad. Apparently you could run a web server on the teacher's device. I know I said I didn't want webservers or webservices involved, but I was thinking of external ones. If the teacher's device is out of commission, everything grinds to a halt anyhow. Again, if this could be configured so that only certain devices can access the webserver (those devices belonging to the 30 students), and there was a way for the webserver to announce, "Hey, new test available. Come and get it!", this would be a fine solution.

Can someone give me some ideas? Even better, point me to some tutorials/books/etc.? In the case of GameCenter, a very simple example would be nice. Notice I'm not using it for a full blown game.

Thanks, Dave

P.S. If someone happens to know the answers for Android too, that would be great. Although my first target is iOS.

Upvotes: 0

Views: 102

Answers (1)

tigloo
tigloo

Reputation: 654

You can use the Apple Push Notification Service to push notifications to your student's devices. If you are fine with emailing results, that would be a good back channel. However, it does require your students to have an active email account unless you want to take over the task of sending an email. Alternatively, upload the results to a server and process them there.

Upvotes: 1

Related Questions