Android emulator doesn't take keyboard input - SDK tools rev 20
Update
As of SDK rev 21 the Android Virtual Device Manager has an improved UI which resolves this issue. I have highlighted some of the more important configuration settings below:
If you notice that the soft (screen-based) main keys Back
, Home
, etc. are missing from your emulator you can set hw.mainKeys=no
to enable them.
Original answer
Even though the developer documentation says keyboard support is enabled by default it doesn't seem to be that way in SDK rev 20. I explicitly enabled keyboard support in my emulator's config.ini file and that worked!
Add: hw.keyboard=yes
To: ~/.android/avd/<emulator-device-name>.avd/config.ini
Similarly, add hw.dPad=yes
if you wish to use the arrow-keys to navigate the application list.
Reference: http://developer.android.com/tools/devices/managing-avds-cmdline.html#hardwareopts
On Mac OS and Linux you can edit all of your emulator configurations with one Terminal command:
for f in ~/.android/avd/*.avd/config.ini; do echo 'hw.keyboard=yes' >> "$f"; done
On a related note, if your tablet emulator is missing the BACK/HOME buttons, try selecting WXGA800 as the Built-in skin in the AVD editor:
Or by manually setting the skin in config.ini:
skin.name=WXGA800
skin.path=platforms/android-16/skins/WXGA800
(example is for API 16)
Android emulator doesn't take keyboard input on custom AVD skins- SDK tools rev 20.0.1
Apparently there is a hardware.ini
file in each of the skin's folder (for example NEXUS-S
) that specify hw.keyboard=no
. You can modify this line to enable the keyboard in the AVD that is based on the skin. There is also hw.dPad=yes
if you wish to use the arrow-keys.
Why did keyboard input stop working in Android Emulator
I solved this problem by adding "Keyboard Support" to the AVD within the AVD-Manager and changing the value to "true".
Android Emulator not showing keys on keyboard
I believe your input method has changed to some which is unrecognized by android OS.
You could try explicitly setting the language on keyboard in app.
Check this one.
Emulator not displaying keyboard
Edit your AVD, add "Keyboard Support" and change the value to no.
Restart your AVD making sure that you wipe user data. Your keyboard will popup now.
Check this and this.
Android Emulator's Enable keyboard input always unchecked after Mac OS Sierra reboot
With Android Studio 3.0 stable this issue has been fixed for me.
Related Topics
How to Remove Application from App Listings on Android Developer Console
Appcompat V7 R21 Returning Error in Values.Xml
How to Handle an Asynctask During Screen Rotation
Accessing Localhost of Pc from Usb Connected Android Mobile Device
How to Implement Multi-Select in Recyclerview
Connecting to MySQL from Android with Jdbc
Remove Data from Notification Intent
Updating Paging 3 Alpha to Stable Cause Indexing Issue Android
How Did Google Manage to Do This? Slide Actionbar in Android Application
How to Listen for Changes in Contact Database
Android Studio - Local Path Doesn't Exist
How to Set Image Button Backgroundimage for Different State
How to Bring an Activity to Foreground (Top of Stack)
Programmatically Select Item Listview in Android
Converting JSONarray to Arraylist