Showing posts with label Developer Preview. Show all posts
Showing posts with label Developer Preview. Show all posts

11/30/17

Android Things Developer Preview 6

Posted by Wayne Piekarski,
Developer Advocate for IoT



The next release of Android Things Developer Preview 6 (DP6) is here with lots
of new features and bug fixes. Android Things is Google's platform that enables
Android Developers to create Internet of Things (IoT) devices with support for
powerful applications such as video and audio processing and on-board machine
learning with TensorFlow. For the specifics on what is new, visit the href="https://developer.android.com/things/preview/releases.html">release
notes. Here are a few of the highlights of what is in DP6.


IoT launcher



DP6 includes a new IoT launcher that allows the user to see the current state of
the device and change settings using a touch screen or USB input devices.
Settings such as configuring the WiFi, finding the build ID, and checking for
updates is now something that can be done interactively, making it even easier
to get started. This launcher is visible when no other developer-provided href="https://developer.android.com/things/sdk/index.html#home_activity_support">IOT_LAUNCHER
Activity is present.



Graphics acceleration defaults



Android Things uses the open-source href="https://github.com/google/swiftshader">SwiftShader library, a
CPU-based implementation of the OpenGL ES APIs. This enables common OpenGL
support across all platforms, even those with no GPU hardware. However, many
simple 2D UIs render faster if the drawing is done directly to the framebuffer
and OpenGL emulation is not used. In DP6, OpenGL rendering is disabled by
default to ensure that most apps run with the fastest UI possible. If you need
OpenGL support for 3D rendering, WebView, or TextureView, then explicitly enable
it in your AndroidManifest.xml according to the href="https://developer.android.com/guide/topics/graphics/hardware-accel.html">documentation:




<activity

...
android:hardwareAccelerated="true">

API 27 and Google Play Services



DP6 is now based on the latest Android 8.1 developer preview, with API level 27.
Most of the standard Android samples now work on DP6. For example, the href="https://github.com/googlesamples/android-Camera2Basic">Camera2Basic
sample using the Camera2 API and TextureView now works on both NXP and Raspberry
Pi based devices (with the hardwareAccelerated flag set to true). Google Play
Services has been updated to support SDK version 11.6, supporting all the href="https://developers.google.com/android/guides/releases">latest
features.


Command-line flashing tool



We heard from developers that flashing and configuring a board using fastboot
can be tedious, so the href="https://partner.android.com/things/console/#/tools">Android Things
Console now brings a new and simpler way of flashing device images. Instead
of using fastboot and adb commands manually, a new interactive command-line
href="https://partner.android.com/things/console/#/tools">android-things-setup-utility
is now provided. This tool makes it much easier to get started with Android
Things, and automates the download and flashing process.

Android Things Console updates



DP6 introduces the new partition scheme that will be used for the upcoming
production release. Due to the new partition layout, the over-the-air update
(OTA) system cannot update existing DP5.1 or earlier devices. Developers will
need to go to the Android
Things Console
, and download and flash a new DP6 build. The Console UI has
also been changed for DP6 features, and will only allow you to create new builds
based on DP6. If you have any older existing builds, they are still available
for download but will not support OTA updates. Developers are encouraged to move
all work to DP6.


GPIO pin naming



The interactive IoT launcher shown at boot now includes an I/O pinout section
where you can discover the labels of all the pins. The pin naming used by the
i.MX7 has been changed, and you should update your code to use this new naming
convention. See the href="https://developer.android.com/things/hardware/imx7d-pico-io.html">i.MX7
documentation for the complete list of pin names.



Settings and Device Update APIs



New APIs have been added to Android Things that control the href="https://developer.android.com/things/sdk/apis/settings.html">configuration
of the local device and device href="https://developer.android.com/things/sdk/apis/update.html">updates. href="https://developer.android.com/things/reference/com/google/android/things/update/UpdateManager.html">UpdateManager
gives developers control over when updates and reboots can be performed,
ensuring the device is available for the user when needed. href="https://developer.android.com/things/reference/com/google/android/things/device/DeviceManager.html">DeviceManager
controls factory reset, reboot, and device locales. APIs are also provided for
settings such as href="https://developer.android.com/things/reference/com/google/android/things/device/ScreenManager.html">ScreenManager
to control the screen, and href="https://developer.android.com/things/reference/com/google/android/things/device/TimeManager.html">TimeManager
to control the clock and time zone.


Peripheral command-line tool



We now provide a command-line tool href="https://developer.android.com/things/sdk/pio/pio-cli.html">pio
that gives developers access to the Peripheral API via the adb shell. Developers
can interactively test GPIO, PWM, UART, I2C, SPI, and future interfaces from an
adb shell, which is useful for debugging and automated testing.

Feedback



DP6 includes significant changes and improvements to the platform. Please send
us your feedback by filing href="https://code.google.com/p/android/issues/entry?template=Android%20Things%20bug%20report">bug
reports and href="https://code.google.com/p/android/issues/entry?template=Android%20Things%20feature%20request">feature
requests, as well as asking any questions on href="http://stackoverflow.com/questions/tagged/android-things">Stack
Overflow. To start using DP6, use the href="https://partner.android.com/things/console">Android Things Console to
download system images and flash existing devices, or use the href="https://partner.android.com/things/console/#/tools">android-things-setup-utility.
More information about the changes are available in the href="https://developer.android.com/things/preview/releases.html">release
notes. You can also join Google's IoT
Developers Community
on Google+, a great resource to get updates and discuss
ideas. Also, we have our new hackster.io
community
, where everyone can share the amazing projects they have built. We
look forward to seeing what you build with Android Things!


Read more

8/11/17

Android Things Developer Preview 5

Posted by Wayne Piekarski,
Developer Advocate for IoT


Today, we're releasing Developer Preview 5 (DP5) of href="https://developer.android.com/things/index.html">Android Things, which
includes the major change of being based on the upcoming Android O release.
Android Things is Google's platform to enable Android Developers to create
Internet of Things (IoT) devices, and seamlessly scale from prototype to
production.


Android O



Android O is currently under href="https://android-developers.googleblog.com/2017/07/developer-preview-4-now-available.html">Developer
Preview for phones and tablets, and DP5 is now based on this upcoming
release (previous releases were based on Android N). This means that your future
Android Things applications should target API 26 to work correctly on the
platform with our support libraries.


Hardware Changes



DP5 now adds support for the new href="https://developer.android.com/things/hardware/imx6ul.html">NXP SprIoT
i.MX6UL design, as listed in our developer kits href="https://developer.android.com/things/hardware/developer-kits.html">documentation.
With Intel discontinuing the href="https://software.intel.com/en-us/iot/hardware/edison">Edison and href="https://software.intel.com/en-us/iot/hardware/joule">Joule hardware
designs, these platforms are moving to legacy support. They will not continue to
receive the latest platform updates, but developers may continue to access the
DP4.1 system images from the Android Things Console.



An important goal of Android Things is to help developers seamlessly scale from
prototype to production. When we exit Developer Preview, we will differentiate
between hardware platforms targeted for prototyping-only and hardware reference
designs that can scale to production. Production-ready hardware will satisfy
Google's security requirements and include long term support from the silicon
manufacturers. We will have more to share later on.


Improvements



With the move to the Android O codebase, there are new API features from Android
as well as specific features for Android Things. For those developers using
UserDriver APIs, you will need to add new permissions to your
AndroidManifest.xml. The href="https://developers.android.com/things/sdk/drivers/index.html">documentation
contains details about the permissions needed for each driver type. DP5 also now
supports OpenGL ES 2.0 and WebView on the Raspberry Pi 3, which was a highly
requested feature from developers. We have also implemented href="https://developer.android.com/things/hardware/raspberrypi-mode-matrix.html">dynamic
pin muxing for the Raspberry Pi 3, with pins being configured at runtime
depending on what features are being used.


Android Studio



The samples for Android Things are now available directly in Android Studio for
browsing and importing. You can now go to File, New, Import Samples, and search
for Things to see everything that is available. We have a wide range of samples,
demonstrating how to interact with buttons, sensors, LEDs, and displays, as well
as implementing Google Assistant and TensorFlow.


Android Things Console



We recently href="https://android-developers.googleblog.com/2017/06/android-things-console-developer-preview.html">launched
the Android Things
Console
, which provides the ability to support over-the-air updates (OTA) to
Android Things devices. We have recently made a number of UX improvements to the
console to improve usability and functionality. DP5 is now available within the
Android Things Console, but the DP5 update will not be pushed automatically to
devices without your intervention. You will need to update your application for
DP5, then create a new update and push it via the console yourself.


Feedback



With Android Things being updated to Android O, significant changes have been
made to the platform. Please send us your feedback by filing href="https://code.google.com/p/android/issues/entry?template=Android%20Things%20bug%20report">bug
reports and href="https://code.google.com/p/android/issues/entry?template=Android%20Things%20feature%20request">feature
requests, and asking any questions on href="http://stackoverflow.com/questions/tagged/android-things">Stack
Overflow. To start using DP5, use the href="https://partner.android.com/things/console">Android Things Console to
download system images and update existing devices. More information about the
changes are available in the href="https://developer.android.com/things/preview/releases.html">release
notes. You can also join Google's IoT
Developers Community
on Google+, a great resource to get updates and discuss
ideas. Also, we have our new hackster.io
community
, where everyone can share the amazing projects they have built!



Read more

7/25/17

Developer Preview 4 now available, official Android O coming soon!

Posted by Dave Burke, VP of Engineering





As we put the finishing touches on the Android O platform, today we're rolling
out Developer Preview 4 to help you make sure your apps are ready.



This is the final preview before we launch the official Android O platform to
consumers later
this summer
. Take this opportunity to wrap up your testing and publish your
updates soon, to give users a smooth transition to Android O.



If you have a device that's enrolled in the href="http://www.android.com/beta">Android Beta Program, you'll receive an
update to Developer Preview 4 in the next few days. If you haven't enrolled your
device yet, just visit the Android Beta
site
to enroll and get the update.



Watch for more information on the official Android O release soon!


What's in this update?



Developer Preview 4 is a release candidate build of Android O that you can use
to complete your development and testing in time for the upcoming official
release. It includes the final system behaviors, the latest bug fixes and
optimizations, and the final APIs (API level 26) already available since href="https://android-developers.googleblog.com/2017/06/android-o-apis-are-final-get-your-apps.html">Developer
Preview 3.



We're releasing the Developer Preview 4 device system images today, together
with the stable version of the Android 26.0.0 Support Library. Incremental
updates to the SDK, tools, and Android Emulator system images are on the way
over the next few days.



We're also introducing a new version of href="http://developers.android.com/testing">Android Testing Support Library
that includes new features like Android Test Orchestrator, Multiprocess
Espresso, and more. Watch for details coming soon.


Test your apps on Android O



Today's Developer Preview 4 system images give you an excellent way to test your
current apps on the near-final version of Android O. By testing now, you can
make sure your app offers the experience you want as users start to upgrade to
the official Android O platform.



Just enroll a supported device in the Android
Beta Program
to get today's update over-the-air, install your current app
from Google Play, and test the user flows. The app should run and look great,
and should handle the Android O href="https://developer.android.com/preview/behavior-changes.html">behavior
changes properly -- in particular, pay attention to href="https://developer.android.com/preview/behavior-changes.html#abll">background
location limits, href="https://developer.android.com/preview/features/notification-channels.html">notification
channels, and changes in href="https://developer.android.com/preview/behavior-changes.html#networking-all">networking,
href="https://developer.android.com/preview/behavior-changes.html#security-all">security,
and href="https://developer.android.com/preview/behavior-changes.html#privacy-all">identifiers.



Once you've resolved any issues, publish your app updates with the current
targeting level, so that they're available as users start to receive Android O.


Enhance your apps with Android O features and APIs



Users running the latest versions of Android are typically among the most active
in terms of downloading apps, consuming content, and making purchases. They're
also more vocal about support for the latest Android features in their favorite
apps. With Android O, users are anticipating features like href="https://developer.android.com/preview/features/notification-channels.html">notification
channels and href="https://developer.android.com/preview/features/notification-badges.html">dots,
href="https://developer.android.com/preview/features/pinning-shortcuts-widgets.html">shortcut
pinning, href="https://developer.android.com/preview/api-overview.html#opip">picture-in-picture,
href="https://developer.android.com/preview/features/autofill.html#optimizing_your_app_for_autofill">autofill,
and others. These features could also help increase engagement with your app as
more users upgrade to Android O over time.












With Android O your app can directly pin a specific app shortcut in the launcher
to drive engagement.


Notification dots keep users active in your app and let them jump directly the
app's core functions.



Enhancing your apps with Android O features can help you drive engagement with
users, offer new interactions, give them more control and security, and improve
performance. Features like href="https://developer.android.com/preview/features/adaptive-icons.html">adaptive
icons, href="https://developer.android.com/preview/features/downloadable-fonts.html">downloadable
fonts, and href="https://developer.android.com/preview/features/autosizing-textview.html">autosizing
TextView can simplify your development and minimize your APK size. Battery
is also a top concern for users, so they'll appreciate your app being optimized
for href="https://developer.android.com/preview/features/background.html">background
execution limits and other important href="https://developer.android.com/preview/behavior-changes.html#o-apps">changes
in vital system behavior for O apps.



Visit the O Developer
Preview site
to learn about all of the new features and APIs and how to
build them into your apps.


Speed your development with Android Studio



When you're ready to build for Android O, we recommend updating to the latest
version of href="https://android-developers.googleblog.com/2017/05/android-studio-3-0-canary1.html">Android
Studio 3.0, available for download from the href="https://developer.android.com/studio/preview/index.html">canary
channel. Aside from improved app href="https://developer.android.com/studio/preview/features/android-profiler.html">performance
profiling tools, support for the href="http://android-developers.googleblog.com/2017/05/android-announces-support-for-kotlin.html">Kotlin
programming language, and Gradle build optimizations, Android Studio 3.0
makes it easier to develop with href="https://android-developers.googleblog.com/2017/05/android-instant-apps-is-open-to-all.html">Instant
Apps, href="https://developer.android.com/preview/features/working-with-fonts.html">XML
Fonts, href="https://developer.android.com/preview/features/downloadable-fonts.html">Downloadable
Fonts, and href="https://developer.android.com/preview/features/adaptive-icons.html">Adaptive
Icons.



We also recommend updating to the stable version of the href="https://developer.android.com/topic/libraries/support-library/revisions.html?utm_campaign=android_launch_npreview_061516&utm_source=anddev&utm_medium=blog">Android
Support Library 26.0.0, available now from href="https://developer.android.com/studio/build/dependencies.html#google-maven">Google's
Maven repository, and to the latest SDK, tools, and emulator system images,
available over the next few days.



You can update your project's compileSdkVersion to API 26 to compile against the
official Android O APIs. We also recommend updating your app's targetSdkVersion
to API 26 to opt-in and test your app with Android O specific href="https://developer.android.com/preview/behavior-changes.html?utm_campaign=android_launch_npreview_061516&utm_source=anddev&utm_medium=blog">behavior
changes. See the href="https://developer.android.com/preview/migration.html#bfa">migration
guide for details on how to setup your environment to build with Android O.


Publish your updates to Google Play



Google Play is open for apps compiled against or targeting API 26. When you're
ready, you can publish your APK updates in your alpha, beta, or production
channels.



Make sure that your updated app runs well on Android O as well as older
versions. We recommend using href="https://developer.android.com/distribute/engage/beta.html?utm_campaign=android_launch_npreview_061516&utm_source=anddev&utm_medium=blog">Google
Play's beta testing feature to get early feedback from a small
group of users. Then do a staged rollout. We're looking forward to seeing your
app updates!


How to get Developer Preview 4



It's simple to get Developer Preview 4 if you haven't already! Just visit href="https://android.com/beta">android.com/beta and opt-in your eligible
phone or tablet. As always, you can also download and href="https://developer.android.com/preview/download.html?utm_campaign=android_launch_npreview_061516&utm_source=anddev&utm_medium=blog#flash">flash
this update manually. The O Developer Preview is available for Pixel, Pixel
XL, Pixel C, Nexus 5X, Nexus 6P, Nexus Player, and the Android Emulator.
Enrolled devices will automatically update when we release the official version
of Android O.



Thanks for all of your input throughout the preview. Continue to share your href="https://developer.android.com/preview/feedback.html">feedback and
requests, we love it!




Read more

6/28/17

Android Things Console developer preview

Posted by Wayne Piekarski,
Developer Advocate for IoT


Today we are launching a preview of the href="https://partner.android.com/things/console">Android Things Console.
This console allows developers to manage the software running on their fleet of
Android Things IoT devices, including creating factory images, as well as
updating the operating system and developer-provided APKs. Devices need to run a
system image downloaded via the Android Things Console in order to receive
future updates, such as the upcoming Developer Preview 5. Google provides all of
the infrastructure for over-the-air (OTA) updates, so developers can focus on
their specific application and not have to build their own implementation –
getting their IoT devices to enter the market faster and more securely than
before.



Let's take a tour of the console, and see the features it offers.


Product Creation and Product Settings



The developer first defines a product, which includes selecting a name and the
type of System-on-Module (SoM) that the device is based on. Many developers want
to use Google Play Services when building IoT devices, and this is configured
here as an optional feature. The size of the OEM partition is also configured,
and must be large enough to include the size of any future APK growth.





Factory Images



A device needs an initial base firmware to receive future updates for the
correct product from your console. For starters, you can simply use "Create
Build Configuration" to build a default factory image with an empty bundle that
is configured for your product. This factory image can then be downloaded and
flashed to your device, and you can start developing on it by sideloading an
APK.



Later on, once you have prepared an application that you would like to deploy to
all the devices in your product, you can upload a bundle to the console. This
bundle is a ZIP file that contains a main APK file, user space drivers as a
service in an APK, and any additional APKs launched by the main APK. A href="https://source.android.com/devices/tech/ota/device_code#boot-animation">bootanimation.zip
file is also supported, which will be displayed during boot up. The uploaded
bundle ZIP file is then used to produce a complete system image that can be
deployed to devices. More information about the bundle ZIP file contents is
available in the href="https://developer.android.com/things/console/app_bundle.html">documentation.





OTA Updates



This tab allows the developer to select which system image should be pushed to
the fleet of product devices. The developer selects one, and then "Push to
Devices" starts the process. The update will then be securely pushed to all of
the devices, installed to one of the A/B partitions, and made active when the
device is rebooted. If any failures are detected, the device automatically rolls
back to the previous known working version, so future updates are still
possible. Developers will be able to test new releases of Android Things in
advance and decide whether devices should be updated automatically.





Feedback



The Android Things Console is currently a preview, and we are working on many
more features and customizations. We encourage all Android Things developers to
check out the Android Things Console and provide feedback. You can do this by
filing href="https://code.google.com/p/android/issues/entry?template=Android%20Things%20bug%20report">bug
reports and href="https://code.google.com/p/android/issues/entry?template=Android%20Things%20feature%20request">feature
requests, and asking any questions on href="http://stackoverflow.com/questions/tagged/android-things">Stack
Overflow. To learn more about the Android Things Console, read the detailed
href="https://developer.android.com/things/console/index.html">documentation.
We also encourage everyone to join Google's IoT
Developers Community
on Google+, a great resource to get updates and discuss
ideas.



Read more

6/15/17

Android Things Developer Preview 4.1


Posted by Wayne Piekarski,
Developer Advocate for IoT



Today, we're releasing a new Developer Preview 4.1 (DP4.1) of href="https://developer.android.com/things/index.html">Android Things, with
updates for new supported hardware and bug fixes to the platform. Android Things
is Google's platform to enable Android Developers to create Internet of Things
(IoT) devices, and seamlessly scale from prototype to production.


New hardware



A new Pico i.MX6UL revision B board has been released, which supports many
common external peripherals from partners such as Adafruit and Pimoroni. There
were some prototype Pico i.MX6UL boards made available to some early beta
testers, and these are not compatible with DP4.1.


Improvements



DP4.1 also includes some performance improvements since DP4, such as boot time
optimizations that improve the startup time of i.MX7D based hardware. This
Developer Preview also includes a version of Google Play Services, specifically
optimized for IoT devices. This new IoT variant is a lot smaller and optimized
for use with Android Things, and requires the use of play-services 11.0.0 or
later in your build.gradle. For more information about the supported features in
the IoT variant of Google Play Services, see the href="http://developers.android.com/things/sdk/index.html#google-services">information
page.


Google I/O



Android Things had a large presence at Google I/O this year, with 7 talks
covering different aspects of Android Things for developers, and these are
available as videos in a href="https://www.youtube.com/playlist?list=PLOU2XLYxmsIIUtQeTRlRoDCdncUpWnR4M">playlist
for those who could not attend:







What’s New In Google’s IoT Platform? Ubiquitous Computing at Google







Bringing Device Production to Everyone With Android Things







From Prototype to Production Devices with Android Things







Developing for Android Things Using Android Studio







Security for IoT on Android Things







Using Google Cloud and TensorFlow on Android Things







Building for Enterprise IoT Using Android Things and Google Cloud Platform



Google I/O also had a codelab area, where attendees could sit down and test out
Android Things development with some simple guided training guides. These
codelabs are available for anyone to try at href="https://codelabs.developers.google.com/?cat=IoT">https://codelabs.developers.google.com/?cat=IoT


Feedback



Thank you to all the developers who submitted feedback for the previous
developer previews. Please continue sending us your feedback by filing href="https://code.google.com/p/android/issues/entry?template=Android%20Things%20bug%20report">bug
reports and href="https://code.google.com/p/android/issues/entry?template=Android%20Things%20feature%20request">feature
requests, and asking any questions on href="http://stackoverflow.com/questions/tagged/android-things">stackoverflow.
To download images for DP4.1, visit the Android Things href="https://developer.android.com/things/preview/download.html">download
page and find the changes in the href="https://developer.android.com/things/preview/releases.html">release
notes. You can also join Google's IoT
Developers Community
on Google+, a great resource to get updates and discuss
ideas, with over 5,600 members.





Read more

6/9/17

Android O APIs are final, get your apps ready!

Posted by Dave Burke, VP of Engineering


Three weeks ago at Google I/O, we href="https://android-developers.googleblog.com/2017/05/whats-new-in-android-o-developer.html">announced
the second developer preview of Android O along with key themes, Fluid
Experiences
and Vitals, and highlighted our work
towards a modular base with href="https://android-developers.googleblog.com/2017/05/here-comes-treble-modular-base-for.html">Project
Treble. It was also an important milestone for us with the release
of the first beta-quality candidate. We talked a lot about what's new in Android
during the keynote and breakout sessions—if you missed the livestream, be sure
to check out the full archive of talks href="https://www.youtube.com/user/androiddevelopers/playlists?sort=dd&view=50&shelf_id=14">here.



Today we're rolling out Developer Preview 3 with the final Android O APIs, the
latest system images, and an update to Android Studio to help you get ready for
the consumer release later in the summer. Watch for one more preview update
coming in July that will bring you the near-final system images.



If you've already enrolled your device in the href="http://android.com/beta">Android Beta Program, you'll receive an
update to Developer Preview 3 shortly.


Make your app compatible with Android O



With the consumer launch approaching href="https://developer.android.com/preview/migration.html">in the coming
months, a critical first step is making your current app compatible with
Android O. This will give your users a seamless transition to the new platform
as it arrives on their devices.



If you haven't tested your app for compatibility yet, getting started is
straightforward -- just enroll a supported device in Android Beta and get the
latest update over-the-air, then install your current app from Google Play and
test. The app should run and look great, and it should handle the Android O href="https://developer.android.com/preview/behavior-changes.html">behavior
changes properly -- in particular pay attention to href="https://developer.android.com/preview/behavior-changes.html#abll">background
limits and changes in href="https://developer.android.com/preview/behavior-changes.html#networking-all">networking,
href="https://developer.android.com/preview/behavior-changes.html#security-all">security,
and href="https://developer.android.com/preview/behavior-changes.html#privacy-all">identifiers.



After you've made any necessary updates, we recommend publishing the compatible
version of your app to Google Play right away -- without changing the app's
platform targeting.


Enhance your app with Android O features and APIs



Extending your apps with Android O features can help you drive more engagement,
offer new interactions, give users more control and security, and even improve
your app's performance.



href="https://developer.android.com/preview/features/notification-channels.html">Notification
channels and href="https://developer.android.com/preview/features/notification-badges.html">dots
give you more ways to surface new content to users and bring them back into your
app. Picture-in-picture keeps your app onscreen while users are multitasking,
and href="https://developer.android.com/preview/features/autofill.html#optimizing_your_app_for_autofill">autofill
makes it simple for them to enter forms data and helps keep their data secure.
Also check out href="https://developer.android.com/preview/features/adaptive-icons.html">adaptive
icons, href="https://developer.android.com/preview/features/fonts-in-xml.html">XML font
resources, href="https://developer.android.com/preview/features/downloadable-fonts.html">downloadable
fonts and href="https://developer.android.com/preview/features/emoji-compat.html">emoji,
href="https://developer.android.com/preview/features/autosizing-textview.html">autosizing
TextView,href="https://developer.android.com/ndk/guides/audio/aaudio/aaudio.html"> AAudio
API, and href="https://developer.android.com/preview/api-overview.html">many others.
You'll also want plan your support for href="https://developer.android.com/preview/features/background.html">background
execution limits and other important href="https://developer.android.com/preview/behavior-changes.html#o-apps">changes
in vital system behavior for O apps.



Visit the O Developer
Preview site
to learn about all of the new features and APIs and how to
build them into your apps.











Picture-in-Picture mode lets you keep users engaged while they are multitasking (left). Notification dots keep users active in your app and let them jump directly the app’s core functions (right).

Get started with Developer Preview 3



Today's preview update includes the latest version of the Android O platform
with the final API level 26 and hundreds of bugfixes and optimizations. You can
download the final API 26 SDK from the SDK Manager in href="https://developer.android.com/studio/index.html?utm_campaign=android_launch_npreview_061516&utm_source=anddev&utm_medium=blog">Android
Studio, and href="https://developer.android.com/topic/libraries/support-library/revisions.html?utm_campaign=android_launch_npreview_061516&utm_source=anddev&utm_medium=blog">Android
Support Library 26.0.0 beta 2 from href="https://developer.android.com/studio/build/dependencies.html#google-maven">Google's
Maven repository.



Together, these give you everything you need to develop and test your apps with
the official Android O APIs. Once you've installed the final SDK, you can update
your project's compileSdkVersion to API 26 to compile against the
official Android O APIs. We also recommend updating your app's
targetSdkVersion to API 26 to opt-in and test your app with Android
O specific href="https://developer.android.com/preview/behavior-changes.html?utm_campaign=android_launch_npreview_061516&utm_source=anddev&utm_medium=blog">behavior
changes. See the href="https://developer.android.com/preview/migration.html#bfa">migration
guide for details on how to set up your environment to build with Android O.



APIs have changed since the second developer preview, so if you have existing
code using Android O preview APIs, take a look at the href="https://developer.android.com/sdk/api_diff/26-incr/changes.html">diff
report to see where your code might be affected.



If you're developing for Android O, we recommend updating to the latest version
of href="https://android-developers.googleblog.com/2017/05/android-studio-3-0-canary1.html">Android
Studio 3.0, now available in the canary channel. Aside from great new
features like improved app performance profiling tools, support for the href="http://android-developers.googleblog.com/2017/05/android-announces-support-for-kotlin.html">Kotlin
programming language, and Gradle build optimizations, Android Studio 3.0
includes build support for href="https://android-developers.googleblog.com/2017/05/android-instant-apps-is-open-to-all.html">Instant
Apps, an href="https://developer.android.com/preview/features/adaptive-icons.html">Adaptive
Icon Wizard, and support for href="https://developer.android.com/preview/features/working-with-fonts.html">XML
Fonts, href="https://developer.android.com/preview/features/working-with-fonts.html">anhref="https://developer.android.com/preview/features/working-with-fonts.html">d
href="https://developer.android.com/preview/features/downloadable-fonts.html">Downloadable
Fonts.






Android Studio 3.0 includes tools for developing with Android O features lets you preview XML font resources in your app.


If you don't plan to use those features, you now have the option of developing
for Android O using href="https://developer.android.com/studio/index.html">Android Studio 2.3.3
from the stable channel. Note that the tools for working with adaptive icons and
downloadable fonts, and XML fonts are not available in Android Studio 2.3.3.


Publish your apps to alpha, beta or production channels in Google
Play



Now that the APIs are final, you can publish APK updates compiling with, and
optionally targeting, API 26 to your alpha, beta, or even production channels in
Google Play. Publishing your O-targeted app during the preview lets you test
compatibility on existing devices and push updates to devices running API 26 --
such as users who are enrolled in the Android Beta program.



To make sure that your updated app runs well on Android O as well as older
versions, a common strategy is to use href="https://developer.android.com/distribute/engage/beta.html?utm_campaign=android_launch_npreview_061516&utm_source=anddev&utm_medium=blog">Google
Play's beta testing feature to get early feedback from a small group of
users -- including developer preview users — and then do a staged rollout as you
release the updated app to all users.


How to get the preview update



Through the Android Beta program,
developers and early adopters worldwide will soon be getting Developer Preview 3
on their devices. If you aren't yet enrolled, just visit href="https://android.com/beta">android.com/beta and opt-in your eligible
Android phone or tablet. As always, you can also download and href="https://developer.android.com/preview/download.html?utm_campaign=android_launch_npreview_061516&utm_source=anddev&utm_medium=blog#flash">flash
this update manually. The O Developer Preview is available for Pixel, Pixel
XL, Pixel C, Nexus 5X, Nexus 6P, and Nexus Player.



Thanks so much for all of your feedback so far. Please continue to share href="https://developer.android.com/preview/feedback.html">feedback or
requests as we work towards the consumer release later this summer. We're
looking forward to seeing your apps on Android O!



Read more

5/18/17

What’s New in Android: O Developer Preview 2 & More

Posted by: Dave Burke, VP of Engineering


android-o-logo.png


With billions of Android devices around the world, Android has surpassed our wildest expectations. Today at Google I/O, we showcased a number of ways we’re pushing Android forward, with the O Release, new tools for developers to help create more performant apps, and an early preview of a project we call Android Go -- a new experience that we’re building for entry-level devices.


Fluid experiences in Android O

It's pretty incredible what you can do on mobile devices today, and how easy it is to rely on them as computers in our pockets. In the O release we've focused on creating fluid experiences that make Android even more powerful and easy to use, and today we highlighted some of those:
  • Picture-in-picture: lets users manage two tasks simultaneously, whether it’s video calling your friend while checking your calendar, or reading a new recipe while watching a video on a specific cooking technique. We’ve designed PIP to provide seamless multitasking on any size screen, and it’s easy for apps to support it.

  • Notification dots extend the reach of notifications, a new way for developers to surface activity in their app, driving engagement. Built on our unique and highly regarded notification system, dots work with zero effort for most apps - we even extract the color of the dot from your icon. 

  • Autofill with Google simplifies setting up a new device and synchronizing passwords by bringing Chrome's Autofill feature to Android. Once a user opts-in, Autofill will work out-of-the-box for most apps. Developers can optimize their apps for Autofill by providing hints about the type of data expected or add support in custom views. 

  • A new homescreen for Android TV makes it easy for users to find, preview, and watch content provided by apps. Apps can publish one or more channels, and users can control the channels that appear on the homescreen. You’ll be able to get started with creating channels using the new TvProvider support library APIs. 

  • Smart Text Selection: In Android O, we’re applying on-device machine learning to copy/paste, to let Android recognize entities like addresses, URLs, telephone numbers, and email addresses. This makes the copy/paste experience better by selecting the entire entity and surfacing the right apps to carry out an action based on the type of entity.

  • TensorFlow Lite: As Android continues to take advantage of machine learning to improve the user experience, we want our developer partners to be able to do the same. Today we shared an early look at TensorFlow Lite, an upcoming project based on TensorFlow, Google’s open source machine learning library. TensorFlow Lite is specifically designed to be fast and lightweight for embedded use cases. Since many on-device scenarios require real-time performance, we’re also working on a new Neural Network API that TensorFlow can take advantage of to accelerate computation. We plan to make both of these available to developers in a maintenance update to O later this year, so stay tuned!  

(L) Android O: Picture-in-picture, (R) Android O: Notification dots


Working on the Vitals in Android

We think Android’s foundations are critical, so we’re investing in Android Vitals, a project focused on optimizing battery life, startup time, graphic rendering time, and stability. Today we showcased some of the work we’ve done so far, and introduced new tools to help developers understand power, performance, and reliability issues in their apps:

  • System optimizations: in Android O, we’ve done a lot of work across the system to make apps run faster and smoother. For example we made extensive changes in our runtime - including new optimizations like concurrent compacting garbage collection, code locality, and more. 

  • Background limits: up to now it’s been fairly easy for apps to unintentionally overuse resources while they’re in the background, and this can adversely affect the performance of the system. So in O, we've introduced new limits on background location and wi-fi scans, and changes in the way apps run in the background. These boundaries prevent overuse -- they’re about increasing battery life and freeing up memory.

  • New Android Vitals Dashboards in the Play Console: today we launched six Play Console dashboards to help you pinpoint common issues in your apps - excessive crash rate, ANR rate, frozen frames, slow rendering, excessive wakeups, and stuck wake locks, including how many users are affected, with guidance on the best way to address the issues. You can visit the Play Console today to see your app's data, then learn how to address any issues.

Android Go

Part of Android’s mission is to bring computing to everyone. We’re excited about seeing more users come online for the first time as the price of entry level smart phones drop, and we want to help manufacturers continue to offer lower-cost devices that provide a great experience for these users. Today we gave a sneak peek of a new experience that we’re building specifically for Android devices that have 1GB or less of memory -- Internally we call it “Android Go,” and it’s designed around three things

  • OS: We’re optimizing Android O to run smoothly and efficiently on entry-level devices

  • Apps: We’re also designing Google apps to use less memory, storage space, and mobile data, including apps such as YouTube Go, Chrome, and Gboard. 

  • Play: On entry-level devices, Play store will promote a better user experience by highlighting apps that are specifically designed for these devices -- such as apps that use less memory, storage space, and mobile data -- while still giving users access to the entire app catalog.

The Android Go experience will ship in 2018 for all Android devices that have 1GB or less of memory. We recommend getting your apps ready for these devices soon -- take a look at the Building for Billions to learn about the importance of offering a useful offline state, reducing APK size, and minimizing battery and memory use.



O Developer Preview 2, Now in Public Beta

Today’s release of O Developer Preview 2 is our first beta-quality candidate, available to test on your primary phone or tablet. We’re inviting those who want to try the beta release of Android O to enroll now at android.com/beta -- it’s an incredibly convenient way to preview Android O on your Nexus 5X, 6P, and Player, as well as Pixel, Pixel XL, or Pixel C device.



With more users starting to get Android O on their devices through the Android Beta program, now is the time to test your apps for compatibility, resolve any issues, and publish an update as soon as possible. See the migration guide for steps and a recommended timeline.



Later today you’ll be able to download the updated tools for developing on Android O, including the latest canaries of Android Studio, SDK, and tools, Android O system images, and emulators. Along with those, you’ll be able to download support library 26.0.0 beta and other libraries from our new Maven repo. The change to Maven from SDK Manager means a slight change to your build configuration, but gives you much more flexibility in how you integrate library updates with your CI systems.



When you’re ready to get started developing with Android O, visit the O Developer Preview site for details on all of the features you can use in your apps, including notification channels and dots, picture-in-picture, autofill, and others. APIs have changed since the first developer preview, so take a look at the diff report to see where your code might be affected.



Thanks for the feedback you’ve given us so far. Please keep it coming, about Android O features, APIs, issues, or requests -- see the Feedback and Bugs page for details on where to report feedback.
Read more
loading...