GithubHelp home page GithubHelp logo

Comments (5)

Unai-HP avatar Unai-HP commented on July 2, 2024 1

Hi. Thanks for replying so fast!
You are right, I didn't provide enough info, so I've rechecked to paste the logs here and found some (more descriptive) errors. I don't know how I missed them.

D  setCharacteristicNotification() - uuid: f8083535-849e-531c-c594-30f1f86a4ea5 enable: true
D  QUEUED   CharacteristicWriteOperation(125660900)
D  STARTED  CharacteristicWriteOperation(125660900)
I  RUNNING  CharacteristicWriteOperation{MAC='XX:XX:XX:XX:XX:XX', characteristic=[uuid='...', hexValue=[...]]}
I  MAC='XX:XX:XX:XX:XX:XX'    onCharacteristicWrite(), status=0, value=[uuid='...']

W  Characteristic ... supports properties: [ WRITE INDICATE ] (40) does not have any property matching [ READ ] (2) <--- The error

D  QUEUED   CharacteristicReadOperation(91684627)
D  FINISHED CharacteristicWriteOperation(125660900) in 442 ms
D  STARTED  CharacteristicReadOperation(91684627)
I  RUNNING  CharacteristicReadOperation{MAC='XX:XX:XX:XX:XX:XX', characteristic=[uuid='...']}

D  Could not read after AuthRequestTX: com.polidea.rxandroidble2.exceptions.BleGattCannotStartException: 
GATT exception from MAC address 'XX:XX:XX:XX:XX:XX', with type BleGattOperation{description='CHARACTERISTIC_READ'}

D  FINISHED CharacteristicReadOperation(91684627) in 37 ms
I  MAC='XX:XX:XX:XX:XX:XX'  onConnectionStateChange(), status=0, value=0
D  Connection operations queue to be terminated (MAC='XX:XX:XX:XX:XX:XX')
   com.polidea.rxandroidble2.exceptions.BleDisconnectedException: Disconnected from MAC='XX:XX:XX:XX:XX:XX' with status 0 (GATT_SUCCESS)
   	at com.polidea.rxandroidble2.internal.connection.RxBleGattCallback$2.onConnectionStateChange(RxBleGattCallback.java:81)
   	at android.bluetooth.BluetoothGatt$1$4.run(BluetoothGatt.java:307)
   	at android.bluetooth.BluetoothGatt.runOrQueueCallback(BluetoothGatt.java:874)
   	at android.bluetooth.BluetoothGatt.-$$Nest$mrunOrQueueCallback(Unknown Source:0)
   	at android.bluetooth.BluetoothGatt$1.onClientConnectionState(BluetoothGatt.java:302)
   	at android.bluetooth.IBluetoothGattCallback$Stub.onTransact(IBluetoothGattCallback.java:128)
   	at android.os.Binder.execTransactInternal(Binder.java:1285)
   	at android.os.Binder.execTransact(Binder.java:1244)
D  Connection Disconnected/Failed: com.polidea.rxandroidble2.exceptions.BleDisconnectedException: Disconnected from MAC='XX:XX:XX:XX:XX:XX' with status 0 (GATT_SUCCESS)
D  QUEUED   DisconnectOperation(4749679)
D  setCharacteristicNotification() - uuid: f8083535-849e-531c-c594-30f1f86a4ea5 enable: false
D  STARTED  DisconnectOperation(4749679)
I  RUNNING  DisconnectOperation{MAC='XX:XX:XX:XX:XX:XX'}
D  onConnectionStateChange newState: RxBleConnectionState{DISCONNECTING}

Looks like the "read" operation doesn't exist, I guess I'm not doing the auth correctly. I've seen some post of this already, so I'll check those to see if I can get a fix. Again, thanks for your get.

from rxandroidble.

dariuszseweryn avatar dariuszseweryn commented on July 2, 2024

Hello, thanks for using the library!

Unfortunately you didn't provide much context in the logs so I can only guess that the connection is not being kept alive. Connection should be kept alive as long as the subscribers to RxBleDevice#establishConnection are subscribed.

Is it the case?

from rxandroidble.

dariuszseweryn avatar dariuszseweryn commented on July 2, 2024

@Unai-HP Did you happen to fix the issue?

from rxandroidble.

Unai-HP avatar Unai-HP commented on July 2, 2024

Yes, I forgot closing the issue, sorry.

from rxandroidble.

dariuszseweryn avatar dariuszseweryn commented on July 2, 2024

I am glad that you were able to find a fix.

If you can disclose it — please post the root cause and solution for the problem — other people who would come here later could benefit from that. Thanks in advance!

from rxandroidble.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.