This repository contains the default code for all boards in the CANEDUDEV Rover.
Board applications utilize FreeRTOS.
This project is built using Meson with the Ninja backend.
Supported OS: Ubuntu 24.04. If you're using Windows, you can utilize the Ubuntu 24.04 WSL distribution.
- Run
./scripts/bootstrap.sh
to set up the build environment. This step installs all dependencies and prepares the build folder. - Execute
meson compile -C build
to initiate the build process. - The build output can be found in the
build
folder.
There is a ROS gateway available which exposes the Rover's CAN messages as ROS topics, and allows the user to control the Rover via ROS. The gateway is deployed as a docker container and available as part of this repository's Github packages.
The gateway can be built locally using meson compile -C build ros-gateway
.
To build the documentation, run meson compile -C build docs
. The HTML output is located in the build/docs/html
folder.
Generate a zip file containing the board binaries by running meson compile -C build release
. The output is stored in the build
folder.
To run all unit tests, execute meson test -C build
.
Additionally, there are integration tests that run against the boards. Note that these tests require hardware that supports canlib, such as the Kvaser Leaf Light.
The integration tests are found in rover_py/tests
. To run a test from the repo root directory run python -m rover_py.tests.<test_name>
. Make sure to omit the .py
file extension.
The hardware initialization code for various boards was initially generated using STM32CubeMX. STM32CubeMX projects are defined in .ioc
files located in the boards
directory.
Follow these steps to generate code:
- Load a project in STM32CubeMX.
- Click "GENERATE CODE" in the top right corner.
- If prompted to download firmware, proceed with the download.
Binaries are flashed onto the board using the STLINK-V3SET programmer along with the STM32CubeProgrammer software.