Re: Detecting AirPort Power Enabled
Re: Detecting AirPort Power Enabled
- Subject: Re: Detecting AirPort Power Enabled
- From: Bill Cheeseman <email@hidden>
- Date: Thu, 1 Oct 2009 16:26:17 -0400
On Oct 1, 2009, at 8:20 AM, Bill Cheeseman wrote:
My need is simple: to detect whether the computer is configured so
that it can detect nearby wi-fi hotspots, if any, so that Core
Location will work. No need for notifications; no need to turn
anything on; no need to detect a network; no need to join a network
-- just detect current status of the AirPort card settings and
return YES if the card is on and the port is active. I warn and
leave it up to the user to change the configuration if the result is
NO.
After experimenting, it seems like it might be as easy as this:
- (BOOL)isAirPortEnabled {
return [[CWInterface interface] power];
}
Is this going to produce a false negative in any situation where the
AirPort card is actually functioning in such a way that it can detect
wi-fi hotspots?
--
Bill Cheeseman
email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Macnetworkprog mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden