-
Notifications
You must be signed in to change notification settings - Fork 582
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adjust BleCannotSetCharacteristicNotificationException
to be more descriptive
#225
Comments
I can go with the first point now and the second for P.S. You should not use |
Regarding @dariuszseweryn P.S.: apologize for off-topic; please let me know if I should open a separate issue or address this somewhere else: My app writes to 2 different characteristics and receives notifications from 2 others. I don't see any realistic way of combining all these into a single Not knowing any better, I have been simply storing the In general, some elaboration on how multiple |
Ok. The second problem is I cannot ask somewhere what is a current state. The only way is to susbscribe to RxBleDevice.
Yeah, that's what I'm trying detect in My logic is following:
As I understand I need to restart subscription if I get any exception from RxBleConnection. Am I right? |
@kanat Yes. If the So far it seems that your use case also could be fulfilled with only one @RobLewis Your question should go to www.stackoverflow.com as well as it is a general question about how to use |
Ok. Should I close the issue? Or it will be opened until version 1.4.0? |
Do not close it. I will leave it be until I will better specify the behaviour. |
BleCannotSetCharacteristicNotificationException
to be more descriptive
@RobLewis Rob, did you post this question on SO? I am very interested in the answer as this fits my scenario as well. |
I did, here: https://stackoverflow.com/questions/44637878/using-multiple-subscribe-statements-with-rxjava/44639493#44639493
Hope to try out the ConnectionSharingAdapter tomorrow.
Cheers,
…--Rob
On Jun 20, 2017, at 14:37 , Ken DeLong ***@***.***> wrote:
@RobLewis <https://github.com/roblewis> Rob, did you post this question on SO? I am very interested in the answer as this fits my scenario as well.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub <#225 (comment)>, or mute the thread <https://github.com/notifications/unsubscribe-auth/AAJVYtrAxu1m7oVSzAVigJ7wu-x299Gtks5sGDuEgaJpZM4N-NrK>.
|
#225 Notification setup `Observable<Observable<byte[]>>` is now observing disconnection events to better notify about exceptions. Added cause to `BleCannotSetCharacteristicNotificationException` where possible.
@kanat Feel free to check and comment the above Pull Request wether it will be useful for your use-case. |
@dariuszseweryn it's ok now, thanks |
#225 Notification setup `Observable<Observable<byte[]>>` is now observing disconnection events to better notify about exceptions. Added cause to `BleCannotSetCharacteristicNotificationException` where possible.
Is available in |
Summary
rxBleConnection.setupIndication(...)
BleCannotSetCharacteristicNotificationException
comes, but I expected to seeBleDisconnectedException
P.S. before disconnection I could see:
BleGattException{macAddress=ED:78:87:F9:85:31, status=8 (0x08 -> https://android.googlesource.com/platform/external/bluetooth/bluedroid/+/android-5.1.0_r1/stack/include/gatt_api.h), bleGattOperationType=BleGattOperation{description='CONNECTION_STATE'}}
Preconditions
Steps to reproduce actual result
1. get app connected to BLE device
2. get app disconnected from device by going away
Actual result
BleCannotSetCharacteristicNotificationException
Expected result
BleDisconnectedException
Logs
error.txt
The text was updated successfully, but these errors were encountered: