Here's one possibility for you to check...
In the project's settings, under the General tab for a build target, there's the Deployment Info section where you select the "Devices" option (that you probably have on "Universal"). Below that is the Device Orientation selection. There's one, um, interesting feature here.
If you check some orientations when Devices is on Universal, it only applies the setting to the iPhone version. If you toggle the Devices selection to iPad, the options will likely be different. What you need to do is switch the selection to iPhone, apply the orientations you want there, switch it to iPad, apply orientations again, and then finally set Devices to Universal.
I have a hunch (not tested with your code) that if you try to apply an orientation that is not supported here, your code will do nothing.