Skip to content

Instantly share code, notes, and snippets.

@dotspencer
Created August 22, 2022 06:14
Show Gist options
  • Save dotspencer/5145bf77d41ec2ae3eb94f9b1f1c4576 to your computer and use it in GitHub Desktop.
Save dotspencer/5145bf77d41ec2ae3eb94f9b1f1c4576 to your computer and use it in GitHub Desktop.
Raspberry PI tips

Node.js install

I usually use nvm to manage node.js versions for projects, but there are not official binaries for the ARM V6 chip in a Raspberry Pi Zero for node versions 12 and higher. The source is still available, and so if you try nvm install 14.17.4 nvm will attempt to compile from source, which on a Raspberry Pi zero will take a long, long, long time (and probably fail).

Fortunately node.js provides "unofficial builds" of newer node versions for ARM v6 at unofficial-builds.nodejs.org.

You can use these binaries with nvm by providing a url to use instead of the default node.js binaries url:

nodejs 14

NVM_NODEJS_ORG_MIRROR=https://unofficial-builds.nodejs.org/download/release nvm install 14

nodejs 16

NVM_NODEJS_ORG_MIRROR=https://unofficial-builds.nodejs.org/download/release nvm install 16

Flashing Image

https://www.raspberrypi.com/software/

This will allow you to flash a headless raspberry pi OS image and configure wifi and ssh in the gui. Easier than manuallly setting everything up after using Etcher.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment