docs: Migrated "Android Runtime on Chrome" pages to DAC
am: 9cd48bb447
Change-Id: Ieecc7bca2ef4d9e987554c4552a1025ab51e7bd7
This commit is contained in:
BIN
docs/html/images/topic/arc/sideload_figure_1.jpg
Normal file
BIN
docs/html/images/topic/arc/sideload_figure_1.jpg
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 62 KiB |
153
docs/html/topic/arc/device-support.jd
Normal file
153
docs/html/topic/arc/device-support.jd
Normal file
@@ -0,0 +1,153 @@
|
|||||||
|
page.title=Chrome OS Device Support for Apps
|
||||||
|
@jd:body
|
||||||
|
|
||||||
|
<div id="qv-wrapper">
|
||||||
|
<div id="qv">
|
||||||
|
<h2>On this page</h2>
|
||||||
|
|
||||||
|
<ol>
|
||||||
|
<li><a href="#overview">Overview</a></li>
|
||||||
|
<li><a href="#support">Supported Platforms</a></li>
|
||||||
|
</ol>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
You can use the Google Play Store to install Android apps on several Google
|
||||||
|
Chromebooks. This document describes the Chromebooks, Chromeboxes, and
|
||||||
|
Chromebases that can install Android apps, both currently and in upcoming
|
||||||
|
releases of Chrome OS.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<h2 id="overview">Overview</h2>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
The same Android apps that run on phones and tablets can run on Chromebooks
|
||||||
|
without compromising their speed, simplicity, or security. To develop the best
|
||||||
|
experience for Android apps across Chromebooks, you should test your app on a
|
||||||
|
suite of devices that consists of the following categories:
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<ul>
|
||||||
|
<li>
|
||||||
|
ARM architecture.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
Intel x86 architecture.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
Touch.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
Non-touch (uses fake-touch).
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
Convertible.
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<p>To learn more about Google Play Store support on Chromebooks, see the
|
||||||
|
following <a class="external-link"
|
||||||
|
href="https://chrome.googleblog.com/2016/05/the-google-play-store-coming-to.html">
|
||||||
|
Google Chrome blog post</a>.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<p class="note"><strong>Note: </strong>You may elect to exclude your app from
|
||||||
|
being available to Chromebooks. For more information, visit <a
|
||||||
|
class="external-link"
|
||||||
|
href="https://support.google.com/googleplay/android-developer/answer/1286017?hl=en">
|
||||||
|
View & restrict your app's compatible devices</a>.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
The following section lists the Chromebooks that work with Android apps and the
|
||||||
|
categories that each device satisfies.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<h2 id="support">Supported Platforms</h2>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
Android apps are not available on every Chromebook, but Google continues to
|
||||||
|
evaluate more devices based on a range of factors, such as processor type, GPU,
|
||||||
|
and drivers. The following table shows the platforms that currently support
|
||||||
|
Android apps:
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<p class="table-caption" id="Objects-and-interfaces">
|
||||||
|
<strong>Table 1.</strong> Chromebooks that currently support Android apps.</p>
|
||||||
|
<table>
|
||||||
|
<tr>
|
||||||
|
<th scope="col">Manufacturer</th>
|
||||||
|
<th scope="col">Model</th>
|
||||||
|
<th scope="col">Architecture</th>
|
||||||
|
<th scope="col">Touchscreen support</th>
|
||||||
|
<th scope="col">Convertible</th>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>Acer</td>
|
||||||
|
<td>Chromebook R11 / C738T</td>
|
||||||
|
<td>Intel x86</td>
|
||||||
|
<td>Yes</td>
|
||||||
|
<td>Yes</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>Asus</td>
|
||||||
|
<td>Chromebook Flip</td>
|
||||||
|
<td>ARM</td>
|
||||||
|
<td>Yes</td>
|
||||||
|
<td>Yes</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>Google</td>
|
||||||
|
<td>Chromebook Pixel (2015)</td>
|
||||||
|
<td>Intel x86</td>
|
||||||
|
<td>Yes</td>
|
||||||
|
<td>No</td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
The following list shows the platforms that will support Android apps in an
|
||||||
|
upcoming release of Chrome OS:
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<ul>
|
||||||
|
<li><strong>Acer: </strong>Chromebook 11 C740, Chromebook 11 CB3-111 / C730 /
|
||||||
|
C730E / CB3-131, Chromebook 14 CB3-431, Chromebook 14 for Work, Chromebook
|
||||||
|
15 CB5-571 / C910, Chromebook 15 CB3-531, Chromebox CXI2, Chromebase 24
|
||||||
|
</li>
|
||||||
|
<li><strong>Asus: </strong>Chromebook C200, Chromebook C201,
|
||||||
|
Chromebook C202SA, Chromebook C300SA, Chromebook C300, Chromebox CN62,
|
||||||
|
Chromebit CS10</li>
|
||||||
|
<li><strong>AOpen: </strong>Chromebox Commercial,
|
||||||
|
Chromebase Commercial 22"</li>
|
||||||
|
<li><strong>Bobicus: </strong>Chromebook 11</li>
|
||||||
|
<li><strong>CDI: </strong>eduGear Chromebook K Series,
|
||||||
|
eduGear Chromebook M Series, eduGear Chromebook R Series</li>
|
||||||
|
<li><strong>CTL: </strong>Chromebook J2 / J4, N6 Education Chromebook,
|
||||||
|
J5 Convertible Chromebook</li>
|
||||||
|
<li><strong>Dell: </strong>Chromebook 11 3120, Chromebook 13 7310</li>
|
||||||
|
<li><strong>Edxis: </strong>Chromebook, Education Chromebook</li>
|
||||||
|
<li><strong>Haier: </strong>Chromebook 11, Chromebook 11e, Chromebook 11 G2
|
||||||
|
</li>
|
||||||
|
<li><strong>Hexa: </strong>Chromebook Pi</li>
|
||||||
|
<li><strong>HiSense: </strong>Chromebook 11</li>
|
||||||
|
<li><strong>Lava: </strong>Xolo Chromebook</li>
|
||||||
|
<li><strong>HP: </strong>Chromebook 11 G3 / G4 / G4 EE, Chromebook 14 G4,
|
||||||
|
Chromebook 13</li>
|
||||||
|
<li><strong>Lenovo: </strong>100S Chromebook, N20 / N20P Chromebook,
|
||||||
|
N21 Chromebook, ThinkCentre Chromebox, ThinkPad 11e Chromebook,
|
||||||
|
N22 Chromebook, Thinkpad 13 Chromebook, Thinkpad 11e Chromebook Gen 3</li>
|
||||||
|
<li><strong>Medion: </strong>Akoya S2013, Chromebook S2015</li>
|
||||||
|
<li><strong>M&A: </strong>Chromebook</li>
|
||||||
|
<li><strong>NComputing: </strong>Chromebook CX100</li>
|
||||||
|
<li><strong>Nexian: </strong>Chromebook 11.6"</li>
|
||||||
|
<li><strong>PCMerge: </strong>Chromebook PCM-116E</li>
|
||||||
|
<li><strong>Poin2: </strong>Chromebook 11</li>
|
||||||
|
<li><strong>Samsung: </strong>Chromebook 2 11" - XE500C12, Chromebook 3</li>
|
||||||
|
<li><strong>Sector 5: </strong>E1 Rugged Chromebook</li>
|
||||||
|
<li><strong>Senkatel: </strong>C1101 Chromebook</li>
|
||||||
|
<li><strong>Toshiba: </strong>Chromebook 2, Chromebook 2 (2015)</li>
|
||||||
|
<li><strong>True IDC: </strong>Chromebook 11</li>
|
||||||
|
<li><strong>Viglen: </strong>Chromebook 11</li>
|
||||||
|
</ul>
|
||||||
398
docs/html/topic/arc/index.jd
Normal file
398
docs/html/topic/arc/index.jd
Normal file
@@ -0,0 +1,398 @@
|
|||||||
|
page.title=Optimizing Apps for Chromebooks
|
||||||
|
@jd:body
|
||||||
|
|
||||||
|
<div id="qv-wrapper">
|
||||||
|
<div id="qv">
|
||||||
|
<h2>On this page</h2>
|
||||||
|
|
||||||
|
<ol>
|
||||||
|
<li><a href="#update-manifest">Update Your App's Manifest File</a></li>
|
||||||
|
<li><a href="#leverage">Leverage Support for Multi-Window Mode</li>
|
||||||
|
<li><a href="#keyboard">Support the Keyboard, Trackpad, and Mouse</a></li>
|
||||||
|
<li><a href="#backup">Use Backup and Restore Effectively</a></li>
|
||||||
|
<li><a href="#update-ndk">Update the NDK Libraries</a></li>
|
||||||
|
<li><a href="#support-new-features">Plan Support for New Android Features</a></li>
|
||||||
|
<li><a href="#testing">Test Your App</a></li>
|
||||||
|
<li><a href="#setup">Set Up ADB</a></li>
|
||||||
|
<li><a href="#learning-materials">Additional Learning Materials</a></li>
|
||||||
|
</ol>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
Google Chromebooks now support the Google Play Store and Android apps. This
|
||||||
|
document describes some ways that you can optimize your Android apps for
|
||||||
|
Chromebooks.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<h2 id="update-manifest">Update Your App's Manifest File</h2>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
To begin optimizing your Android app for Chromebooks, update your manifest file
|
||||||
|
(<code>AndroidManifest.xml</code>) to account for some key hardware and software
|
||||||
|
differences between Chromebooks and other devices running Android.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
As of Chrome OS version M53, all Android apps that don't explicitly require the
|
||||||
|
<a
|
||||||
|
href="{@docRoot}guide/topics/manifest/uses-feature-element.html#touchscreen-hw-features"><code>android.hardware.touchscreen</code></a>
|
||||||
|
feature will also work on Chrome OS devices that support the
|
||||||
|
<code>android.hardware.faketouch</code> feature. However, if you want your app
|
||||||
|
to work on all Chromebooks in the best possible way, go to your manifest file
|
||||||
|
and adjust the settings so that the <code>android.hardware.touchscreen</code>
|
||||||
|
feature is not required, as shown in the following example. You should also
|
||||||
|
review your mouse and keyboard interactions.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<pre>
|
||||||
|
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
... >
|
||||||
|
<!-- Some Chromebooks don't support touch. Although not essential,
|
||||||
|
it's a good idea to explicitly include this declaration. -->
|
||||||
|
<uses-feature android:name="android.hardware.touchscreen"
|
||||||
|
required="false" />
|
||||||
|
</manifest>
|
||||||
|
</pre>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
Different devices often have different sensors available in them. See the <a
|
||||||
|
href="https://developer.android.com/guide/topics/sensors/sensors_overview.html">Sensors
|
||||||
|
Overview</a> document for an overview of all sensors that the Android platform
|
||||||
|
supports. Although Android handheld devices may have GPS and accelerometers,
|
||||||
|
sensors are not guaranteed to be available in every Chromebook. However, there
|
||||||
|
are cases where the functionality of a sensor is provided in another way. For
|
||||||
|
example, Chromebooks may not have GPS sensors, but they still provide location
|
||||||
|
data based on Wi-Fi connections. If you want your app to run on Chromebooks,
|
||||||
|
regardless of sensor support, you should update your manifest file so that none
|
||||||
|
of the sensors are required.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<p class="note"><strong>Note</strong>: If you don't require a particular sensor
|
||||||
|
for your app but still use measurements from the sensor when it's available,
|
||||||
|
make sure you dynamically check for the sensor's availability before trying to
|
||||||
|
gather information from it in your app.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
Some software features are unsupported on Chromebooks. For example, apps that
|
||||||
|
provide custom IMEs, app widgets, live wallpapers, and app launchers aren't
|
||||||
|
supported and won't be available for installation on Chromebooks. For a complete
|
||||||
|
list of software features that aren't currently supported on Chromebooks, see <a
|
||||||
|
href="{@docRoot}topic/arc/manifest.html#incompat-software-features">incompatible
|
||||||
|
software features</a>.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<h2 id="leverage">Leverage Support for Multi-Window Mode</h2>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
The implementation of Android apps on Chrome OS includes basic multi-window
|
||||||
|
support. Instead of automatically drawing over the full screen, Android renders
|
||||||
|
apps on Chrome OS into layouts that are appropriate for this form factor. Google
|
||||||
|
provides support for the most common window layouts:
|
||||||
|
|
||||||
|
<ul>
|
||||||
|
<li>
|
||||||
|
<strong>Portrait</strong> – Similar to Nexus 5.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<strong>Landscape</strong> – Similar to Nexus 7.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<strong>Maximized</strong> – Uses all available screen pixels.
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
In addition, end users are presented with window controls to toggle among all
|
||||||
|
available layouts. By choosing the correct orientation option, you can ensure
|
||||||
|
that the user has the correct layout upon launching the app. If an app is
|
||||||
|
available in portrait and landscape, it defaults to landscape if possible. After
|
||||||
|
this option is set, it is remembered on a per-app basis. Google recommends that
|
||||||
|
you test your app to ensure that it handles changes in window size
|
||||||
|
appropriately.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<h2 id="keyboard">Support the Keyboard, Trackpad, and Mouse</h2>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
All Chromebooks have a physical keyboard and a trackpad, and some Chromebooks
|
||||||
|
have a touchscreen as well. Some devices can even convert from a laptop to a
|
||||||
|
tablet.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
Many existing apps already support mouse and trackpad interactions with no extra
|
||||||
|
work required. However, it's always best to adjust your app's behavior
|
||||||
|
appropriately when users interact with it using a trackpad instead of a
|
||||||
|
touchscreen, and you should support and distinguish between both interfaces
|
||||||
|
properly. Given the support for physical keyboards, you can now provide hotkeys
|
||||||
|
to enable your app's users to be more productive. For example, if your app
|
||||||
|
supports printing, you can use <strong>Ctrl+P</strong> to open a print dialog.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<h2 id="backup">Use Backup and Restore Effectively</h2>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
One of the strongest features of Chromebooks is that users can easily migrate
|
||||||
|
from one device to another. That is, if someone stops using one Chromebook and
|
||||||
|
starts using another, they simply have to sign in, and all of their apps appear.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<p class="note"><strong>Tip: </strong> Although it's not mandatory, backing up
|
||||||
|
your app's data to the cloud is a good idea.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
Chromebooks can also be shared among a large number of people, such as in
|
||||||
|
schools. Since local storage is not infinite, entire accounts—together
|
||||||
|
with their storage—can be removed from the device at any point. For
|
||||||
|
educational settings, it's a good idea to keep this scenario in mind.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<h2 id="update-ndk">Update the NDK Libraries</h2>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
If your app uses the Android NDK libraries, and its target SDK version is 23 or
|
||||||
|
higher, ensure that text relocations are removed from both the ARM and x86
|
||||||
|
versions of your NDK libraries, as they're not compatible in Android 6.0 (API
|
||||||
|
level 23) and higher. By leaving text relocations in your NDK libraries, you may
|
||||||
|
also cause incompatibility errors with Chromebooks, especially when running on
|
||||||
|
a device that uses an x86 architecture.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<p class="note"><strong>Note: </strong>To view more details on updating NDK
|
||||||
|
libraries properly, see the <a
|
||||||
|
href="https://developer.android.com/about/versions/marshmallow/android-6.0-changes.html#behavior-runtime">
|
||||||
|
Runtime</a> section of the Android 6.0 Changes document.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<h2 id="support-new-features">Plan Support for New Android Features</h2>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
Android apps on Chromebooks initially ship with APIs for Android 6.0 (API level
|
||||||
|
23). By following the best practices outlined above, your app is likely to be
|
||||||
|
compatible with the multi-window improvements introduced in Android 7.0 (API
|
||||||
|
level 24). It's good to plan support for the APIs and behaviors available as of
|
||||||
|
Android 7.0, which feature several improvements. For example, multi-window
|
||||||
|
support is better integrated, and you're able to resize activities arbitrarily,
|
||||||
|
making them feel more natural. You can also access APIs for drag-and-drop
|
||||||
|
operations across apps and mouse cursor control.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<h2 id="testing">Test Your App</h2>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
To <a href="{@docRoot}topic/arc/sideload.html">load</a> your app onto your
|
||||||
|
Chromebook for testing, you must enter <em>Developer</em> mode on your Chrome OS
|
||||||
|
device and enable <em>unknown sources</em>. See the <a class="external-link"
|
||||||
|
href="https://www.chromium.org/chromium-os/poking-around-your-chrome-os-device#TOC-Putting-your-Chrome-OS-Device-into-Developer-Mode">
|
||||||
|
Putting your Chrome OS Device into Developer Mode</a> document for detailed
|
||||||
|
instructions about moving your device into Developer mode. After your device is
|
||||||
|
in Developer mode, you can go to your Chrome settings and select <strong>Enable
|
||||||
|
Unknown Sources</strong> under the <em>security in app</em> settings.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
After enabling Developer mode, you can load an Android app onto your Chrome OS
|
||||||
|
device using one of several methods. For more details, see the <a
|
||||||
|
href="{@docRoot}topic/arc/sideload.html#load-app">Load Your App</a> section of
|
||||||
|
the Loading Apps on Chromebooks page.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<p class="note"><strong>Note: </strong>To ensure that your Android app works
|
||||||
|
well on a variety of Chromebook devices and available form factors, Google
|
||||||
|
recommends that you test your app on an ARM-based Chromebook, an x86-based
|
||||||
|
Chromebook, a device with a touchscreen and one without one, and on a
|
||||||
|
convertible device (one that can change between a laptop and a tablet). To view
|
||||||
|
the full list of supported devices, see the <a
|
||||||
|
href="{@docRoot}topic/arc/device-support.html">Chrome OS Device Support for
|
||||||
|
Apps</a> page.</p>
|
||||||
|
|
||||||
|
<h2 id="setup">Set Up ADB</h2>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
Before attempting to set up an ADB connection, you must start your Chrome OS in
|
||||||
|
<a class="external-link"
|
||||||
|
href="https://www.chromium.org/chromium-os/poking-around-your-chrome-os-device">
|
||||||
|
Developer Mode</a> so that you have the ability to install Android apps on the
|
||||||
|
Chromebook.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<p class="caution"><strong>Caution: </strong>After switching your Chrome OS
|
||||||
|
device to Developer mode, it restarts and clears all existing data on the
|
||||||
|
device.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
To set up ADB, complete the following steps:
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<ol>
|
||||||
|
<li>
|
||||||
|
Press <strong>Ctrl+D</strong> to start your device.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
Finish the setup process.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
Log into your test account.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
Accept the Google Play Store terms and service conditions.
|
||||||
|
</li>
|
||||||
|
</ol>
|
||||||
|
|
||||||
|
<h3>Configure the firewall</h3>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
To configure the Chrome OS firewall to allow incoming ADB connections, complete
|
||||||
|
the following steps:
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<ol>
|
||||||
|
<li>
|
||||||
|
Press <strong>Ctrl+Alt+T</strong> to start the Chrome OS terminal.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
Type <strong>shell</strong> to get to the bash command shell:
|
||||||
|
<pre class="no-pretty-print">
|
||||||
|
crosh> shell
|
||||||
|
chronos@localhost / $
|
||||||
|
</pre>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
Type the following commands to set up developer features and enable
|
||||||
|
disk-write access for the firewall settings changes:
|
||||||
|
<pre class="no-pretty-print">
|
||||||
|
chronos@localhost / $ sudo /usr/libexec/debugd/helpers/dev_features_rootfs_verification
|
||||||
|
chronos@localhost / $ sudo reboot
|
||||||
|
</pre>
|
||||||
|
The <em>sudo reboot</em> command restarts your Chromebook.
|
||||||
|
<p class="note"><strong>Note</strong>: You can press the <strong>Tab</strong>
|
||||||
|
key to enable autocompletion of file names.</p>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
After your device restarts, log in to your test account and type the
|
||||||
|
following command to enable the <em>secure shell</em> and configure the
|
||||||
|
firewall properly:
|
||||||
|
<pre class="no-pretty-print">
|
||||||
|
chronos@localhost / $ sudo /usr/libexec/debugd/helpers/dev_features_ssh
|
||||||
|
</pre>
|
||||||
|
You can now exit out of the shell.
|
||||||
|
</li>
|
||||||
|
</ol>
|
||||||
|
|
||||||
|
<p class="note"><strong>Note</strong>: You must complete this procedure only
|
||||||
|
once on your Chromebook.</p>
|
||||||
|
|
||||||
|
<h3>Check the IP address of your Chromebook</h3>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
To verify the IP address of your Chromebook, complete the following steps:
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<ol>
|
||||||
|
<li>
|
||||||
|
Click the clock icon in the bottom-right area of the screen.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
Click <strong>Settings</strong>.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
The <em>Internet Connection</em> section in the Settings area lists all of
|
||||||
|
the available networks. Select the one that you want to use for ADB.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
Take note of the IP address that appears.
|
||||||
|
</li>
|
||||||
|
</ol>
|
||||||
|
|
||||||
|
<h3>Enable ADB debugging</h3>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
To enable ADB debugging, complete the following steps:
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<ol>
|
||||||
|
<li>
|
||||||
|
Click the clock icon in the bottom-right area of the screen.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
Click <strong>Settings</strong>.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
In the <em>Android Apps</em> section, click the <strong>Settings</strong>
|
||||||
|
link in the line that reads <em>Manage your Android apps in Settings</em>.
|
||||||
|
This brings up the Android apps settings.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
Click <strong>About device</strong>.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
Click <strong>Build number</strong> seven times to move into Developer mode.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
Click the arrow in the top-left area of the window to go back to the main
|
||||||
|
Settings screen.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
Click the new <strong>Developer options</strong> item, activate <strong>ADB
|
||||||
|
debugging</strong>, and then click <strong>OK</strong> to allow ADB
|
||||||
|
debugging.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
Return to your development machine and use ADB to connect to your
|
||||||
|
Chromebook's using its IP address and port 22.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
On your Chromebook, click <strong>Allow</strong> when prompted whether you
|
||||||
|
want to allow the debugger. Your ADB session is established.
|
||||||
|
</li>
|
||||||
|
</ol>
|
||||||
|
|
||||||
|
<h4>Troubleshooting ADB debugging</h4>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
Sometimes the ADB device shows that it's offline when everything is connected
|
||||||
|
properly. In this case, complete the following steps to troubleshoot the issue:
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<ol>
|
||||||
|
<li>
|
||||||
|
Deactivate <strong>ADB debugging</strong> in <em>Developer options</em>.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
In a terminal window, run <code>adb kill-server</code>.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
Re-activate the <strong>ADB debugging</strong> option.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
In a terminal window, attempt to run <code>adb connect</code>.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
Click <strong>Allow</strong> when prompted whether you want to allow
|
||||||
|
debugging. Your ADB session is established.
|
||||||
|
</li>
|
||||||
|
</ol>
|
||||||
|
|
||||||
|
<h2 id="learning-materials">Additional Learning Materials</h2>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
To learn more about optimizing your Android apps for Chromebooks, consult the
|
||||||
|
following resources:
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<ul>
|
||||||
|
<li>
|
||||||
|
Review the
|
||||||
|
<a class="external-link" href="http://android-developers.blogspot.com/2016/05/bring-your-android-app-to-chromebooks.html">
|
||||||
|
Bring your Android App to Chromebooks</a> I/O session.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
Post a question on the <a class="external-link"
|
||||||
|
href="https://plus.sandbox.google.com/+AndroidDevelopers">Android developer
|
||||||
|
community</a> with hashtag <em>#AndroidAppsOnChromeOS</em>.
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
125
docs/html/topic/arc/sideload.jd
Normal file
125
docs/html/topic/arc/sideload.jd
Normal file
@@ -0,0 +1,125 @@
|
|||||||
|
page.title=Loading Apps on Chromebooks
|
||||||
|
@jd:body
|
||||||
|
|
||||||
|
<div id="qv-wrapper">
|
||||||
|
<div id="qv">
|
||||||
|
<h2>On this page</h2>
|
||||||
|
|
||||||
|
<ol>
|
||||||
|
<li><a href="#enter-dev">Enter Developer Mode</a></li>
|
||||||
|
<li><a href="#enable-unknown">Enable Unknown Sources</a></li>
|
||||||
|
<li><a href="#load-app">Load Your App</a></li>
|
||||||
|
</ol>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
This document describes how to enter <em>Developer</em> mode and enable
|
||||||
|
<em>unknown resources</em> so that you can load Android apps on your Google
|
||||||
|
Chromebook.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<h2 id="enter-dev">Enter Developer Mode</h2>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
To load Android apps, you must enable unknown sources. Enabling unknown sources
|
||||||
|
is available only when your device is in Developer mode.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<p class="caution"><strong>Caution: </strong>Modifications that you make to the
|
||||||
|
system are not supported by Google and may void your warranty. Additionally,
|
||||||
|
modifications may cause hardware, software, or security issues.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<p class="note"><strong>Note: </strong>On most devices, both the
|
||||||
|
<em>recovery</em> button and the <em>dev-switch</em> button are virtualized. If
|
||||||
|
these instructions don't work for you, see the <a class="external-link"
|
||||||
|
href="https://www.chromium.org/chromium-os/developer-information-for-chrome-os-devices">
|
||||||
|
specific instructions for your device</a>.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
To enter Developer mode, complete these steps:
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<ol>
|
||||||
|
<li>
|
||||||
|
Invoke <em>Recovery</em> mode by pressing and holding the
|
||||||
|
<strong>Esc</strong> and <strong>Refresh (F3)</strong> keys, then pressing
|
||||||
|
the <strong>Power</strong> button.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
When the <em>Recovery</em> screen appears, press <strong>Ctrl+D</strong>.
|
||||||
|
There's no prompt for this action, so you must simply complete it.
|
||||||
|
Afterwards, you are prompted to confirm and reboot into Developer mode.
|
||||||
|
</li>
|
||||||
|
</ol>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
If you see one of the following screens when you turn on your device, you've
|
||||||
|
successfully entered Developer mode:
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<img src="{@docRoot}images/topic/arc/sideload_figure_1.jpg" />
|
||||||
|
|
||||||
|
<p class="img-caption"><strong>Figure 1. </strong>Developer mode confirmation
|
||||||
|
screens.</p>
|
||||||
|
|
||||||
|
<p class="note"><strong>Note</strong>: To skip the OS loading screen, either
|
||||||
|
wait 30 seconds or press <strong>Ctrl+D</strong>, and your Chromebook continues
|
||||||
|
starting.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<h2 id="enable-unknown">Enable Unknown Sources</h2>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
To enable unknown sources, navigate to <strong>Chrome Settings > App Settings >
|
||||||
|
Security</strong>, then enable <strong>Unknown sources</strong> by moving the
|
||||||
|
slider to the right.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<p class="note"><strong>Note:</strong>You can enable unknown sources only when
|
||||||
|
your device is in <a
|
||||||
|
href="{@docRoot}topic/arc/sideload.html#enter-dev">Developer mode</a>.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<h2 id="load-app">Load Your App</h2>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
After enabling unknown sources, you can load apps by copying an app's APK file
|
||||||
|
to the <em>Downloads</em> folder and opening it with Android's File Manager app.
|
||||||
|
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
You can copy the APK file to your Chromebook using one of the following methods:
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<ul>
|
||||||
|
<li>
|
||||||
|
<strong>Using a cloud app</strong> – Upload your APK file to Google
|
||||||
|
Drive or send it to yourself via email. Open it with the Android app
|
||||||
|
equivalent (Drive and Gmail, respectively).
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<strong>Using an external storage device</strong> – Transfer the APK
|
||||||
|
file to the Downloads folder of your Chromebook using a thumb drive, SD
|
||||||
|
card, or an external hard drive. Afterwards, open the Android File Manager
|
||||||
|
app by navigating to <strong>Chrome Settings > App Settings > Device &
|
||||||
|
USB > Explore</strong>.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<strong>Using ADB</strong> – After <a
|
||||||
|
href="{@docRoot}topic/arc/index.html#setup"> setting up ADB</a> on your
|
||||||
|
Chromebook, enter the following command into a terminal window on your
|
||||||
|
development workstation:
|
||||||
|
<pre class="no-pretty-print">
|
||||||
|
adb install <var>app-name</var>.apk
|
||||||
|
</pre>
|
||||||
|
<p>This command pushes the app to your connected Chromebook and installs the
|
||||||
|
app. For more information about copying and installing apps from a
|
||||||
|
development computer, see <a
|
||||||
|
href="{@docRoot}studio/command-line/adb.html#move">Installing an
|
||||||
|
Application</a>.</p>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
Reference in New Issue
Block a user