Whilst running Android applications on a real device is pretty quick nowadays, it’s still useful to run our apps against an emulator.
In this post we’re going to look at creating an emulator which works/looks like a Samsung s10e.
Device information and skins
In the case of Samsung devices, simply visit Samsung, Emulator Skin Overview.
Here you can find skin downloads (to give your emulator more of a look of the device) along with device information, such as screen size, resolution etc. Download the skin.
Note: You’ll need to be registered on the Samsung developer site to download the skins, but it’s a painless process.
In the case of the s10e, the device has a 5.8 inch display and a resolution of 1080×2280. So we’re put that information into our virtual device in a minute, before we do that, extract the downloaded skin into the following folder
%USERPROFILE%\AppData\Local\Android\Sdk\skins\samsung_s10e
Now we’re got all the relevant skin related files let’s move onto creating our virtual device.
Android device manager
From Visual Studio or Android Studio, locate the button to run the Android Device Manager. In either case either press New… or Create Virtual Device…
To save trying to describe both UI’s I’m going to stick with the Android Studio UI. So after click on Create Virtual Device, do the following
- Click New Hardware Profile
- Set Device Name to Samsung S10e
- Ensure Device Type is Phone/Tablet
- Set screen size to 5.8
- Set Resolution to 1080 x 2280
Leave all other options as they are but now scroll down to the Default Skin option. Clicking on the … button does nothing until you switch from No Skin to select a skin, any skin will work. Don’t worry if you get a warning about the skin not being the right size as we’re going to change it now. Click on the … button and locate the samsaung_s10e folder we put the skin files into.
Finally, click Finish.
- With the new device selected, press the Next button
- Currently the s10e is running Android Pie API Level 28, so select this or your preferred version of Android
- Press Next and if all looks good, then press Finish
If you need to edit the configuration you can do so via the Android Virtual Device Manager, you’ll need to select the device and then click the edit button. You’ll need to click the Show Advanced Settings button to change memory, or if you wish to change the skin.