- Установка и запуск эмулятора Android SDK на Windows
- How to install Android SDK and setup AVD Emulator without Android Studio
- Understanding the Android SDK
- Installing the Android SDK
- Step 1 — Download the tools package
- Step 2— You need Java 8!
- Step 3 — Download the essential packages
- Step 4 — Set your environmental variables
- Step 5 — Download the platform specific packages you want
- Step 5 — Create a AVD device
- Step 6 — Run the Android Emulator
- Эмулятор Android SDK: обзор, инструкции, установка
- Функционал эмулятора
- Интерфейс Android SDK
- Системные требования Android SDK
- Производительность
- Инструкция: Как установить эмулятор Android SDK на свой ПК?
- Особенности эмулятора
Установка и запуск эмулятора Android SDK на Windows
Нам потребуется:
1. Java SE Runtime Environment
2. Android SDK
Установка.
1. Скачиваем и устанавливаем Java SE Runtime Environment . После этого скачиваем и распаковываем Android SDK .
2. Запускаем SDK Manager.exe, который находится в распакованной нами папке, и видим такое окно:
На скриншоте отмечено то, что нам нужно установить для запуска Android 4.3. Если вам нужна другая версия Android или какие-то дополнительные параметры их стоит тоже выделить галочкой для установки.
3. Отмечаем нужные нам компоненты и жмем Install pakage.. Некоторые компоненты, которые не входят в состав скачанного пакета Android SDK будут загружаться с интернета. Ждем загрузки (все зависит от скорости интернета) и переходим непосредственно к запуску эмулятора.
Запуск эмулятора.
1. Переходим в вкладку tools и там выбираем Manage AVDs.., как показано на скриншоте:
2. После запуска Manage AVDs.. видим такое окно и в нем жмем New:
3. После этого появится окно в котором нам нужно будет выбрать устройство, систему Android, количество памяти и т.д. Я выбрал так (Вы выбираете как вам нужно):
4. Заполнили поля, жмем Ок. После чего видим созданное нами устройство:
Выбираем его и жмем Start. В появившемся маленьком окне нажимаем на Lauch. Должна появится шкала запуска:
и после мы должны увидеть интерфейс с загрузкой Android (загрузка может происходить долго, все зависит от того какие вы параметры выбрали):
4. После загрузки мы увидим окно программы, которое делится на две части. Слева находится дисплей виртуального устройства, а справа — управляющие клавиши:
5. Ну вот собственно и все. Если у Вас возникнут какие-нибудь вопросы, их можно задать в этой теме.
Источник
How to install Android SDK and setup AVD Emulator without Android Studio
If you are trying to develop to Android, you probably will end up installing the Android Studio to get the Android SDK and the AVD Emulator working properly.
But if you are using another code editor, like Sublime Text or VSCode, installing the Android Studio will just mess up with your setup and consume your precious RAM for no good reason.
I had a hard time figuring out how to properly do this setup due the lack of documentation about it, so i hope this article helps you. 🙂
Recommended previous knowledge:
- SDK (Standard Development Kit); Read about on Wikipedia;
- AVD (Android Virtual Device); Read about on docs;
- CLI (Command Line Interface); Read about on Wikipedia;
- Android API levels; Read about on Vanderbilt University;
- How to open, navigate and execute files in your OS terminal;
- Know what are environmental variables;
Understanding the Android SDK
Basically, the Android SDK is a bunch of packages necessary to develop for Android.
These packages stays in subfolders of a folder called “sdk” (or “android-sdk” sometimes). You do not need to know how these packages really work, just what they do.
The picture below is my Android SDK folder, these are the basic packages you will need in order to get everything working properly.
Here is a brief explanation of each package:
- tools: This package is mainly used to manage the other packages and to create AVD’s;
- emulator: As the name suggest, this is the Android emulator;
- platform-tools: Some tools to communicate with Android devices when you plug then in your computer;
- patcher: This package is automatically downloaded by the SDK. I didn’t find what exactly this is for, so just leave it as it is;
The folders bellow contain sub-folders with the packages for each Android API level.
- platforms: The platform packages are required to compile your app for the specified API level.
- system-images: These are the android images used in the emulator.
- build-tools: These are necessary to build your Android apps
Installing the Android SDK
In order to install the SDK we will use the Command Line Tools. These are some quite simple CLI’s used to manage the Android SDK. You can read the documentation here for more details.
Step 1 — Download the tools package
First, you need to download the tools package. And with this package you can download the others.
- First, go to the Android Studio download page: https://developer.android.com/studio;
- Then click in “ Download Options”;
- There you will find a table named “ Command line tools only”;
- This table contain some zip files. Download the appropriate file for your system ( Windows, Mac or Linux);
- Extract this zip and you will get a folder called tools: This is the tools package i explained earlier;
Create a folder anywhere you prefer to place your SDK. I recommend you to stick with one of these commonly used places:
- Globally: C:\Android\sdk or C:\android-sdk (this is not default, but i usually set my SDK here on Windows)
- One user only: C:\Users\ \AppData\Local\Android\sdk
- Globally: /Library/Android/sdk
- One user only: /Users/ /Library/Android/sdk
And move the tools folder to this new sdk folder. Make sure you have admin access to this folder and any sub-folders inside it, or the tools package will fail to download new packages.
Note: You can also download a pre-build package for your SO (like the one available on Ubuntu repository). But i do not recommend you do to so, because they probably will not be updated and will be harder to manage, since it was automatically installed.
Step 2— You need Java 8!
The Android SDK packages require Java 8. If you do not have it, you need to download. If you are using a newer version, you have to downgrade to Java 8 or you will eventually get some errors, because it is not compatible.
If you do not have the Java 8 SDK, here is how you can install it:
On Ubuntu run these commands:
- # sudo apt-get update
- # sudo apt-get install openjdk-8-jdk
Sorry for MacOS users, i don’t know how to install it on this OS.
Step 3 — Download the essential packages
Now, download the platform-tools and the emulator packages, because they contain some CLI binary files you will need later. I decided to download these packages first in order to set all the necessary environment variables at once and make the rest of the process easier.
Open a terminal window (you need to use a terminal, not the file explorer), go to your sdk folder and navigate to the /tools/bin directory.
This folder contain the SDKManager binary: this is a CLI used to list the available packages in the Google’s repository and download, update or remove them from your SDK folder.
The bellow command will list all packages installed (the first items on the list) and all packages available to download:
To download the packages, simply copy the package names and pass it as a parameter to the SDKManager CLI using the terminal:
# ./sdkmanager platform-tools emulator
If you open your sdk folder you should see these packages folders there.
Step 4 — Set your environmental variables
You need to set the below environmental variables containing the path to our SDK, so any running program can find it in your pc:
ANDROID_SDK_ROOT = Path to your SDK folder
ANDROID_HOME = The same as ANDROID_SDK_ROOT. This variable is now deprecated, but i recommend setting it because some programs still using it to locate your sdk.
And add these folders to the PATH variable, making their binary files accessible from everywhere:
To add the environment variables on WIndows, just follow these steps:
- Open the “Control Panel”;
- Go to “ System and Security” option in the side menu;
- In the window “ System Properties” open the tab “ Advanced”;
- Click in the button “ Environment Variables” in the bottom of the page;
- In the “ Environment Variables” window you will see two tables: “User Variables” and ” System Variables”.
- If you created your sdk folder for one user only, set the variables in the “ User Variables” table;
- But, if you create your sdk folder globally, set the variables in the “ System Variables” table instead;
On Linux, you can set your environment variables in many places. So i choose the ones I found the most appropriate:
- If you created your sdk folder for one user only, set your environment variables in the file
/.bashrc;
Here is how i set these variables in my Ubuntu, using the file /etc/environment:
And sorry again, no MacOS instructions for this task.
You can find more about these environmental variables in the oficial docs here.
Now your SDK is ready! If you do not need to run the emulator there’s no need to follow the next steps.
Step 5 — Download the platform specific packages you want
You need more three packages: The platform, the system-image and the build-tools. You can download these packages for any Android version you prefer. In this article, i will download the packages for the API Level 28.
Use the “ sdkmanager — list” command to find these packages and download them using the command “ sdkmanager
Here’s an example:
Step 5 — Create a AVD device
Creating a AVD device is a simple task: run the AVDManager command (this is a binary file located in the tools/bin folder of your sdk) with the create avd option, a name for the new AVD and the image you want to use.
Here is a example:
# avdmanager create avd — name android28 — package “system-images;android-28;default;x86”
You will be asked if you want to alter some configurations. You can also modify these configurations later in the file config.ini, located in the avd folder (this folder usually is created in your user folder, under the android directory). The currently active configurations can be find in the file hardware-qemu.ini (this file just will be created after the emulator runs for the first time).
Step 6 — Run the Android Emulator
Now you just need to run the emulator command (remember that we added this package to the environmental variables?):
The emulator take some time to init for the first time. But if you done everything correctly you should see this screen:
Источник
Эмулятор Android SDK: обзор, инструкции, установка
Android SDK – это эмулятор и среда разработки приложений для операционной системы Андроид одновременно. Программа занимает мало места на жестком диске и предоставляет впечатляющий функционал. Хотя ПО ориентировано на профессиональных разработчиков, его могут использовать и рядовые пользователи в качестве обычного эмулятора операционной системы. Так же смотрите аналогичный эмулятор Xamarin Android Player для разработчиков.
А вы знали, что данный эмулятор также называют «Android Studio».
Функционал эмулятора
Android SDK может эмулировать не только саму операционную систему, но и «железо». На выбор доступно множество виртуальных устройств с поддержкой Андроида:
- Смартфоны;
- Планшеты;
- Телевизоры;
- Умные часы;
- Очки, шлемы дополненной и виртуальной реальности;
- Бортовые компьютеры автомобилей;
- Терминалы.
Также присутствует эмуляция различных технологий, например, Bluetooth, WiFi, 2G, 3G, Edge.
Встроенная среда разработки поддерживает написание кода программы с подсветкой синтаксиса и авто дополнением. Среди поддерживаемых языков программирования есть C, C++, Kotlin и Java. Можно одновременно скомпилировать несколько apk одного проекта, каждый для разного устройства и версии ОС. С помощью встроенного диспетчера можно отслеживать нагрузку эмулятора на систему.
Существует консольный режим для опытных разработчиков.
Интерфейс Android SDK
Программа имеет настраиваемый интерфейс, каждый пользователь может расположить любые элементы где угодно, а также выбрать цвет оформления. Сам интерфейс включает в себя такие главные элементы:
- Кнопки открытия и сохранения проектов;
- Переходы по шагам;
- Увеличение/уменьшение масштаба окна;
- Выбор apk-файла;
- Выбор эмулируемого железа и версии системы;
- Изменение разрешения экрана;
- Запуск/пауза эмуляции;
- Настройки и помощь.
Откатить изменения и вернуть изначальное расположение элементов можно в настройках.
Системные требования Android SDK
Для Windows официальные системные требования следующие:
- ОС Windows 7/8/10;
- Минимум 3 ГБ оперативной памяти для запуска, 8 ГБ рекомендовано;
- Дополнительно 1 ГБ свободной оперативной памяти для эмуляции и тестирования работы приложений;
- Минимум 2 ГБ свободного места на диске для установки, рекомендуется 4 ГБ для создания файла подкачки;
- Монитор с разрешением 1280 x 800 или выше.
Версии для Mac и Linux предъявляют почти аналогичные требования к аппаратной части компьютера, но имеют свои отличия в программной части. Mac:
- Mac OS X 10.10 (Yosemite) или новее, но не выше 10.13 (macOS High Sierra);
- 1.5 ГБ свободного места для установки эмулятора;
- 500 МБ на диске для интегрированной среды разработки (опционально).
Официально версия Linux тестировалась на Ubuntu 14.04. Имеет следующие требования:
- Графическая оболочка GNOME или KDE;
- Библиотека GNU C (glibc) 2.19 или новее.
Эмулятор работает на 32 и на 64-битных системах.
Производительность
Программа сильно уступает аналогам в производительности, жертвуя ей в угоду точности. Соответственно, требования к железу в несколько раз выше. К другим недостаткам можно отнести:
- Отсутствие русcкоязычной версии;
- Нестабильная работа на Windows XP и старых версиях Mac OS X;
- Необходимость установки дополнительных пакетов Java JRE и Java SE Development Kit SDK;
- Не работает на процессорах без поддержки виртуализации.
В настройках программы можно выбрать ночную тему интерфейса.
Инструкция: Как установить эмулятор Android SDK на свой ПК?
Установка предельно проста. Загрузите установочный файл по ссылке ниже. Затем запустите его, 2 раза кликнув левой кнопкой мыши. В окне установщика ознакомьтесь с лицензией и нажимайте далее. Укажите путь установки. Выберите, какие версии Андроида вы хотите эмулировать. По умолчанию устанавливаются только новейшие варианты. Нажимайте OK и начнется установка.
Подробный видеообзор установки эмулятора Android SDK.
ВАЖНО: Чем больше компонентов будет выбрано при установке, тем больше потребуется места на диске.
Особенности эмулятора
Эмулятор имеет много преимуществ перед аналогами:
- Стабильность;
- Высокая производительность;
- Официальная техническая поддержка;
- Подробная документация и множество обучающих материалов;
- Встроенный файловый менеджер;
- Открытый исходный код;
- Поддержка стандартов GSM-телефонии;
- Тестирование созданных программ для Андроид;
- Поддержка виртуальных машин, например, Dalvik;
- Настраиваемый интерфейс.
Благодаря этим особенностям, Android SDK можно назвать самым функциональным в своей области. Сочетание средств разработки и возможности быстрого тестирования в одной программе определенно порадует разработчиков мобильных приложений. Рядовым пользователям, возможно, стоит обратить внимание на более простые аналоги.
Источник