Anyone know the machine IDs for these new devices? For example the 3rd generation iPad could be iPad3,1 iPad3,2, iPad3,5 iPad3,6 depending on the model. I'm finding the string with this
struct utsname systemInfo;
uname(&systemInfo);
NSString *dev = [NSString stringWithCString:systemInfo.machine encoding:NSUTF8StringEncoding];
I got a new Ipad 4th Wifi, the machine model is iPad3,4
Also, Ipad mini Wifi is iPad2,5
Edited
On Mid-November will be launch the rest of the new Ipad models: (as Ipad 3th gen)
iPad3,5 for iPad 4th gen GSM
iPad3,6 for iPad 4th gen CDMA
iPad2,6 for Ipad mini Wifi GSM
iPad2,7 for Ipad mini Wifi CDMA
Just got my iPad mini. "iPad2,5"
UIDevice model is just "iPad". I suspect the larger iPad 2 will be phased out since it does not have the lighting port, and the new iPad mini Retina will be iPad2,6
Related
I've checked whether motion&fitness is enabled in my app. I've checked the below code to check this.
if([CMMotionActivityManager isActivityAvailable])
{
}
This returns FALSE when motion&fitness is disabled in settings. But the motion&fitness option is not there in iPhone 5 and lower versions. So I want to know whether the device model is iPhone 5s or higher. Is there any way to check this?
If you want to check motion then use
https://developer.apple.com/library/prerelease/ios/documentation/CoreMotion/Reference/CMSensorRecorder_class/index.html#//apple_ref/occ/clm/CMSensorRecorder/isAuthorizedForRecording
iOS 9 and above, CMSensorRecorder class, In that they introduce method to check if your app is authorized for Motion & Fitness:
If you are using Swift the use following
class `func isAuthorizedForRecording() -> Bool
if Objective C then
+ (BOOL)isAuthorizedForRecording
if you just want to check device model then use following method
[[UIDevice currentDevice] platformType] // ex: UIDevice4GiPhone
[[UIDevice currentDevice] platformString] // ex: #"iPhone 4G"
to getting complete list of model
#import <sys/utsname.h> // import it in your header or implementation file.
NSString* deviceName()
{
struct utsname systemInfo;
uname(&systemInfo);
return [NSString stringWithCString:systemInfo.machine
encoding:NSUTF8StringEncoding];
}
after printing device name you will get one of following output
#"i386" on 32-bit Simulator
#"x86_64" on 64-bit Simulator
#"iPod1,1" on iPod Touch
#"iPod2,1" on iPod Touch Second Generation
#"iPod3,1" on iPod Touch Third Generation
#"iPod4,1" on iPod Touch Fourth Generation
#"iPod7,1" on iPod Touch 6th Generation
#"iPhone1,1" on iPhone
#"iPhone1,2" on iPhone 3G
#"iPhone2,1" on iPhone 3GS
#"iPad1,1" on iPad
#"iPad2,1" on iPad 2
#"iPad3,1" on 3rd Generation iPad
#"iPhone3,1" on iPhone 4 (GSM)
#"iPhone3,3" on iPhone 4 (CDMA/Verizon/Sprint)
#"iPhone4,1" on iPhone 4S
#"iPhone5,1" on iPhone 5 (model A1428, AT&T/Canada)
#"iPhone5,2" on iPhone 5 (model A1429, everything else)
#"iPad3,4" on 4th Generation iPad
#"iPad2,5" on iPad Mini
#"iPhone5,3" on iPhone 5c (model A1456, A1532 | GSM)
#"iPhone5,4" on iPhone 5c (model A1507, A1516, A1526 (China), A1529 | Global)
#"iPhone6,1" on iPhone 5s (model A1433, A1533 | GSM)
#"iPhone6,2" on iPhone 5s (model A1457, A1518, A1528 (China), A1530 | Global)
#"iPad4,1" on 5th Generation iPad (iPad Air) - Wifi
#"iPad4,2" on 5th Generation iPad (iPad Air) - Cellular
#"iPad4,4" on 2nd Generation iPad Mini - Wifi
#"iPad4,5" on 2nd Generation iPad Mini - Cellular
#"iPad4,7" on 3rd Generation iPad Mini - Wifi (model A1599)
#"iPhone7,1" on iPhone 6 Plus
#"iPhone7,2" on iPhone 6
#"iPhone8,1" on iPhone 6S
#"iPhone8,2" on iPhone 6S Plus
#"iPhone8,4" on iPhone SE
If you want in Swift please use below link
iOS: How to determine the current iPhone/device model in Swift?
An iPad Air already has a Retina screen, so why has Apple deliberately designed two kinds of simulator?
The simulator does not include the iPad mini. The difference between the Retina and the Air is the 64 bit processor.
iPad Air = Retina x64
iPad Retina = Retina x32
iPad 2 = Non-Retina x32
To test the iPad mini Apple recommends testing on a non-retina device (aka iPad 2):
From the "Apple iOS Simulator Guide":
Although an iPad mini isn’t an option for a simulated device in
Simulator, you can still test apps for the iPad mini in the simulator.
To do this, run your app on the simulated iPad without Retina display.
Edit:
You can also test iPad mini on iPad Retina Simulator.
See updated Apple "iOS Simulator User Guide":
Testing for the iPad mini
To test apps for the iPad mini in the simulator, run your app on a simulated
iPad with the corresponding type of display, either Retina or non-Retina
depending on the iPad mini model.
I feel a little dummy to ask such a question but I am not sure. Can someone tell me to whichreal device corresponds exactly each device in the simulator? I have seen here that all the devices available in the simulator are the following ones, but to what do they correspond?
iPhone Retina (3.5-inch) :iPhone 4 and 4s?
iPhone Retina (4-inch) : iPhone 5?
iPhone Retina (4-inch 64-bit) : iPhone 5s?
iPad
iPad Retina : iPad 1, 2 or 3?
iPad Retina (64-bit)
All of the iPhone entries you have are correct.
5th gen iPod touch would be under iPhone Retina 4".
4th gen iPod touch would be under iPhone Retina 3.5".
The 3rd gen and earlier would be under iPhone Non-retina 3.5"
The iPad would be:
iPad - iPad 1, iPad 2, 1st gen Mini
iPad Retina - iPad 3, iPad 4,
iPad Retina 64-bit - iPad Air, 2nd gen Mini
I find the Wikipedia page List of iOS devices to be very helpful.
on IOS calling uname() will return the device name. The only doc i could find is this website but it does not contain the iPad Mini Retina in the list.
Does anyone know what uname() will return on that device ?
Thanks,
Razvan.
Check this list. Looks like it contains all Apple devices. According to this list iPad mini Retina WiFi is iPad4,4 and iPad mini Retina Cellular is iPad4,5
I am developing iOS app with ZBar SDK for QR-codes scan. Here ZBar SDK creators tell us that
Only the iPhone 3GS and iPhone 4 are supported, as they have a camera
with auto-focus. The ZBar library does not support the iPhone 3G and
is unlikely to ever support it.
So I have added auto-focus-camera key to the Required Device Capabilities section of my plist. All is great, except one thing - iPad 2 & iPod Touch 4th Gen doesn't have auto focus camera, but still are able to use my ZBar SDK code to scan QR-codes. But my auto-focus-camera key doen't allow users with iPad 2 and iPod Touch 4th Gen to download my app from App Store.
In other words I need to find a way to make my app installable via App Store on these devices:
iPhone 3GS.
iPhone 4.
iPhone 4S.
iPad 2.
The New iPad.
iPod Touch 4th Gen.
And on these devices my app should not be available:
iPhone 2G.
iPhone 3G.
iPad.
iPod Touch 3d Gen and
My question is: how to make my app available in App Store for first list devices' user and not available for second list devices' users?
Any help will be appreciated!
PS: I have seen this question on SO, but it doesn't help me much.
PS2: This app has the desired set of available devices.
Requirements: Compatible with iPhone 3GS, iPhone 4, iPhone 4S, iPod
touch (4th generation), iPad 2 Wi-Fi, iPad 2 Wi-Fi + 3G, iPad (3rd
generation) and iPad Wi-Fi + 4G.
Does anyone know, how they did it?
PS3: At the same time adding both still-camera and auto-focus-camera gives us this:
Requirements: Compatible with iPhone, iPod touch (4th generation),
iPad 2 Wi-Fi, iPad 2 Wi-Fi + 3G, iPad (3rd generation) and iPad Wi-Fi
+ 4G.
And that is not a great way as long as we have all iPhones as suitable for our app, instead of 3GS, 4 and 4S.
PS4: My app is here and it has such requirements:
Requirements: Compatible with iPhone 3GS, iPhone 4, and iPhone 4S.
Word Lens requires the armv7, opengles-2, and video-camera device capabilities.
I'm not sure that you can do that
Maybe you can do a check in your code and if the device model is not the good one, just pop a new view saying that the model that the user is using can't make work the application ?
You can detect the model with this:
#import <sys/utsname.h>
NSString*
machineName()
{
struct utsname systemInfo;
uname(&systemInfo);
return [NSString stringWithCString:systemInfo.machine
encoding:NSUTF8StringEncoding];
}
and give that:
#"i386" on the simulator
#"iPod1,1" on iPod Touch
#"iPod2,1" on iPod Touch Second Generation
#"iPod3,1" on iPod Touch Third Generation
#"iPod4,1" on iPod Touch Fourth Generation
#"iPhone1,1" on iPhone
#"iPhone1,2" on iPhone 3G
#"iPhone2,1" on iPhone 3GS
#"iPad1,1" on iPad
#"iPad2,1" on iPad 2
#"iPhone3,1" on iPhone 4
#"iPhone4,1" on iPhone 4S
Else you can try sending an e-mail to apple
We need to use video-camera key in Required Device Capabilities section of app's plist.