Google I/O 2011: Android Open Accessories and ADK

Google I/O 2011: Android Open Accessories and ADK

Summary: The new Android Open Accessories API will allow Android apps to communcate with real world devices such as keyboards, mice (including scroll wheel and hover), game controllers, robots, and more. A demo from Android 3.

SHARE:
TOPICS: Hardware, Android, Google
0

The new Android Open Accessories API will allow Android apps to communcate with real world devices such as keyboards, mice (including scroll wheel and hover), game controllers, robots, and more. A demo from Android 3.1 showed an Asteroids game played with an XBox controller. Another showed a USB controlled Nerf blaster.

USB has two modes - host mode and accessory mode. In host mode the phone acts like a computer that can charge devices and handle multiple devices. Unfortunately it's not supported yet by many phones and tablets. Accessory mode is supported by all phones, and lets the device you plug into the phone act as the host. On the phone you run an app that uses the Android Open Accessories API. Source code, hardware plans, etc. are available now at accessories.android.com.

There are two different APIs: one for Android 3.1 and a compatability library for Android 2.3. Apps see that an Intent is sent when hardware is attached and detached. Once a connection is established you just do reads and writes over stream I/O.

To encourage development, Google gave an ADK to everyone in the room. It includes two servos and all the needed cables.

For more details see the live notes.

Topics: Hardware, Android, Google

Ed Burnette

About Ed Burnette

Ed Burnette is a software industry veteran with more than 25 years of experience as a programmer, author, and speaker. He has written numerous technical articles and books, most recently "Hello, Android: Introducing Google's Mobile Development Platform" from the Pragmatic Programmers.

Kick off your day with ZDNet's daily email newsletter. It's the freshest tech news and opinion, served hot. Get it.

Talkback

0 comments
Log in or register to start the discussion