Reputation: 1310
I need to detect the EDGE network and bad network in the iPhone.
1) How to detect the bad network ?
2) Is it possible to detect EDGE network separetly ?
3) How can I get the strength of the network ?
Please give some answer about these questions. Thanks in advance.
Upvotes: 11
Views: 2394
Reputation: 57040
On iOS7, you can!
http://www.objc.io/issue-5/iOS7-hidden-gems-and-workarounds.html
CTTelephonyNetworkInfo *telephonyInfo = [CTTelephonyNetworkInfo new];
NSLog(@"Current Radio Access Technology: %@", telephonyInfo.currentRadioAccessTechnology);
[NSNotificationCenter.defaultCenter addObserverForName:CTRadioAccessTechnologyDidChangeNotification
object:nil
queue:nil
usingBlock:^(NSNotification *note)
{
NSLog(@"New Radio Access Technology: %@", telephonyInfo.currentRadioAccessTechnology);
}];
Upvotes: 26