Unfortunately, I send in my beloved Macbook Pro Late 2016 to Apple to fix their 1st generation butterfly keyboard that is broken by design. So I am left with my peripherals and an unused Raspberry Pi 3 Model B with 1 GB RAM* (I still had laying around). Luckily, I have a lot of work for the coming week that can not be delayed. So without spending any money or borrowing a device from my girlfriend, friends or family my only option is to get a minimal temporary desktop environment running on my Raspberry Pi. All I had to do to get started was to grab the 64 GB micro sd card from my old Samsung Galaxy and get a power supply as well as a housing (Aukru 3 in 1 Kit + Power Supply*).
TL;DR
Don't do it – setup is a bit complicated, you can't use the software you are used to, it's way too slow and you will have to do most of your work in terminal
The workflow
We are going through the following problems in this post:
- Problem 1 – Raspberry Pi won't boot from 64 GB or 128 GB sd card because of exFat
- Problem 2 – Make Raspberry Pi support 21:9 ultrawide resolutions
- Problem 3 – Install latest nodejs 12 or 14 on raspbian
- Problem 4 – Install latest neovim on raspbian (0.4.4)
- Problem 5 – Setting up my development environment: VSCode, Neovim, ...
- Problem 6 – Overall performance
- Conclusion
Problem 1 – Raspberry Pi won't boot from 64 GB or 128 GB sd card because of exFat
The micro sd card used in the Raspberry Pi must be fat32 formatted. The problem here is that cards with more than 32 GB of memory (64 GB, 128 GB, 256 GB) won't work correctly with fat32. That is why they are formatted exFat by default.
- If you have a micro-sd card with at least 64 GB you must reformat it to fat32 by following the steps written here.
- Goto the Raspberry Pi Download Page and either download noobs or the Raspberry Pi imager.
- If you downloaded noobs just extract its contents into the root of your sd card.
If you installed the Raspberry Pi imager, run it and install Raspbian on your sd card.
Problem 2 – Make Raspberry Pi support 21:9 ultrawide resolutions
By default, the Raspberry Pi will only support standard resolutions like 1920x1080 or 1280x720 px. In order to use the small machine with a 21:9 monitor, we must define a custom resolution. The following works on my LG Ultrawide 21:9 with 3440x1440 px.
- First of all open
/boot/config.txt
in your favorite editor with root privileges. (For vim it would be:sudo vim /boot/config.txt
) - You will then need to add or replace the following config values. If you don't know what you are doing or what I mean, stop right here
- Restart (
sudo reboot
) and your Raspberry Pi will output 1920x820 px filling your 21:9 monitor. You can also try using 2560x1080px but my Raspberry was terribly slow and crashed after a few minutes so I reduced the resolution. - The config for 2560x1080p @ 60 Hz looks like:
- You can also try reducing the refresh rate by editing the
hdmi_cvt
value (here reduced from 60 Hz to 30 Hz in comparison with the last code snipped):
Problem 3 – Install latest Node.js 12 or 14 on Raspbian
I wanted to use a correctly working Node.js 12 or 14 instead of the broken v10 that the package manager installs. Fortunately, prebuilt binaries for arm-architecture are available via node source. In order to install, for example, version 12, just execute:
Problem 4 – Install latest neovim on Raspbian (0.4.4)
Even though neovim
is available from the official package manager but you will end up with a very old version ( 0.3.x
). If you want to use the latest version cocvim
for instance, you must build neovim
from source (like in the good ol' days):
Building neovim from source on Raspbian
- Install the build dependencies by opening a terminal and executing:
- Grab the source (https://github.com/neovim/neovim/releases) by downloading the source for the latest stable version of
neovim
and extract it. Alternatively, you can clone the repo via git and checkout the stable branch. - Build and install
neovim
by executing:
- If you type
neovim --version
you should seeneovim
printing the installed version. If the displayed version does not match with the one you built, you likely installedneovim
with the package manager before. To fix it just runsudo apt-get remove neovim
.
Problem 5 – Setting up my development environment: VSCode, neovim, ...
Installing Visual Studio Code on Raspbian
My development environment usually includes Visual Studio Code when doing web development (node, react, ...).
Unfortunately, Raspbian is not supported by Visual Studio Code and there is no official build that works. There is however an unofficial fork that works on Raspbian. It can be installed by executing the following commands.
wget https://code.headmelted.com/installers/apt.sh
chmod u+x ./apt.sh
sudo ./apt.sh
You will then find the entry Code - OSS (headmelted)
in your applications (Raspberry GUI in the top left corner -> Programming).
It works fairly well but if you install the wrong plugins Code will take too much RAM and require more CPU power than your Pi has to offer. This is the reason why I temporarily ditched VS Code in favor of neovim.
Setting up Raspberry Pi for development with neovim
After successfully installing the latest neovim
version as described before in section Problem 4 configuring it was no problem at all.
- Start by installing a plugin manager like vim-plug:
- Configure
neovim
like you normally would
- If you want to set up
neovim
for web development with highlighting, suggestions, etc. there is a great tutorial over here.
Problem 6 – Overall performance
It's bad but it is definitely not unusable if you stick to the basics:
- Don't open too many applications
- Don't open too many tabs in your browser
- Keep your resolution low (< 1080 px)
- Use native, performant applications (electron, I am talking to you)
- Use the terminal if you can (
neovim
, ...) - Use web apps for software you can't replace (e.g. SharePoint, ...)
If you want to do more than working with static content or must use complex software packages your Raspberry Pi will be too slow. Video calls (Skype, Zoom, ...) will not work. If you need more power, try using a bigger model like the new Raspberry Pi 4 with 8 GB RAM*.
Conclusion
Since I am comfortable messing around with configs and fixing things, getting it to work was not that hard for me. Nevertheless, I think it's far from "it just works" and I can't recommend using a Raspberry Pi as your daily driver:
- It's way too slow
- You can't use the software you are used to
- You must close parts of your open work while working cause your running out of RAM
- You can't operate your Pi at more than 1080p
- You can't do video calls with your team
FYI: I wrote this whole article on my Raspberry Pi.
Raspberry Pi is a trademark of the Raspberry Pi Foundation