

Remote desktops solutions usually render blurry fonts and feel unresponsive over slow connections. This is the killer advantage over more generic remote desktop solutions like VNC, which stream pixels directly. Input is also very responsive, because the protocol is specialized, and therefore optimized. The beauty of this approach is that even with a slow connection, it renders crisp, pixel-perfect fonts and UI, because it understands the underlying software, so it can render fonts in vector format. The web client records keyboard and mouse input, and sends it back to the IDE via AWT. The web client interprets those drawing commands and renders them in a web page.

It intercepts drawing commands from the IDE (or any Swing application) with a custom drawing engine ( AWT implementation) that instead of rendering things on screen, records each command, serializes them and sends them to a web client. The idea behind Projector is simple but rather brilliant. When I want to work on my projects, I just start my EC2 instance, run Projector on it, then open a Chrome tab and I’m ready to code. Not bad considering I don’t need an expensive laptop anymore. Even if I used it for 8 hours a day, 5 days a week, it would cost me around $64 / month.

Running the instance costs me around $0.40 / hour, not cheap if you’re running it 24/7, but since I use it only for a few hours a week for my personal projects, it ends up being quite affordable. I went with AWS, chose an EC2 instance with 8 cores, 32Gb of RAM and 100 Gb of storage. Luckily cloud VMs are now a commodity, and you can get one up and running in a matter of minutes via services like Amazon AWS, Google Cloud or Microsoft Azure. You still need a beefy machine either in the cloud on on your local network to do the actual heavy lifting of running the IDE and Gradle builds. Where is Android Studio actually running? My personal favorite so far is the Pixelbook Go, great keyboard and super lightweight, been really enjoying coding from it.

I even considered an iPad as an alternative, it works, but definitely not as comfortable as a real laptop. Without the constraints of a beefy hardware, I can choose a development machine that is portable, lightweight, and much cheaper! A good choice in my opinion is a decent Chromebook, a MacBook Air, or a Surface Go. If it has a browser, you can use it to code. Of course you would never code on a phone, but it proves that the device hardware is irrelevant. Remote Android Studio accessed from a Pixel 4’s browser
