Coder Social home page Coder Social logo

Comments (3)

davidgyoung avatar davidgyoung commented on July 17, 2024

Hi, @Mritunjaysingh. Can you please try putting the lines below before your call to checkAvailability(), and let me know the log lines you see in LogCat?

Thanks,
David

    Log.d(TAG, "appContext is "+this.getApplicationContext());
    Log.d(TAG, "packageManager is "+this.getApplicationContext().getPackageManager());
    Log.d(TAG, "hasBluetoothLE is "+this.getApplicationContext().getPackageManager().hasSystemFeature(android.content.pm.PackageManager.FEATURE_BLUETOOTH_LE));
    Log.d(TAG, "bluetoothManager is "+this.getApplicationContext().getSystemService(Context.BLUETOOTH_SERVICE) );
    Log.d(TAG, "bluetoothAdapter is "+((android.bluetooth.BluetoothManager) this.getApplicationContext().getSystemService(Context.BLUETOOTH_SERVICE)).getAdapter() );
    Log.d(TAG, "enabled is "+((android.bluetooth.BluetoothManager) this.getApplicationContext().getSystemService(Context.BLUETOOTH_SERVICE)).getAdapter().isEnabled() );

from android-ibeacon-service.

davidgyoung avatar davidgyoung commented on July 17, 2024

Hi, @Mritunjaysingh. I cannot reproduce this issue, so I am closing this for now. If you are still seeing this, and can put the log lines in your app as I have proposed above, please reopen the issue with the requested info.

from android-ibeacon-service.

billmote avatar billmote commented on July 17, 2024

I put those lines ahead of checkAvailability() and I am getting an NPE. Here is the output:

05-19 09:22:29.872 29830-29830/com.example.helloworld.debug D/MainActivity﹕ appContext is com.example.helloworld.HelloWorldApplication@1221a945
05-19 09:22:29.872 29830-29830/com.example.helloworld.debug D/MainActivity﹕ packageManager is android.app.ApplicationPackageManager@5369b49
05-19 09:22:29.873 29830-29830/com.example.helloworld.debug D/MainActivity﹕ hasBluetoothLE is true
05-19 09:22:29.877 29830-29830/com.example.helloworld.debug D/MainActivity﹕ bluetoothManager is android.bluetooth.BluetoothManager@3f068c4e
05-19 09:22:29.877 29830-29830/com.example.helloworld.debug D/MainActivity﹕ bluetoothAdapter is android.bluetooth.BluetoothAdapter@26ddb16f
05-19 09:22:29.877 29830-29830/com.example.helloworld.debug D/MainActivity﹕ enabled is false

from android-ibeacon-service.

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.