Skip to content

Error while sending datas to glasses #15

@MosKi-TM

Description

@MosKi-TM

I tried to set me up a really basic project but the problem is that I can't send data to the glasses

Thr following error occures on any "glasses.method" such as circ, clear or txt

[ 0xFF, 0x01, 0x01, 0x06, 0x00, 0xAA ]
2023-12-19 12:13:22.499 17209-17225 writeCommand com.example.testactivelook W payload length: 6
2023-12-19 12:13:22.523 17209-17225 BluetoothGatt com.example.testactivelook W Unhandled exception in callback
java.lang.ArrayIndexOutOfBoundsException: src.length=6 srcPos=0 dst.length=6 dstPos=0 length=256
at java.lang.System.arraycopy(Native Method)
at com.activelook.activelooksdk.core.ble.GlassesGattCallbackImpl.unstackWriteCommand(GlassesGattCallbackImpl.java:282)
at com.activelook.activelooksdk.core.ble.GlassesGattCallbackImpl.writeCommand(GlassesGattCallbackImpl.java:260)
at com.activelook.activelooksdk.core.ble.GlassesImpl.writeCommand(GlassesImpl.java:70)
at com.activelook.activelooksdk.core.GlassesCommandsAdapter.write(GlassesCommandsAdapter.java:200)
at com.activelook.activelooksdk.core.GlassesCommandsAdapter.clear(GlassesCommandsAdapter.java:228)
at com.example.testactivelook.MainActivity.lambda$onCreate$0(MainActivity.java:54)
at com.example.testactivelook.MainActivity$$ExternalSyntheticLambda2.accept(Unknown Source:2)
at com.activelook.activelooksdk.core.ble.GlassesGattCallbackImpl.onCharacteristicRead(GlassesGattCallbackImpl.java:139)
at android.bluetooth.BluetoothGattCallback.onCharacteristicRead(BluetoothGattCallback.java:108)
at android.bluetooth.BluetoothGatt$1$6.run(BluetoothGatt.java:425)
at android.bluetooth.BluetoothGatt.runOrQueueCallback(BluetoothGatt.java:864)
at android.bluetooth.BluetoothGatt.-$$Nest$mrunOrQueueCallback(Unknown Source:0)
at android.bluetooth.BluetoothGatt$1.onCharacteristicRead(BluetoothGatt.java:419)
at android.bluetooth.IBluetoothGattCallback$Stub.onTransact(IBluetoothGattCallback.java:182)
at android.os.Binder.execTransactInternal(Binder.java:1290)
at android.os.Binder.execTransact(Binder.java:1249)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions