I'm Keyvan Nayyeri, a 25 years old Ph.D. student at
the Computer Science department of
the University of Texas at San Antonio.
I'm also
a Software Architect and Developer and previously held a B.Sc.
degree in Applied Mathematics.
This is my blog where I publish content about various topics specifically Programming Languages and Compilers, Software
Engineering, and Programming.
Fahrenheit Marketing is a top-dog Austin Web Design firm offering a complete portfolio of online services.
Recently I started to write a new post series to share my experiences and show the development process of an educational iPhone application that we’re building for our graduate Software Engineering course this semester. After giving a general overview, I talked about the vision of our application, and now I want to talk about the deployment process of the application even though we haven’t finished the development of our project.
A very common part of any development process is deployment of the software into the host machine or machines. iPhone/iPod Touch development is no different and you need to follow some specific steps in order to deploy an iPhone application.
One of the early tasks in development of our educational iPhone application was deploying a sample application, called MoveMe, to our devices, so we understand the deployment process. Interestingly, I found this step the most challenging and frustrating part of iPhone development for myself and my teammates to this point.
Basically, iPhone application deployment process consists of two groups of steps: legal steps to obtain specific permissions from Apple and technical steps to deploy the application to a device.
Here at the beginning I’d mention that we are using an Apple University Program that makes some points a little different, however, I think that I can assume the same major steps for deployment of a commercial iPhone application as well.
As I had stated before, development of an iPhone application can be done only on a Macintosh machine and you can’t use other platforms such as Windows or Linux to accomplish this goal. Likewise, you can’t use the available Mac Virtual Machines to do this.
In essence, these are the steps to be followed to deploy an iPhone/iPod Touch application to a device:
As you see, this is very different from the regular deployment process for other mobile platforms that have a few straightforward steps. In this post, I try to give a brief explanation of each step. As you see in a moment, such a long process is error-prone and can be difficult and it is indeed. In my experience almost all my classmates had problems with one or more steps of this process.
The first step for a team leader or administrator is to go online to the iPhone Developer Program and enroll to create an account. Enrollment costs money and you need to pay $99 for a Standard program account or $299 for an Enterprise program account. There is a short comparison of these programs on the Apple website that you can read. We were lucky to use our university accounts to be able to log into this portal!
This is one of the very bad points that I found about Apple. This is beyond the scope of this post but I see no point in this mechanism to enforce developers and companies to pay you in order to develop something even very simple for your platform.
After logging into the portal, you need to navigate to the iPhone Developer Program Portal to follow the next steps. It’s worth mentioning that you have access to some good guidelines and videos on this portal that can help you learn how to follow the steps to deploy your application.
In the second step you need to add your team members to the portal so they receive an invitation code via email to register on the portal and register.
If you’re a member of a team, you may start your deployment process from here because your team leader, administrator, or manager has gone over the first step and you only need to use the invitation code to register on the portal.
The third step is to generate a Certificate Signing Request on your Mac machine. This can be done by opening the Keychain Access application.
Go to the Preferences menu and set Online Certificate Status Protocol (OSCP) and Certificate Revocation List (CLR) to Off.
Choose Certificate Assistant and then Request a Certificate from a Certificate Authority, then enter your information. Don’t forget to use the same email address that you have used on the portal. Choose to generate a 2048 bits key size with RSA algorithm for your certificate. Finally, save the generated certificate somewhere on your machine.
Go to the iPhone Developer Program portal and navigate to the Certificates page. Click on the Request Certificate button to upload your certificate, then wait for this certificate to be approved. Certificates must be approved by the team administrators and they will be notified by email. When they approve the request, a Download button appears next to your certificate in the Certificates page and you can download the file.
After downloading the certificate to your machine, you need to install it on Keychain Access so it appears in the list of certificates with the appropriate name.
The other task that has to be done by the administrators is to authorize the devices that host your applications. Each iPhone or iPod Touch device has a 40 character unique identifier associated with it that can be found in iTunes, Xcode, or iPhone Configuration Utility.
Administrators need to go the iPhone Developer Program portal and choose the devices page to add each device with an appropriate name and its unique ID.
Each iPhone/iPod touch application has a unique identifier that should be associated with the application and be added to the Provisioning Profile. Application IDs enable some features in iPhone OS 3.x such as Push Notifications.
Application IDs can be either a unique ID or a wildcard. The latter type of application ID can be used for several applications.
There are some details about different components of an application ID called the Bundle Seed ID and Bundle Identifier but I don’t go over these details here.
If you need to use an application ID for Apple Push Notification service, then you need to follow additional steps as well.
After generating the application ID by the administrators, a provisioning profile name and ID should appear in the Provisioning page on the program portal where developers can click on the Download button to get their provisioning profile.
Next you need to add this Provisioning profile to your Xcode development IDE. Doing this correctly, you should see the name of your Provisioning profile in the Organizer window.
Having your application developed, and the above steps completed successfully, you can deploy the application to the authorized device. You can test you applications using the Xcode Simulator for different versions of the iPhone OS, but obviously, that’s not enough and you need to deploy the application to a real device to make sure everything works properly.
After selecting your device from the list of devices in the drop down list, you need to choose your application name in the Targets sub-tree in the left pane, and then click n the Info item in the menu.
This opens up a new window where you need to go to the Build tab and find Code Signing setting item and select your provisioning Profile from the list that appears next to the Code Signing Identity.
Now have to open the Properties tab and put your application ID in the Identifier textbox.
At this point, you should be able to click on Build and Go button in Xcode to build and deploy your application. If everything is set properly, then you should see your application deployed to the device after a few seconds.
Fahrenheit Marketing is your resource for Search Engine Optimization in Austin.
ASeventhSign
Feb 23, 2010 1:38 PM
#
Dew Drop - February 23, 2010 | Alvin Ashcraft's Morning Dew
Feb 24, 2010 6:45 AM
#
Keyvan Nayyeri
Mar 02, 2010 11:08 PM
#
Keyvan Nayyeri
Mar 19, 2010 8:38 AM
#
Keyvan Nayyeri
Apr 08, 2010 10:14 PM
#
Keyvan Nayyeri
Apr 19, 2010 3:13 PM
#
Keyvan Nayyeri
Apr 30, 2010 10:33 PM
#
Keyvan Nayyeri
May 03, 2010 12:42 PM
#
Keyvan Nayyeri
May 06, 2010 10:42 AM
#
Patrick Martin
Jun 06, 2010 11:04 PM
#
You saved me a lot of time as OS X and the iPhone development platform is entirely new to me and I was struggling.
- Pat
Leave a Comment