Useful Ubuntu Utilities for Raspberry Pi4

Many software packages that are standard on the Raspberry Pi OS must be manually installed on Ubuntu 20.10 or 20.04.1 LTS Server. This guide lists various useful utilities.

Table of Contents

    Install raspi-config

    1. Navigate to raspi-config on archive.raspberrypi.org. Pick the latest .deb version. At time of writing the latest file is raspi-config_20201108_all.deb.
    2. Download that file to /tmp
      wget https://archive.raspberrypi.org/debian/pool/main/r/raspi-config/raspi-config_20201108_all.deb -P /tmp
    3. Install
      sudo dpkg -i /tmp/raspi-config_20201108_all.deb
    4. reboot

    Install userland vcgencmd tools

    1. install vcgencmd
      sudo apt install libraspberrypi-bin
    2. add user to video group. If you don’t do this you will get “VCHI initialization failed” error. Replace username below with the current user.
      sudo usermod -aG video <username>
    3. reboot

    Clean the APT Cache to free up space on SD card.

    Find out how large the apt cache is
    du -sh /var/cache/apt/archives
    Clean apt cache
    sudo apt-get clean

    Configure WiFi with headless operation

    1. While the SDcard is connected to your PC open the network.config file on the system-boot partion.
    2. Edit the file to add your Wi-Fi credentials. Remove the # to uncomment the configuration.
    wifis:
      wlan0:
      dhcp4: true
      optional: true
      access-points:
        <wifi network name>:
          password: "<wifi password>"

    Read CPU temperature

    Divide the result by 1000 to find the value in degrees Celsius.
    cat /sys/class/thermal/thermal_zone0/temp

    Read GPU temperature

    Call the vcgencmd utility
    vcgencmd measure_temp