How to test a new app on old hardware? (Xcode 4.3.2 with base SDK iOS 5.1; test-device is iPhone 3G with iOS 4.2.1)

Go To StackoverFlow.com

2

I am developing an iPhone-App that should run not only on new iphones, but on old devices as well. So for testing, I did load a provisioning profile to my old iPhone 3G (iOS 4.2.1) and connected it with my mac. In Xcode I also did set iOS Deployment Target to 3.0. With this settings, the app runs on an iPhone 4, but not on my old iPhone 3G.

I know that I also must set architecture from armv7 to armv6, but when I enter "armv6" it jumps back to "armv7".

So, what must I do, to be able to test new apps on old devices? What values must I enter, and WHERE must I enter them? Do I need to download some addon for the actual SDK?

2012-04-05 17:50
by Hubert Schölnast


5

We are testing applications on iOS 4 and 3 for some applications at my work and normaly the two key point are the arm achitecture and the deployment target as you already point out.

First, if you have multiple target, make sure you have the correct configuration everywhere.

Secondly, you pointed out that the armv7 "jumps" back to armv6. It shouldn't happen. Make sure you enter this field correctly with "armv6" on the first line and "$(ARCHS_STANDARD_32_BIT)" on the second line of the popup.

Finally, do you have any warnings or message in you console when you try to lauch the application ?

2012-04-05 18:08
by Xval
Does the armv7 conf still come back even when you type "armv6" "$(ARCHSSTANDARD32_BIT)" ? Looking at your explanations, there are high chances it doesn't work cause the app is build for an armv7 architecture.. - Xval 2012-04-05 18:29
Sorry i didn't see your first comment, normally it's the TARGETS entry that counts in the end (by default the projects value counts but it's possible the value has changed so i invite you to check). There you will find the build target (commonly you will have one Publish target for app submission and the target you use for dev which is the one you need to check) - Xval 2012-04-05 18:32
When I try to start the app on the iPhone 3G, there are no warnings or error messages. It simply does not load onto the phone. In the lightblue display in the middle of Xcodes Header i can read, that the is beening built, then i get the message "Running on ..." (can't read the rest, because it vanishes so fast) and then, after less than 1 second: "Finished running ToDO&Project on old_iPhone - no issues".

How exactly did you enter "armv6"? And where did you enter it - Hubert Schölnast 2012-04-05 18:39

To enter the architecture, go to the build settings of your target, look for architectures, choose "Other" and you'll be able to edit it. i'm not sure it's necessary but we always separate armv6 and $(ARCHSSTANDARD32_BIT) in two lines (but be sure armv6 is first) - Xval 2012-04-05 18:42
Well, in TARGETS I can change the architecture to "armv6 $(ARCHSSTANDARD32_BIT)". But this does not help. The app is not loaded onto the iPhone, and Xcode sayes "running" and after less then 1 sec "finished". Btw: In PROJECT, Architecture is still frozen to "Standard (armv7)" and I can't change it there - Hubert Schölnast 2012-04-05 18:50
As long as the arm conf is correct in the target it should be ok. Trying a good clean and build as you just changed the arm architecture. If it still doesn't work, take back a look at the deployment target in your target's build conf. If none of this work i must say i have no more idea for now. Does your iphone correctly appear in the organizer ? Checking the log of the devices might help too.. - Xval 2012-04-05 19:29
Cleaning before building does not help. Deployment Target is 3.0. Architecture in Project is "Standard (armv7)" Architecture in Target is "armv6 $(ARCHSSTANDARD32BIT)". The device show up in organizer with a green light. When I try to run the app on the phone, it finishes in less than 1 second after the "running" message appears. In the phones console is a error-message: "Thu Apr 5 22:00:22 unknown lockdownd[16] : 2ff68000 handleconnection: Could not receive USB message #6 from Xcode. Killing connection - Hubert Schölnast 2012-04-05 20:05
Looking at http://stackoverflow.com/questions/8127343/3g-iphone-device-finished-running-but-app-wont-load or http://stackoverflow.com/questions/6378228/switching-from-xcode3-to-xcode4-cant-load-programs-onto-older-ipod-touch it seems that there might a armv7 value in your plist file. Search for "Required device capabilities - Xval 2012-04-05 21:37
I'm dealing with the same issues. I've added armv6 and armv7 on separate lines above $(ARCHSSTANDARD32_BIT) and remove the armv7 requirement from the plist file. That gives me Command /usr/bin/lipo failed with exit code 1 I haven't had any trouble with a 3GS running 4.2.1 but the 3G on 4.2.1 is the problem - Mark 2012-04-06 00:54
After reading this post- http://stackoverflow.com/questions/4198676/warning-iphone-apps-should-include-an-armv6-architecture-even-with-build-config

I was able to get a couple apps to run on a 3G/4.2.1 One thing I did differently this time was select Combined instead of Levels under Build Settings. That may very well have made the difference. Just make sure you also remove the requirement for armv7 in the plist file - Mark 2012-04-06 03:57

It was the "Required device capabilities" in the apps plist. It was set to "armv7". Just adding a second item with "armv6" did not help. But when I deleted the old "armv7"-item, and "armv6" was the only one, then it did work! Thank you, Xval and Mark - Hubert Schölnast 2012-04-06 06:52
And what now .. Devices of type “iPhone 3G” are not supported by this version of Xcode , Xcode 4. - Renetik 2012-09-21 12:15


0

XCode comes with an iOS simulator... You should be able to test from iOS 3.2 - 5.1

If you don't already have it go to the update manager in XCode and download the iOS 5.0 simulator.

2012-04-05 17:52
by 4WebDev
The problem is, that the simulator has a bug. My app is behaving different on the simulator and my iPhone 4. Look here: http://stackoverflow.com/questions/10030362 Now I want to find out, how it behaves on my old iPhone 3G. That's why I need to test the app on real old hardware - Hubert Schölnast 2012-04-05 17:57
Ads