We have an app which makes use of an accessory connected to the audio jack(or lightning port in iPhone7 or later).It needs to be run in certain orientations, depending on iOS device.
There are currently no issues setting device orientation in either simulator or actual device for any iPhone, except the iPhoneX simulator.
Current code for setting orientation:
- (BOOL)shouldAutorotate {
return YES;
}
- (UIInterfaceOrientationMask)supportedInterfaceOrientations
{
//device checks omitted
return UIInterfaceOrientationMaskPortraitUpsideDown;
}
Target settings with orientations enabled
Stack trace:
TF uncaught exception reason : Supported orientations has no common orientation with the application, and [RootNavigationController shouldAutorotate] is returning YES
2017-10-05 09:35:02.692945+0200 [65045:74145368] *** Terminating app due to uncaught exception 'UIApplicationInvalidInterfaceOrientation', reason: 'Supported orientations has no common orientation with the application, and [RootNavigationController shouldAutorotate] is returning YES'
This is working on iPhone5, iPhone6, iPhone6+, iPhone7 and iPhone7+ devices and iPhone8 simulators. It doesn't seem to be an iOS11 issue either as my iPhone7 is currently running iOS11. The only device I'm currently having issues with is the iPhoneX simulator.