Re: iOS Security Failures vs. Standard Disconnections
Re: iOS Security Failures vs. Standard Disconnections
- Subject: Re: iOS Security Failures vs. Standard Disconnections
- From: András Kövi <email@hidden>
- Date: Fri, 28 Sep 2012 23:11:27 +0200
IMHO the only way to handle this scenario is by sending a notification from the watch to the phone that power off is going to happen. Delay the power off by a few 100ms to ensure the notification was received and then go to sleep. If the system does not provide more observability of causes through the error codes and userInfo, then this seems to be the only solution.
Andras
2012/9/28 Aaron Wright
<email@hidden>
We are trying to distinguish between failures to connect to a device due to a security failure (e.g. a device is bonded to another) and a standard "clean disconnect" by a device (e.g. the device disconnects because the user triggers a clean disconnect) in our app. This is needed in order to determine which devices we want to "auto-reconnect" with and which we do not in our Connected Devices list.
Thus-far, we have determined that there are two error-codes for disconnections that we encounter:
1) out of range or sudden disconnect - error code 6
2a) the pairing popup times out - error code 7
2b) the user presses cancel on the "pairing" screen (see attached) - error code 7
2c) the pairing process fails (for whatever reason such as a timeout) - error code 7
2d) the user deliberately disconnects device via CONNECT button (UI) on watch - error code 7
Unfortunately, we need to distinguish between (2d) and the other scenarios (2a, 2b, 2c). The code snippet follows my signature. Our goal is to ensure that the phone automatically reconnects in the scenario where the watch is deliberately disconnected (e.g. powered OFF by the user which triggers a clean disconnect) vs. where pairing fails.
Thank you
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Bluetooth-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Bluetooth-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden