We’re getting closer to finishing the Lookit iOS app using Appcelerator Titanium. The app calls a custom API on the Lookit server for both submitting pictures to the server and getting pictures, ratings, comments and other data about everyone else’s pics.
The user experience of our app is as important to me as getting the app to work correctly in the first place, and that includes making sure the app is responsive and usable on slow cell connections. Of our iOS beta testers, more than 80% of them have installed the app on an iPhone or iPad with 3G service.
Since most of our development happens in the iOS simulator on laptops with great wifi connections, we needed a way to slow down our internet connection to simulate a cellular connection.
You can limit the network traffic on your Mac to 3G-like speeds with three lines in the Terminal:
$ sudo ipfw pipe 1 config bw 30Kbit/s delay 350ms
$ sudo ipfw add 1 pipe 1 src-port 80
$ sudo ipfw add 2 pipe 1 dst-port 80
This works great when testing your apps in the simulator on your laptop, but clicking with your mouse on the screen and touching with your fat fingers on an iPhone are completely different experiences. Tanner and I each use iPod Touches as our development devices, which don’t have 3G chips – only wifi.
Testing the entire 3G user experience is possible on a device by slowing down your laptop’s internet connection to 3G speeds, sharing your laptop’s (now slower) wifi connection and connecting your iPod Touch to it.
To fake a 3G connection on your iPod Touch:
- Run the lines above, limiting the network I/O on your laptop to 3G speeds.
- Share your Internet connection from your Mac, essentially turning your laptop into a hotspot.
- Connect your iPod Touch to the new hotspot.
Returning your network’s connection back to normal is just as easy:
$ sudo ipfw delete 1
$ sudo ipfw delete 2
Someone should turn this into an app. I’d spend a buck on it because I’m a lazy bastard.
More info on the Lookit mobile apps »