Skip to content

Android code Couldn't search Ble Shiled device! #3

Open

Description

@dparadox

Hello, I'm trying to make to work the SimpleControls example using the same Api. 18
but I got the message Couldn't search Ble Shiled device!. The binaries example work perfectly.

I have the BLE Mini

Some idea?

Thanks

Activity

  1. Cheong2K commented on Apr 1, 2015

    @Cheong2K
    Contributor

    Please try Google Play version "BLE Controller" to see if it works.

  2. dparadox commented on May 25, 2015

    @dparadox
    Author

    Yes it's works but ths implementation not, i would like to have same implementation.

  3. mnottale commented on Jul 17, 2016

    @mnottale

    Had the same issue that I fixed by changing the offset used in the uuid comparison code:

        private BluetoothAdapter.LeScanCallback mLeScanCallback = new BluetoothAdapter.LeScanCallback() {
    
            @Override
            public void onLeScan(final BluetoothDevice device, final int rssi,
                    final byte[] scanRecord) {
    
                runOnUiThread(new Runnable() {
                    @Override
                    public void run() {
                        byte[] serviceUuidBytes = new byte[16];
                        String serviceUuid = "";
                        for (int i = 32 - 6, j = 0; i >= 17 - 6; i--, j++) {   // <--- HERE
                            serviceUuidBytes[j] = scanRecord[i];
                        }
    
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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