This question already has answers here:
How to get the status of bluetooth (ON/OFF) in iphone programmatically
(7 answers)
Closed 7 years ago.
The question is simple: Is there any way to get noticed when the users enables or disables bluetooth on a iOS device?
I searched the internet but just found some private APIĀ“s.
Thanks for your help.
You can use Bluetooth Low Energy's (BTLE) interface. You will get updates whenever an user disables/enables Bluetooth in settings. Check the CBCentralManagerDelegate Protocol Reference. And of course you can also check the state
Related
This question already has answers here:
How to get iOS device MAC address programmatically
(6 answers)
Closed 5 years ago.
I am working on a network security based ios app. I need to find the device's MAC address which is used to register the device at router level. Once registration is complete then the router allows the network traffic coming from that MAC address to pass through.
Now, the problem is, in ios 7 or later we can't get the device mac address, as per the following post:
stackoverflow:Mac address is unavailable from ios 7 and up.
Can anyone suggest me any alternative way to find MAC address in ios using C or Objective-C or using any other way.
EDIT:
I know that this question has been asked and answered but I am looking for any alternative way by which we can do this.
You can't anymore due to a change in Apple's privacy controls.
This question already has an answer here:
How to power iOS device off [duplicate]
(1 answer)
Closed 7 years ago.
I want to make an application that would turn off an iphone at a set time every night;
Absolutely not! (Unless we are talking about a jailbroken app.)
Apple has a very strict sandboxing approach for third party apps. To access the system, you have to use the provided iOS APIs and none of them offers this kind of control.
This question already has answers here:
Activate airplane mode programmatically?
(2 answers)
Closed 7 years ago.
Yes. I actually think that what I am asking is impossible but I'd like to know if you have any idea how to power the iPhone off with swift or objective c code, or at least enter the airplane mode.
You cannot do this with the Public APIs provided by apple. This may be done using the unreleased Private APIs.
But According to Apple's policy, usage of any Private APIs will lead to rejection of App from App Store.
This question already has answers here:
How can I detect if my apple device supports Bluetooth Low Energy
(3 answers)
Closed 9 years ago.
What is the correct way to determine whether an iOS device supports Bluetooth LE. Is there a way to query this through CoreBluetooth, or are you required to check iOS versions and hardware ids to figure it out. The latter seems unlikely given Apple's dislike of those approaches.
Yeah, just setup your CBCentralManagerDelegate and wait for the centralManagerDidUpdateState: callback. If the state is CBCentralManagerStateUnsupported, then the current device does not support ble.
CBCentralManagerStateUnsupported -> The platform doesn't support the
Bluetooth Low Energy Central/Client role.
This question already has answers here:
iOS wifi scan, signal strength
(2 answers)
Closed 9 years ago.
Is there a way to show WiFi networks table sorted by their signal?
It sounds very unlikely that apple will let us do such a thing but I'll ask that anyway.
Thanks
No you can check only if connection is available or not but you can't get signal strenth.For more detail you can go with this link
here