=

Adhoc installation issues on Windows PC

November 5th, 2009 by Ravi Korukonda 3 comments »

As an iPhone developer I have lately been observing many errors while installing Adhoc builds on my testing/friends iPhones or iPodTouches. Many of them have been really hard to fix and some have just been “nothing but frustrating”.

There was a case where what ever I did, did not work. Many attempts to install using iTunes after trying to change certificates, provisioning profiles have failed. Even the “iPhone Configuration Utility” failed to install the app. I had actually lost all hopes getting it installed on this device. But after a little prayer and just a little hope left, it just worked.

Why did it work? I do not have any answer. Can’t still figure it out. And that was the first time I tried installing an Adhoc build on a device for a Windows user!! Is it really so hard?

adhoc_issues_on_windows

Could not install application on device: Error: A signed resource has been added, modified or deleted.

The image that you see here, is another failed attempt at installing an Adhoc build for a Windows user. But this got resolved real quick.

The reason: Mac allows file names to contain some special characters (like ‘*’) which are not valid on a Windows PC. This is one thing you can check if you come across errors of above kind. But not all of them will be the same as above.

If any one else has faced a similar problem and found a definitive solution, let us know here.

Share and Enjoy:
  • Digg
  • Sphinn
  • del.icio.us
  • Facebook
  • Mixx
  • Google Bookmarks
  • LinkedIn
  • N4G
  • Twitter
  • Yahoo! Buzz
Tags: iphone adhoc installation, iphone adhoc issues, iPhone App Developers, iPhone app Developers help, iPhone App Development help, iphone configuration utility

Utility for iPhone app developers: iSimulate

November 4th, 2009 by Rama Krishna 1 comment »

Tired of having to install your application on a device for every little change that you make in your code? No!! You test it on the iPhone Simulator!!
What if the application uses GPS and Accelerometer? You cannot test it on the iPhone Simulator.

Here comes iSimulate from vimov to your rescue. People at vimov have created a really useful utility for developers to test their applications which employ GPS and Accelerometer on the iPhone Simulator. Lots of time saved between installs right!!

iSimulate is an application which you download and install on your device to send accelerometer and GPS details to the app running on the iPhone Simulator. The app must of course embed the iSimulate library to be able to receive those details. All it takes to install the iSimulate app on your device, embed the library in your application and start using it is just around 5 minutes.

The newer releases of iSimulate even support video streaming. You can actually see the game or app on your iPhone or iPodTouch even though it’s running on the iPhone Simulator. This enables you to provide very accurate touches to the Simulator. This is a giant leap forward from it’s first days where you had screen filled with Accelerometer graph to simulate touches!!

iSimulate really makes testing your apps easy and quick. Go get your apps on to AppStore that much quicker!!

Share and Enjoy:
  • Digg
  • Sphinn
  • del.icio.us
  • Facebook
  • Mixx
  • Google Bookmarks
  • LinkedIn
  • N4G
  • Twitter
  • Yahoo! Buzz
Tags: iPhone App Developers, iPhone Application Development, iPhone SDK Help, iphone simulator

iPhone SDK 3.1.2. released for iPhone app Developers

October 9th, 2009 by Ravi Korukonda 1 comment »

Apple released iPhone SDK 3.1.2 on Thursday Oct 8, the release email sent to iPhone App Developers by Apple states this:

iPhone SDK 3.1.2 is now available on the iPhone Dev Center. If you have updated your iPhone app development devices to iPhone OS 3.1.2, you will need to download and install the new iPhone SDK to continue your iPhone app development.

A version of iPhone SDK 3.1.2 is also available to developers who are running Mac OS X Snow Leopard. Please ensure you select the appropriate SDK based on your iPhone app development environment.

iPhone SDK 3.1.2 is now available

iPhone SDK 3.1.2 is now available

Share and Enjoy:
  • Digg
  • Sphinn
  • del.icio.us
  • Facebook
  • Mixx
  • Google Bookmarks
  • LinkedIn
  • N4G
  • Twitter
  • Yahoo! Buzz
Tags: iPhone App Developers, iPhone App Development, iPhone Development help, iPhone OS 3.1.2, iPhone SDK 3.1.2, xcode 3.1.4, xcode 3.2.1

Apple Announced App Store Resource Center for iPhone App Developers

September 21st, 2009 by Ravi Korukonda No comments »

Apple announced App Store Resource Centre, a Single destination is designed to make it easier for iPhone App Developers to find details on everything you need to know about distributing your iPhone app on the App Store — from how to prepare for app submission to managing your app once it’s been posted.

Preparing iPhone apps for App Submission
Get started with iTunes Connect, including setting up your user accounts, submitting contracts, tax and banking information, and gathering application information.

App Store Approval Process
Ensure your application is ready for submission and learn what to expect during the app approval process.

Managing iPhone Apps on the App Store
Make the most of your presence on the App Store and learn what you can do to manage your app once it has been posted.

Share and Enjoy:
  • Digg
  • Sphinn
  • del.icio.us
  • Facebook
  • Mixx
  • Google Bookmarks
  • LinkedIn
  • N4G
  • Twitter
  • Yahoo! Buzz
Tags: App Store help, iPhone App Developers, iPhone app Developers help, iPhone App Development

Memory Issues in iPhone OS 3.0 : Sample Code

August 26th, 2009 by Ravi Korukonda 1 comment »

As mentioned in a previous article by Rama Krishna the memory issues in iPhone OS 3.0 relating to UIImageView can be reproduced easily. And here is such a re-production. You can download the iPhone sample application and see for yourself what the problem is. Just open the project, build it for the device (not the simulator) and run it with Instruments (ObjectAlloc) to see a nice little upwards running ramp developing on screen.

Oh!! but remember to run the app on iPhone OS 3.0 and not on iPhone OS 3.1 (the bug has apparently been patched for this version)

Share and Enjoy:
  • Digg
  • Sphinn
  • del.icio.us
  • Facebook
  • Mixx
  • Google Bookmarks
  • LinkedIn
  • N4G
  • Twitter
  • Yahoo! Buzz
Tags: iPhone App Developers, iPhone app Developers help, iPhone Application sample code, iPhone OS 3.0, iPhone OS 3.0 issues, iPhone OS Bugs

Custom URL schemes and Launching other applications — Best Practices for iPhone OS 3.0

August 24th, 2009 by Rama Krishna No comments »

How to open other applications like phone dialer, SMS, Safari, Google Maps, iTunes or AppStore or any other iPhone application?

“openURL” is the API to use to achieve any of the above and many more.
If you need to let your application users quickly dial APPLE from within your app, just include the following line

[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"tel:8006927753"]];

Similarly, you could initiate SMS application by using openURL with “sms: “, but unfortunately you cannot fill in the SMS content as Apple does not yet support it.
There are many more things you could do with this API like launching Google Maps, Safari with any website like you want or even the AppStore links to your apps which you want the users to buy.

Checking support for URLs of other applications
Until the release of iPhone OS 3.0 it was not possible to find if there are any applications installed on the device which handle the URL scheme you are about to use. But now it is possible through the following API

- (BOOL)canOpenURL:(NSURL*)url

Call the above API before using “openURL” to make sure your call will “certainly” be handled by a registered application. If you were developing an iphone app which lets a phone call be made from within it, do the following

// this will fail if the device is an iPod
if ([[UIApplication sharedApplication] canOpenURL:[NSURL URLWithString:@"tel:111"]])
{
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"tel:111"]];
}
else
{
// show an Alert here indicating that the call can’t be completed
}

Apart from using “canOpenURL”, do check the return value from “openURL” too and take appropriate action.

You should also use “canOpenURL” to find out if any features (like calling a number and SMS) that are not accessible on iPod should be disabled or hidden. Showing “phone” icons and letting them be clicked in your application on an iPod is a sure shot way to get your application rejected for uploading to AppStore.

Registering and handling custom URL schemes
If you are developing a great tool and can be used by other applications, you can register custom URL schemes and implement them. To create custom URL schemes just add them to your application’s “info.plist” file.

  • To the root element of your application’s “info.plist” file, and a row with key named “URL types”.
  • Expand it to find “item1″ in it, expand it and edit the value for key “URL identifier” to look something like “com.yourcompany.yoururlscheme”
  • Add another row to “item1″ with key “URL Schemes”. Type in the first few characters of your URL scheme.
    For an example, if you wish to use url formats like abc://part1/part2, just enter “abc” for URL Schemes

Once you have created and registered your own URL formats/schemes, you can handle incoming URL requests by implementing the following UIApplicationDelegate method

- (BOOL)application:(UIApplication*)application handleOpenURL:(NSURL*)url

Before parsing and/or handling the URL, make sure it is in the right format and follows all rules of your URL scheme.

The above method was the only place where you can handle incoming URLs until iPhone OS 3.0 arrived. For iPhone OS 3.0 and above, the preferred place to handle incoming URLs is

- (BOOL)application:(UIApplication*)application didFinishLaunchingWithOptions:(NSDictionary*)launchOptions

This method should return whatever “handleOpenURL” API would have returned if it were implemented. If you implement the above delegate method of UIApplication, IPhone OS will not invoke the following methods

- (void)applicationDidFinishLaunching:(UIApplication*)application
- (BOOL)application:(UIApplication*)application handleOpenURL:(NSURL*)url

Share and Enjoy:
  • Digg
  • Sphinn
  • del.icio.us
  • Facebook
  • Mixx
  • Google Bookmarks
  • LinkedIn
  • N4G
  • Twitter
  • Yahoo! Buzz
Tags: Best Practices for iPhone OS 3.0, iPhone App Developers, iPhone app Developers help, iPhone App Development, iPhone Custom URL schemes, iPhone OS 3.0, iPhone SDK Help

iPhone application approval process — Dubious

August 22nd, 2009 by Rama Krishna 1 comment »

There are many stories on the Internet of iPhone app developers who have been harassed by the Apple’s approval process for applications. This article is not of such types, but an example of their standards in reviewing applications.

Apple says, you should not advertise or disable features in an iPhone or iPodTouch application in order to get people to buy some other app. But that is exactly what Rope’n'Fly did with their lite version app and got away!!

Rope’n'Fly advertises their high scores feature in the lite version app by saying it is not available for “training” mode. That may be a nice mask, may be high scores are not available for training mode even in the full version, but when the lite version app is considered as an app on its own that is “illegal”.

Rope’n'Fly is great and is my current favorite game for the iPhone, but did they do any thing to get the app go through the review process without any hiccups? Some of mine don’t seem to get that privilege!! Infact, one my apps which was approved the first time, was rejected (citing a UI issue, which I never knew was a problem) when I tried to update it.

Wish all developers the best of luck with their application approval process for iPhone!!

Share and Enjoy:
  • Digg
  • Sphinn
  • del.icio.us
  • Facebook
  • Mixx
  • Google Bookmarks
  • LinkedIn
  • N4G
  • Twitter
  • Yahoo! Buzz
Tags: iPhone App Development, iPhone application review

Apple at it again!!

August 19th, 2009 by Rama Krishna 3 comments »

Apple’s release of iPhone OS 3.0 was eagerly awaited by the iPhone developer as well as the user community alike. But since it has been released I haven’t been able to get a good night’s sleep, not because of the cool new features it had using which I could create new exiting applications, but because of the bugs it has in it’s new iPhone OS 3.0.

Ever since Apple has released the new iPhone OS, I have been looking around for a fix to the problem I have seen with UIImageViews. Frantically “Google”ing for a fix, searching Apple iPhone Documentation again and again just to see if I have missed anything in the Release Notes and Change Logs of the iPhone SDK for UIImageView have not yielded any result. My self imposed deadlines to update all my apps for iPhone OS 3.0 have been breached and a resolution was not in sight.

The bug in UIImageView was its memory usage. As long as an image on screen is left alone after being created, nothing happens. But if you have any sinister designs on your mind, of moving/resizing the image on screen memory usage starts increasing. And there is no way you could do anything to bring the memory usage down, even releasing the image view object does not work.

And the most important finding in this issue is that “there are no memory leaks”. All the memory allocated is always being used!! That is what I had to believe, but performance of my applications on iPhone was rapidly falling down with the amount of time spent on it. Clearly indicating to me that there was something odd with the new iPhone OS.

A detailed bug report that I sent to Apple received a reply stating

This is due to a bug in the graphics system that mis-reports how it is allocating memory to ObjectAlloc, which causes it to display memory usage as continuously increasing.
If you attach the Memory Monitor instrument to your sample application, you will find that the Real Memory usage stays constant through out the application’s execution, indicating that while ObjectAlloc believes memory usage is increasing, it really is not.

For a couple of days, I was devastated at receiving that reply. So, no way out for me from this situation? Are all my app users going to give me bad ratings for no fault of mine?

Fortunately, I received another e-mail from Apple Support acknowledging that

this is a known issue, which is currently being investigated by engineering

Obviously someone else has already reported the issue, but the above response is only a “consolation prize” for me and nothing in the equation between me and my application purchasers changed. They are still going to complain that my apps are resource hogging and give them bad ratings.

This issue seems to be fixed in iPhone OS 3.1 and beyond, but the damage is already done!! Will all iPhone/iPodTouch users update their devices promptly?

Hope your applications are not plagued with these problems, and/or you have found an alternative to overcome this problem.

Happy programming!!

Share and Enjoy:
  • Digg
  • Sphinn
  • del.icio.us
  • Facebook
  • Mixx
  • Google Bookmarks
  • LinkedIn
  • N4G
  • Twitter
  • Yahoo! Buzz
Tags: iPhone App Development, iPhone OS, iPhone OS 3.0 issues, iPhone OS Bugs

Effective ways of handling Interruptions in iPhone App Development

August 18th, 2009 by Ravi Korukonda 4 comments »

It is a known and acknowledged fact that user’s experience with your iPhone app is of paramount importance in keeping them glued to it. Towards that, handling interruptions gracefully in an iPhone app plays a key role.

iPhone being a “one app at a time” device, apps get interrupted by incoming Phone Calls, SMSs, Calendar Events, Alarms or Push Notifications from other apps on the device.
The iPhone SDK provides a few methods in UIApplicationDelegate which can be implemented to handle the interruptions and keep user’s experience as flawless/seamless as possible.

The Interruption
- (void)applictaionWillResignActive:(UIApplication*)application

This method lets your application know that it is about to be interrupted by the iPhone OS. The name of the method suggests that your app will no longer be active, and will not respond to any user actions until the interruption is taken care of. An interruption like an incoming phone call or an SMS can either be accepted or dismissed by the user, and this is where you have to perform all tasks necessary to resume if the user chooses to leave the application. If the app was a game, it could save any game state needed for a resumption later.

The Resumption / Interruption Dismissed
- (void)applicationDidBecomeActive:(UIApplication*)application

When your application is about to become active again, this method is called by the iPhone OS. If the user decides not to leave the application and dismisses the interruption this is a good place to allow the user resume using the application. Since the application has not yet been closed, all the required state to resume is still in memory and continuing using the app is really as simple as a Pause/Resume feature.

The Interruption Accepted
- (void)applicationWillTerminate:(UIApplication*)application

If the user decides to leave the application or accepts an interruption, this method call from the iPhone OS notifies us of that intention. This is the place where you save all necessary state of the app/game to resume later.

The best place to save all game/app state to resume later is “applicationWillResignActive”. The simple reason being, all iPhone interruptions need user’s input to either accept or dismiss the interruption. This action from the user might needs a few seconds of his/her time to understand what the interruption is and what to do with it. This duration should be just enough for a well written application to save all state. Whereas, in the case of the application being closed by the user, iPhone OS wouldn’t wait for the app to complete saving state. The time available is really short and many applications might fail to save state.

Since there are multiple reasons and ways for an app being closed, state saving method calls need to be placed both in “applictaionWillResignActive” and “applictaionWillTerminate”. But ensure you don’t waste precious time in saving app state at both places. If the user closes the application by pressing the “Home” button, use “applictaionWillTerminate” to save state and necessary cleanups. If the application is being closed due to an interruption, save state in “applictaionWillResignActive” and perform any necessary cleanup in “applictaionWillTerminate”.

So, make it a point to use various UIApplicationDelegate methods to maintain user experience and reusability of the app. Keep your users glued to your application or game and return to it after an interruption.

For more tips and strategies on iPhone App Development, click here. For iPhone app marketing tips, try this link.

Share and Enjoy:
  • Digg
  • Sphinn
  • del.icio.us
  • Facebook
  • Mixx
  • Google Bookmarks
  • LinkedIn
  • N4G
  • Twitter
  • Yahoo! Buzz
Tags: iPhone App Development, iPhone Development help, iPhone Development tips, iPod Touch Development tips

iPhone development tip for iPhone OS 3.0.1

August 13th, 2009 by Ravi Korukonda 4 comments »

Many of my friends woke up to a rude shock when they found that their devices updated to iPhone OS 3.0.1 were not supported by iPhone SDK 3.1 Beta 3 for development.

If you too are experiencing the same problem, here is the solution to continue iPhone development with iPhone SDK 3.0 for your iPhone running iPhone OS 3.0.1.

1. Log-in to your MAC with an Admin account and launch the Terminal application (You will find it in /Applications/Utilities)
2. Copy and Paste the following line into the Terminal window
ln -s /Developer/Platforms/iPhoneOS.platform/DeviceSupport/3.0\ \(7A341\) /Developer/Platforms/iPhoneOS.platform/DeviceSupport/3.0.1

Note: If you have not installed iPhone SDK 3.0 in the default location “/Developer”, replace the “/Developer” directory in the above line as appropriate.

You can download the iPhone 3.0.1 Advisory guidelines document from iPhone Dev Portal

Share and Enjoy:
  • Digg
  • Sphinn
  • del.icio.us
  • Facebook
  • Mixx
  • Google Bookmarks
  • LinkedIn
  • N4G
  • Twitter
  • Yahoo! Buzz
Tags: iPhone 2G, iPhone 3G, iPhone 3Gs, iPhone Development help, iPhone Development tips, iPhone OS, iPhone OS 3.0.1