One of the sticking points with developing iPhone apps for me was transitioning to a Mac computer. I've never been a mac person and have always worked on a Windows PC. All of my programming experience has been on a PC. I've developed VBA applications within Excel in addition to numerous websites.
But since you need a Mac to develop iPhone apps I took the plunge and got an iMac. It's a beautiful computer but have had lots of difficulty transitioning between Mac (developing apps) and my PC (developing websites). Just as installing xcode (iPhone app development software) and getting that working I found installing Titanium to be a bit of a hassle mainly to my inexperience with a Mac. Here are some problems I ran into to hopefully save you some time.
Titanium does have a very through guide available on their website. I don't want to rehash what's been created there but here are a few points:
- I have a Mac with OSX 10.6.4 and had no problems with Java. Already had xcode and apple SDK installed so that step was not a problem.
- The android SDK gave me fits.
I'm still unsure what everything is in the list but this setup allowed me to create android apps. If you're missing something go to the available packages and make sure to check it. Also, after you click to install selected make sure you select "accept all" to make all the packages have a Green check next to them. Otherwise you haven't agreed to the licenses and the packages won't download.
The final step for the android sdk is copying the ADB file into the tools folder. Again, it's all explained in the guide but initially I skipped right over this step. As far as I can tell Google changed the location of the adb file in it's latest SDK release. Titanium, however, needs it to be in a certain place. So, while the guide talks about symbolic links I just duplicated the adb file from platform-tools folder to the tools folder and that did the trick.
- Download Titanium
- Download Netbeans
- Your first app
After getting very frustrated and considering shelving the whole Titanium project I realized my mistake. You have to select Project Type: "Mobile" at the top of the form in order to test your app on the iPhone/Android simulator (the whole point for me!).
- Create new Project in NetBeans
For your sources folder select the folder you specified in the step above. Avoid the frameworks. You should now be able to open App.js and see the underlying code. Make a few edits (I changed "I am a window" to "I am Danny"), click save.
- Launch your app
Go back to Titanium and under the "test & package" tab select the emulator of your choice and click launch. For iPhone I had no problems and it seems, at least on my computer, to run way faster than the android emulator which takes forever to load.
For the android simulator make sure your SDK starts with "API." So on my computer I have these chocies: 1.6, APIs 1.6, 2.1-update1, APIs 2.1-update1, 2.2, and APIs 2.2. For the emulator to work the SDK selected must start with API (the ones bolded above). Finally, for some reason the Android emulator, when launched, is in locked mode. Sometimes this caused problems so the easiest thing I found was that as soon as possible when the Android Screen popped up drag the lock button from the left to the right side of your screen. Titanium was usually on the "this will take awhile" step (shown in the titanium screen log) so the emulator was usually unlocked by the time Titanium was ready to run my test app.
No comments:
Post a Comment