I wanted to change the YouTube video quality from adb.
Currently I am using the following command to run the YouTube video from adb:
adb shell am start -a android.intent.action.VIEW "https://www.youtube.com/watch?v=Zv11L-ZfrSg"
is there any additional option to set it to required quality?
enter image description here
System UI is not responding when I lunch android emulator and after clicking on close app it is very slow to use.
My system Specs ->
POP OS (Ubuntu)
8GB Ram
i5 7th gen
Nvidia 940mx
Quick Resolution:
Click on your AVD manager
Select your Emulator and click the edit button for your device.
Choose Wipe in the drop down menu.
See illustration below ..
Recommended Resolution :
Click on the AVD manager .
Select your Emulator and click the edit button for your device.
Select Hardware in the Graphics drop down menu.
For more information on Graphics acceleration see Android Studio Developer Guide
Just go to your AVD manager and click the Down arrow i.e DropDown Icon in the far left where your emulator name is displayed and Do a cold boot but make sure you are not running your device when doing it. It works for me for sometime say for 3-4 hours then I need to do it again I m not able to find the permanent solution to this but it is rather better than wiping down the data which would not work if you are a mobile dev as it would delete the apk it has installed and all that stuff. I hope your problem is resolved. If any of you seeing this comment in future I mean in 2025? Please reply me to see if I m alive! Bye
If you are using a 64-bit operating system on your computer, you should change emulators architecture(CPU/ABI) from x86 to x86_64. Create a virtual device and choose a system image like this one
I'm trying to get my react-native project to run on an android emulator while on a Mac operating system. It worked fine on my windows.
On my Mac, I go to terminal and type react-native run-android and I get the error message:
$ react-native run-android
Scanning 616 folders for symlinks in /Users/John/Documents/myreactnativeproject/node_modules (17ms)
Starting JS server...
Building and installing the app on the device (cd android && ./gradlew installDebug)...
Could not install the app on the device, read the error above for details.
Make sure you have an Android emulator running or a device connected and have
set up your Android development environment:
https://facebook.github.io/react-native/docs/android-setup.html
I type adb devices and I see
List of devices attached
emulator-5554 unauthorized
I go into the settings of my android emulator, I go to Settings Build Number to tap it several times to enable Developer options. In developer options, I enabled USB debugging, disabled Verify apps over USB, and left everything else as default. I shut down my android studio and emulator, restarted it. But still, the same issues mentioned above.
What am I doing wrong?
EDIT
I just connected my android phone to my Mac. When I run adb devices, I see this result
List of devices attached
YLEDU16B18004313 device
But when I run react-native run-android, I get the same error as above. So maybe there is something wrong with my react-native set up instead?
EDIT 2
I was able to deploy the app to my android phone by adding these extra steps
chmod 755 android/gradlew
For some reason, when I type echo $ANDROID_HOME into the terminal, I get the result /Users/John/Library/Android/sdk. But if I add the echo $ANDROID_HOME line to my android/gradlew file, it echoes nothing. And when I run the react-native run-android command, the compiler complains that ANDROID_HOME is not defined. So I have to type export ANDROID_HOME=/Users/John/Library/Android/sdk again, then running the react-native run-android command works and deploys it to my phone.
However, my emulator still doesn't work. The new error message I get is that Skipping device 'emulator-5554' (emulator-5554): Device is UNAUTHORIZED,.
But at least I have a temporary solution, and to debug with my phone.
EDIT 3
I got rid of the emulator 5554 unauthorized error by going into my Android Virtual Devices and deleting the virtual device. Then I re-installed it. And now my adb devices shows emulator 5554 device. And I am not able to deploy the app to my emulator.
In my case, Create a Virtual Device with Google APIs Image, not Google Play Image worked for me.
The problem occurs the only emulator that runs on Android Pie others don't.
In Android Studio
Open an Android Virtual Device Manager.
Create a new Virtual Device.
Select any Hardware you want.
Select any System Image which the Target is "(Google APIs)" not "(Google Play)" (If you don't found. Try to look at "x86 Images" tab or "Other Images" tab)
Done!
Android emulators have by default "Usb Debugging" in settings. You just need to wipe the data of the emulator. Do the following steps. It will work :---
Close the emulator and run the command adb kill-server in the command prompt. If adb is not set in you path then you might run this command from directory where adb is present.
Click on Wipe Data option from avd Actions menu.
Now run the emulator. It should work.
create new Virtual Device, and make sure you choose Google API's.
run the new device!. this should work
In my case, following steps worked
Wipe data from avd manager
Cold boot now
I managed to authenticate the adb on a Pixel 2, Android 9.0 (Google Play), API 28, x86_64 virtual device (Intel HAXM). The problem should be related to the Extended Controls (the 3 dots bottom icon menu, when the virtual device is booted), the Google Play menu, that is checking the version of the Google Play services. When adb is not 'unauthorized', this page is displaying the correct version, and the Update button opens inside the phone the Play Store with the Play Services app, so you can update it.
The steps I took to be able to authenticate are:
Make sure the USB debugging is turned ON in Dev setting
Revoke the USB debugging authorizations
Make sure the Extended Controls > Settings > Advanced > Open GL options are set to the: 'Desktop native OpenGL' and 'Renderer maximum (up to OpenGL ES 3.1)', so the emulator interface, animations, etc, are fast!
Power off the emulator
In 'Your Virtual Devices' in Android Studio, click the down arrow in Actions > Select 'Cold Boot Now'
When the device boot, you have to be fast, the dialog to remember and accept the USB connection will show and disappear for like less than 1 second (again I guess related to some automation scripts kicking, idn).
If you manage to click the 'remember' and 'ok' checkbox and button before the dialog disappears, you are done. Else you have to Power Off and Cold Boot again.
After that, don't wipe your emulator, else you'll have to do that insane race clicking again!
I run adb kill-server and adb devices.
the device will back again.
for Emulator, the default settings is debug enabled
Creating an emulator with graphics set to "Software - GLES 2.0" worked for me (Nexus 6 image).
I was initially using a Nexus 5X image which didn't allow me to select the graphics option.
NOTE: I went through the steps mentioned in EDIT 2 and EDIT 3 by the OP before doing this.
This can happen if USB debugging is not enabled on the emulator device.
Go to the emulated device, enable the Developer options and enable USB debugging.
I had to create a new emulator with Google Api. Wiping data didn't work for me.
2022 answer
What a shame of thread: so many "answers", comments and upvotes and none worked. Nobody simply mentioned that the "adb unauthorized" is caused by the adb keys stored in ~/.android/adbkey and ~/.android/adbkey.pub After deleting and recreating them, the problem was solved.
Credit: Android Emulator Unauthorized
I got my mac system to deploy a react-native build to my physical phone by following Edit 2 in the question.
I got my mac system to deploy a react-native build to my emulator by following Edit 3 in the question.
I think the issue was generally caused by moving my project from a Windows dev area to Mac dev area. Then probably a combination of different issues happened that cause builds to fail for each situation.
Deleting emulator and creating it again helped me on Ubuntu
I solved Problem
add ANDROID_SDK_HOME to environment variable
ANDROID_SDK_HOME = D:\sdk
and unplug device
and use new cmd
I'm new to Android.
I'm using Micromax A87 (india) with Gingerbread, this company is not listed in Android Manufacturers on Google website. My mobile's USB debugging mode is on. I tried to run hello world program with Eclipse but it started in AVD.
My problem is that my mobile is not showing in list by adb devices command. But device manager (win7) shows android composite ADB interface and I can also use my phone as disk.
Tell me where is issue? If I try to install supplied driver with phone then PC say that I already have better drivers and same case is for online search. I tried restarting adb.
Please help me to set up android work-space.
I have solved this issue for the same handset, do the following...
Go to C:\Users\system name.android
Make a copy of adb_usb.ini as a backup
Open adb_usb.ini
Replace the content of this file with following content:
0x17EF
0x1EBF
0x05C6
0x19D2
0x9015
0x1C9E
0x0BB4
I'm working on a fedora 14 computer. It's a Dell desktop, and it randomly freeze the mouse disabling the left&right clicks at all ( well it responses to the mouse movements).
Yesterday it did it again, so I googled this problem, and ppl suggested it was acpi-related, so I switched to tty2 and added two lines in my /boot/grub/grub.config file.
apm=off
acpi=off
then I restarted my computer, it was booting fine through the fedora logo filling up screen, then it flashed black, and gave me a screen with scattered fedora logo, when it's supposed to be the graphical login screen. Here if I hit ctrl+alt+f3, it doesn't show the indicator but a floating square with a "?" as the only option, and it doesn't do anything when "enter" is pressed.
so this is going nowhere, and I had to push the power button to force restart.
I did try going into single user mode, and changed the /boot/grub/grub.config file back to how it looked before, but it didn't seem to have fixed anything.
any idea what is going wrong and how to get the login screen back? appreciate your help!
p.s. I've got a freely-distributed compiler installed on this computer but I don't have the install files anymore. So I don't want to reinstall the OS.
p.p.s. I made a liveCD USB of fedora16, can I make any use of that?