开发者

Are there any limitations to the iPhone simulator?

Is there anything that a device can do that the simulator can't? There are obvious things like using the accelerometer in a certain way, but are there others? Such as DSP, 开发者_如何学运维for example? My app runs fine on the device, but crashes on the simulator and I just want to make sure that it is not due to any of the simulators possible inherent limitations.

Thanks!


Within iOS Simulator, there are some limitations,

including: Apple Push Services Privacy alerts for access to Photos, Contacts, Calendar, and Reminders The UIBackgroundModes key iCloud document syncing and key-value storage support

Unsupported frameworks include:
External Accessory
Media Player
Message UI 
Event Kit
In UIKit, the UIVideoEditorController class
Store Kit


Here's a nice list from a previous question: iPhone device vs. iPhone simulator

And another one current to iOS 4: IPhone Application Development For Dummies


For example Apple Push Notification Service will not work in Simulator, as far as I can remember.


The Simulator is less limited than any actual device in such things as CPU performance, memory, storage, etc. But there may be differences in Open GL and GPU performance, etc.

Your app should be checking for the existence of any hardware features before using them, and checking for nil objects and pointers as well. So anything missing, such as an accelerometer or the camera, should not cause an app to crash.

If your app is crashing on the Simulator, that is a very strong indication that it might crash on some future iOS device or OS release. So you should hunt the cause down.

The instruction sets are different between the device and the Simulator (ARM vs. x86, NEON vs. SSE), so there's an extremely tiny possibility that it could be a compiler or compiler optimization bug.


Camera does not work. They could make a default mac camera simulated.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜