Google’s Fuchsia team has started a new effort that allows Fuchsia devices to be managed with the ADB tool just like an Android phone.
On Android, developers and enthusiasts today can access some of the core components of their phones and tablets from their PC using ADB. Short for “Android Debug Bridge”, ADB is a crucial tool that, as the name suggests, is capable of “bridge” your two devices together.
Developers will use ADB to remotely install the latest work-in-progress version of their app on a physical device or even an Android emulator. Even if they never use ADB commands directly, developers benefit from ADB being deeply integrated into other tools like Android Studio.
Meanwhile, Android enthusiasts and power users alike use ADB to access their phone’s command prompt, perhaps enabling a community-discovered mod. You can also use ADB to access the real-time logs from your phone, diagnose problems, or just learn about its inner workings.
More importantly, ADB can run consistently well on any major desktop platform — Windows, macOS, and Linux (and by extension, ChromeOS) — and that’s an aspect of great importance to Google’s Fuchsia team.
This week, the Fuchsia team shared a new proposal titled “ADB on Fuchsia” that shares the team’s intent to support ADB for controlling devices and the rationale for wanting to do so.
At the moment, the core tools “fx” and “ffx” used to control Fuchsia devices are only compatible with Linux and macOS computers. And while efforts are underway to get ffx running on Windows, that isn’t expected to be completed until late 2022.
Moreover, even when ffx is supported on all platforms, Fuchsia with ADB support would continue to be useful for the foreseeable future as ADB is a ubiquitous tool. Over the years, ADB has been integrated into many different workflows and automation tools, many of which can immediately start supporting Fuchsia devices with no changes required.
So what would it look like for Fuchsia to support connection over ADB? One thing that is important to note is that this does not mean you can connect your favorite Fuchsia device, such as your Nest Hub or Nest Hub Max, to your computer via USB. Google has explicitly noted that Fuchsia’s version of ADB “will not be available in user or production versions,” a decision made for security reasons.
Instead, ADB on Fuchsia is only meant to work with devices while they’re still early in development, allowing some of those early stages of development and testing — Google cites “bring-up, engineering, and so on” — from Windows devices. .
Another notable limitation is that the Fuchsia team currently only plans to support “only a subset” of what ADB can do. Specifically, there are only plans for four specific ADB commands:
- adb shell
- adb log cat
- adb push
- adb pull
As we mentioned earlier, ADB’s “shell” command is used to access the internal command prompt of a (normal Android) device. When used with a Fuchsia device, you could run the same commands you would normally use via an ffx shell or connecting to the device via SSH. Next up is “logcat”, which, like on Android, would be able to run all logs from a Fuchsia device.
The more interesting ADB commands are “push” and “pull”, which are used for sending and retrieving files between your two devices. The proposal doesn’t share exactly how this would work on a Fuchsia device, but it would certainly come in handy during testing.
Internally, all of these ADB commands are effectively routed to their Fuchsia equivalent, as illustrated somewhat in an attached image. In that sense, this support for ADB really just acts as a compatibility layer.
Overall, it’s intriguing to see how Google connects their various projects in direct, if subtle, ways. While it’s unlikely that most of us will need to connect to a Fuchsia device via ADB in the near future, the addition is still quite interesting.
In some ways, ADB support for Fuchsia is also talking to Google about making Fuchsia-first device development easier for the company’s partners—or really anyone who wants to make a device powered by Fuchsia—using the tools they probably want. already have.
More about fuchsia:
FTC: We use auto affiliate links that generate revenue. More.
Check out 9to5Google on YouTube for more news: