Skip to content
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

Scan Device Failed When Upgrade build.gradle(app) #13

Closed
zawawimanja opened this issue Dec 26, 2019 · 1 comment
Closed

Scan Device Failed When Upgrade build.gradle(app) #13

zawawimanja opened this issue Dec 26, 2019 · 1 comment

Comments

@zawawimanja
Copy link

When updated the compilesdkversion and targetsdkversion to 28 , scan device failed.

apply plugin: 'com.android.application'
android {
compileSdkVersion 28

defaultConfig {
    applicationId "com.nordicsemi.nrfUARTv2"
    minSdkVersion 18
    targetSdkVersion 28
}


buildTypes {
    release {
        minifyEnabled false
        proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.txt'
    }
}

}

dependencies {
implementation 'com.android.support:support-v4:23.0.0'
implementation 'android.arch.lifecycle:viewmodel:1.1.1'

}

@zawawimanja
Copy link
Author

zawawimanja commented Dec 26, 2019

Anyone have problem after updating gradle to 29. I already solve it.

In manifest.xml
///
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />

`
private static final int ACCESS_FINE_LOCATION_PERMISSION = 85;

//in oncreate devicelistactivity

if (ContextCompat.checkSelfPermission(this, Manifest.permission.ACCESS_FINE_LOCATION) != PackageManager.PERMISSION_GRANTED) {
    ActivityCompat.requestPermissions(this, new String[]{Manifest.permission.ACCESS_FINE_LOCATION}, ACCESS_FINE_LOCATION_PERMISSION);

}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant