Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save cmpscabral/05ec6436e4590fa8e74956c016e97139 to your computer and use it in GitHub Desktop.
Save cmpscabral/05ec6436e4590fa8e74956c016e97139 to your computer and use it in GitHub Desktop.
Adding PIXEL to Raspbian Lite

Adding PIXEL/GUI to Raspbian Lite

These 'notes' were primarily intended for my own consumption but since there have been surprisingly many comments to it over the years I wanted to do some updates and clarifications. Thanks for all comments.

These instructions will require you to have connection to internet from your pi, WiFi, Ethernet or by some other means like a 3G USB dongle or something.

Preparations

Download and flash Raspbian Lite as normal. Run raspi-config and setup whatever you would to for console only mode. I usually change password, hostname and activate SSH server as a initial setup.

Adding wifi from console (optional)

This can be done in at least 2 ways and I would recommend using raspi-config but you could also...

Edit wpa_supplicant manually

sudo nano /etc/wpa_supplicant/wpa_supplicant.conf Add the bottom of the file

network={
  ssid="YOUR_SSID"
  psk="YOUR_PASSWORD"
}

Save and reboot

Touchscreen

If you have any other that the original Raspberry Pi touchscreen you might have to install the correct drivers.

Rotate Touchscreen (optional)

These instructions are for the original Raspberry Pi touchscreen and if you have to change it's rotation, wich you might have to do depending on the case you mount it in.

  • Edit /boot/config.txt on the newly flashed card and add the line lcd_rotate=2 at a location of your choice in the file.
  • Save and reboot

Run all updates

Reduces that anything goes wrong int the following steps

sudo apt update
sudo apt upgrade

# you only have to reboot if there were any updates that needed it
# if unsure do it anyway
sudo reboot

Adding GUI

This will get you a really stripped down PIXEL installation Tested on Jessi and Stretch

sudo apt-get install -y raspberrypi-ui-mods rpi-chromium-mods
sudo reboot

This will pull in all packages needed for GUI + rpi modified Chromium web browser and is all you need for a "basic" setup. It will take some time though. The download will go fast but decompressing and installing is tough even on a Rpi 3.

I will do some tests but you might have to install lightdm manually using sudo apt-get install lightdm as well. It should be a part of the installation of raspberry-ui-mods though.

There might be some issues with icons being installed for programs that isn't installed and when new programs not showing up in the menu. This is probably due to some missing package that I yet have to figure out which one.

Enable autologin (optional)

If you want autologin you have to run raspi-config again and select "Boot option"->"Desktop / CLI"->"Desktop autologin"

Xinit (optional)

If you do not want autologin but want to be able to start the gui manually sudo apt-get install --no-install-recommends xinit so that you can boot to the console start the desktop as required using the command startx.

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