As you may know, a Chromebook (or better: Chrome OS) has the ability to run Linux programs. In fact, this is still an ongoing beta test, but more and more functionality is slowly being added. Recently, USB devices are also recognized. What do you need to know about this?
One of the shortcomings in the Linux virtual machine under Chrome OS was that USB hardware was inaccessible. We have already made quite a few updates to Google’s operating system intended for Chromebooks. And luckily it is now possible! If you’re running the most recent version of Chrome OS, it’s pretty simple.
First of all it is (of course) important to activate the Linux virtual machine (vm), by default this option is off. That’s why you start Settings (click somewhere in the clock field at the bottom right of the screen and then on the gear in the unfolded panel). In the window that opens on the left, click Advanced and then on developers. You can now turn on Linux with the appropriate button on the right.
Simply follow the instructions, some things have to be downloaded, but after a maximum of ten minutes everything should be in order. You now have a complete Linux vm, which you can start via the app panel (ball on the far left of the dock) and then click on ^ in the opened panel. You will find the Linux apps app group somewhere among the installed apps.
Manage USB Devices
Suppose you want to use a USB device under Linux, you can now do that. Not everything is supported, just a matter of trying it out. In our case we plugged in a USB-to-serial converter. These things are widely used, for example, for programming and communicating with microcontrollers.
To check if this device can be made available for Linux, tap it. Then open the aforementioned Chrome OS again Settings and click (left) again Advanced, followed by a click on developers. Then click on the right Linux development environment and then on Manage USB devices.
In our case, the converter appears in the list, you activate it by turning on the switch behind the device. Please note: this promotion is unfortunately not (yet?) remembered. Which means every time you enter the Linux environment (or any app running under it), you have to re-authorize your USB device(s).
Turn on the switch behind your USB device to grant it access. From that moment on you can use the thing in combination with Linux. As can be seen, we can access a device connected to the converter via a serial terminal program. In short: mission accomplished!
About Terminal
Under Android – also part of the Chromebook – various terminal apps are available, but at the time of writing we have not yet got one to work. Occasionally, the USB converter is recognized, but the required transfer rate (baud rate) cannot be set correctly.
In all other cases, the converter is not recognized at all. Just maybe you’ll be lucky with a different copy than what we have here. However, don’t count on it.
It is not really necessary, because Chrome OS has the possibility to run a terminal program in the Chrome browser! And, if desired, you can also install it as a web app. Most famous is Beagle Term. This is a simple web app, don’t expect extreme miracles in terms of features. But it works.
Other solutions
However, if you want to get more serious with a serial terminal connection, the Linux virtual machine in Chrome OS is the most obvious way. The web app is perfectly usable to quickly check something, for example. But because things like terminal emulation and the like are missing, you won’t see any color, for example; everything is monochrome.
Again: fine for quick work, but not if you really want to communicate with a peripheral that supports slightly more advanced options.
You are also dependent on your Chromebook for programming microcontrollers via a serial dongle Linux. For the rest, other solutions are available for other USB hardware.
You might want to try a USB-DAC (aka digital-to-analog converter for sound), or any other USB device you have lying around. If it doesn’t work under Chrome OS itself, you might get it running under the Linux vm – combined with the right software!
You open a ‘bare’ Linux terminal session by starting the Terminal app. Linux fanatics can then do their thing. Fortunately, for the lesser ‘terminal knights’ there is also a Linux app store (with mainly free open source software in it) available. For that you start the app Software.
The nice thing is that all this software uses the Chrome OS desktop. In other words: if you install, for example, photo editor GIMP from this app store, then it integrates completely with Chrome OS in terms of appearance. Be careful though: Linux apps can take up a lot of storage space. Many Chromebooks still come with modest SSDs, so if you have a machine with 32GB of storage, it’s a matter of weighing what you really want and what’s less important.
Don’t forget to check every now and then what Linux programs are ‘left behind’ after trying them out once. Removing unnecessary software can suddenly free up a lot of disk space!
Linux on demand
Let’s talk about that Linux environment in your Chromebook. In fact, it works ‘unnoticed’ in the background. It only starts up when prompted. In other words: when you start a Linux program, think of, for example, the aforementioned Terminal or another piece of software installed via the Linux store.
This method means that the first time you start an app under Linux, it can take a while. After all: not only the program has to be started, but first the entire Linux environment has to be booted. On a slower Chromebook this can take a while, on a faster version you’re done in a few seconds. Once the Linux VM has started, Linux programs start much faster afterwards. Wherever you turn off your Chromebook (actually turn it off, so don’t close the lid to put it to sleep) and log in again, the Linux vm won’t start automatically.
In short: the game then starts again and starting the first app under Linux takes some extra time. No drama, but you just have to know so as not to get the impression that something goes wrong and your app or Linux does not start. Just wait a little while and you’ll be fine!
.