Today we will discuss and I hope to learn how to make Android Virtual Device in Android Studio.
I assume that you have installed Android Studio on your machine/computer.
Open your Android Studio and create New Flutter Project -> Flutter Application
After that click 'Finish' and wait a few seconds.
Then you will get a project, something like this.
(feel free to call your project as you want, and go to the directory lib->main.dart file)
Now, go to drop-menu Tools and chose AVD Manager
You will get a pop-up window like this one and there go for "+ Create Virtual Device.." in the left down corner.
Again you will get a new one pop-up window and now is to you to choose device definition
You have category:
You probably need to choose the Phone category, but that depends on you and your project.
Go for the Phone category and choose one phone that you want.
Now we need to choose System Image for our device.
Android System Images are just versions of Android that you can run on your computer. More about that
Download one of these System Images and click Next
Then, finish step you can change the name of your device.
For example: Nexus 5 API 30 - tutorial- but this isn't needed and you can leave just Nexus 5 API 30
Now you can launch this AVD in the emulator. Click that. And it will show you a phone, maybe you need to wait for a few seconds but be patient. And if it's your first time to launch this AVD you maybe got some errors, if so please comment below which errors you get.
After you launch this AVD in the emulator, go to drop-menu and choose (mobile) and also choose main.dart
Run it. It can take a few seconds/minutes. Be patient. After that this main.dart code will be run on your virtual device.
That's it. After a few seconds, it will show you main.dart application on your virtual device. Congratulations.
Thanks for reading, I hope you learn something new. If you get any errors feel free to comment in the section below.
Also, if you can check my first post Say 'Hi' to Flutter