This script assumes:
- that the newest Raspberry Pi OS is installed
- the user running it is pib
All the software pib requires can be installed by running our setup script. Follow these steps to run it:
-
Open a terminal in Raspberry Pi OS
-
Insert the following command into the terminal to download the script:
wget https://raw.githubusercontent.com/pib-rocks/pib-backend/main/setup/setup-pib.sh(or download it manually: https://github.com/pib-rocks/pib-backend/blob/main/setup/setup-pib.sh)
-
Insert this command to run the script:
bash setup-pib.shIf you want to run the setup-script in legacy mode (for Raspberry Pi 4), insert:
bash setup-pib.sh -l
The setup then adds Cerebra and it's dependencies, including ROS2, Tinkerforge,... Once the installation is complete, please restart the system to apply all the changes.
This script assumes that the setup script was executed successfully
- Open a terminal
- Enter this command:
update-pib
This script will update your docker containers (Front- and Backend)
Starting the webots simulation:
- Complete all steps of the "Installing pibs software"-section of this readme document
- Webots GUI is intended to run natively on the host Wayland session (not inside Docker).
- Install Webots on the host OS and then run the simulator launch on the host:
ros2 launch pibsim_webots pib_launch.py
- Ensure ROS networking between host and Docker works (same
ROS_DOMAIN_ID, multicast not blocked).
Webots may throw error messages saying it crashed (especially on VM). This can usually be ignored by clicking on "wait".
To synchronize communication between pibs on default ROS_DOMAIN_ID=0:
- Open a Terminal:
- Run the following command:
gedit ~/.bashrc
OR for users connected through terminal:
vim ~/.bashrc - Within .bashrc
delete: export ROS_LOCALHOST_ONLY=1
or replace it with: ROS_LOCALHOST_ONLY=0 - Restart pib
To add pib to a distinct logical network:
- Open a Terminal
- Run the following command:
gedit ~/.bashrc
OR for users connected through terminal:
vim ~/.bashrc - Delete: "export ROS_LOCALHOST_ONLY=1"
- Append: "export ROS_DOMAIN_ID=YOUR_DOMAIN_ID"
- Restart pib
For a range of available ROS_DOMAIN_IDs please check the official documentation at:
https://docs.ros.org/en/dashing/Concepts/About-Domain-ID.html
The backend can be started via docker compose. Since the software requires to interface with the OS hardware (USB,
sound and GPIO) Docker for Windows and Mac is not supported.
Running docker compose up will start the Flask API, rosbridge and the blockly node server. To run the full backend,
including camera, motors, programs and the voice assistant, profiles can be used:
docker compose --profile all uppassword.env required to run the voice assistant:
TRYB_URL_PREFIX=<BASE_URL_Tryb>
For the development process, external developers are requested to refer to the following explanation: https://pib-rocks.atlassian.net/wiki/spaces/kb/pages/435486721/Contributing+to+pib
This branch integrates custom features previously maintained in a separate repository:
- Vendored
pib-blocklysources with button, audio, object detection, and display blocks ros_packages/button_servicefor TinkerForge RGB button control- Facial expressions and display text support in the ROS display service
- Face tracking and vision prompt integration in the camera stack
Cerebra UI updates may be required for new Blockly block categories to appear in the editor.