How can I check if an application running on iPhone 5 or not and then do something?
Check the IMEI number So, this is one of the easiest ways to find out if your iPhone is real or fake. To find the phones IMEI number go to Settings, click on General, tap on the About option, and scroll down to see the IMEI number. If theres no IMEI or serial number, theres a high chance that the iPhone model is fake.
The iPhone 4, 4s, 5 and 5c cannot connect as your step tracking device because these models don't have the part built in, the accelerometer, that tracks steps (this is included in the iPhone5s and newer).
From the Devices section of your Apple ID account page, you can see all of the devices that you're currently signed in to with your Apple ID, including Android devices, consoles, and smart TVs: Sign in to appleid.apple.com,* then select Devices.
#define IS_IPHONE_5 ( fabs( ( double )[ [ UIScreen mainScreen ] bounds ].size.height - ( double )568 ) < DBL_EPSILON )
then in the code:
if (IS_IPHONE_5) {
//is iphone 5
}
You're likely concerned with the window size, not the make/model, this will do:
CGRect screenRect = [[UIScreen mainScreen] applicationFrame];
if (screenRect.size.height == 568)
{
// this is an iPhone 5+
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With