Seems to be the library to switch to as it supports the RPi5 https://gpiozero.readthedocs.io/en/stable/index.html#
All posts by
RPi.GPIO no longer working from RPi5
RPi.GPIO no longer works due to the change to the new RP1 southbridge chip. Full explanation here. GPIO Zero offers a good migration guide here.
Using the SPI Interface
Enabling The SPI Port The SPI port needs to be enabled in Raspberry Pi OS before it can be used. See here. Test the SPI Port Test the SPI port is working on the command line by typing: You should see the following: There are 2 spidev devices shown (or more on newer Pi’s). The first […]
Running virtual environment at boot
See here For more info see here
Creating a virtual environment for python programs
Raspberry Pi OS manages Python packages a bit differently to some Linux installs and will insist on using a virtual environment (e.g. you get an error: “error: externally-managed-environment”) Creating a virtual environment is good practice anyway for Python development in general, as it helps to manage dependencies and avoid conflicts. Update system and ensure virtualenv […]
Install Docker
Installing Update all packages: Push this below installation script: Run the script with the help of the below command: Letting non-admin users run docker images See here
Raspberry Pi Connect
Included free with the RPi, gives you remote control via a browser. https://www.raspberrypi.com/software/connect The icon for it is in the top bar next to the WiFi and Bluetooth icon.If you don’t see it, go to Start > Preferences > Raspberry Pi Coniguration > Interfaces > Ensure Raspberry Pi Connect is turned on. You can see […]
Auto Running The GUI as root
You can use the raspbian preferences via the GUI to cause the pi user to be auto logged in at boot up and the GUI automatically run. However if you need to run with root privileges due to needing IO pin control (yes yes its not advised to run as root, but for many uses its fine where […]
Assign fixed port name to a USB device
For example, to always refer to the same USB to serial adapter by the same port name, when you have more than one connected. This guide is based on the excellent guide here. 1 – Get a list of your USB devices Example result: 2 – Get specific attributes for the device For our example […]
UART commands and config
List serial ports GPIO serial port is /dev/ttyAMA0 USB when added usually has a USB in its name, e.g. /dev/ttyUSB0 List just USB serial ports List all ports Assigning a fixed name to a USB serial port https://www.freva.com/assign-fixed-usb-port-names-to-your-raspberry-pi/