-
Notifications
You must be signed in to change notification settings - Fork 0
Instructions for the Raspberry Pi Zero 2 WH configuration
For installing the OS, I used the Raspberry Pi Imager with an 16GB SD card. I then took the Ubuntu Server 24.04.1 (64-bit) OS. I don't forget to enable ssh options while editing the configuration.
https://www.raspberrypi.com/software/
Since I used the Raspberry Pi without screen (headless), I connect to the pi using ssh via the following command:
ssh user@192.168.xxx.xxxWhere 'user' is the username specified in the Raspberry Pi Imager configuration, and '@192.168.xxx.xxx' is the IP adress of the pi.
More infos: https://pimylifeup.com/raspberry-pi-ip-address/
Once connected to the Raspberry Pi, I upgraded the packages:
sudo apt update && sudo apt upgradeAs Ubuntu does not have raspi-config natively, I have to install it manually:
sudo apt-get install raspi-configThis allows me access to the Raspberry's configurations:
sudo raspi-config
Here are the parameters I modified/enabled:
- Interface options > Legacy camera
- Interface options > SPI
- Interface options > I2C
- Interface options > Serial Port
- Interface options > Remote GPIO
- Performance options > GPU Memory > 128 MB
Don't forget to reboot the pi after editing:
sudo rebootTo run my python codes I installed pip:
sudo apt-get install python3-pipI then installed zram-tools for reducing swap:
sudo apt install zram-toolsYou can check that zram-tools is well installed with this command:
zramctlClone the repository with git:
git clone https://github.com/Mowibox/Chromapi.gitEnter the folder:
cd ChromapiAnd install the required python packages:
pip install -r requirements.txtI wrote simple tests inside on 'Chromapi/tests' folder to see that everything is working.
Legs and LEDs test:
python3 test_1.py
Ultrasonic sensor test:
python3 test_2.py
Look at the Troubleshooting page if you encounter any issues!