Netanel
Netanel

Reputation: 487

Android Studio "Error Installing APK" to xiaomi phone

I am developing an app in android studio and I use xiaomi mi a1 to run it on it. I turned on USB debugging and USB tethering and I do see the phone in android studio devices. The problem is that when I try to run it after some time it says "Error Installing APK".

Notes:

  1. I turned off insta run.
  2. When android 8 was on my phone everything worked just fine. Since I installed android 9 it stopped working.

Anyone knows what's the problem or how to fix it?

EDIT: When I turned off insta run there was no error but it kept "installing apk's" for about 20 minutes and the app didn't load on the phone (On other phones it took max 1-2 minutes).

Upvotes: 2

Views: 2756

Answers (1)

Erselan Khan
Erselan Khan

Reputation: 845

Settings -> Additional Settings -> Developer options ->

1) Turn off "MIUI optimization" and Restart

2) Turn On "USB Debugging"

3) Turn On "Install via USB"

4) Set USB Configuration to Charging

Make sure you have insert sim in your mobile, else app will not installed in your mob and always through error.

Upvotes: 2

Related Questions