This repository holds the scripts for:
This script is designed to run on a system with a USB or UART connection to a PixHawk Board, and a camera system. Some functions may not work if the above requirements are not met, but our systems should be designed in a robust way to allow most functions to still work.
git submodule update --init --recursive
pip install -r requirements.txt
git submodule update --init --recursive
sudo apt install opencv-python
pip install -r requirements.txt
To setup a systemd service so that shepard will automatically start and restart.
uaarg@raspberrypi:~/shepard $ sudo ln shepard.service /etc/systemd/system
uaarg@raspberrypi:~/shepard $ sudo systemctl enable shepard.service
Created symlink /etc/systemd/system/multi-user.target.wants/shepard.service → /etc/systemd/system/shepard.service.
uaarg@raspberrypi:~/shepard $ sudo systemctl start shepard.service
Then you can confirm that everything is working by running:
uaarg@raspberrypi:~/shepard $ sudo systemctl status shepard.service
● shepard.service - Shepard
Loaded: loaded (/etc/systemd/system/shepard.service; enabled; vendor preset: enabled)
Active: active (running) since Mon 2023-04-03 18:40:55 MDT; 8min ago
Main PID: 2210 (python)
Tasks: 9 (limit: 3933)
CPU: 15min 59.449s
CGroup: /system.slice/shepard.service
├─2210 python /home/uaarg/shepard/main.py
├─2220 python /home/uaarg/shepard/main.py
├─2221 python /home/uaarg/shepard/main.py
└─2222 python /home/uaarg/shepard/main.py
sudo usermod -a -G tty {your username}
sudo usermod -a -G dialout {your username}
We have several tools setup, please use them. These are:
./scripts/lint.sh
Run a linter over all python files./scripts/fmt.sh
Run a formatter over all python filesAlso, keep in mind that the tests and linter is run on every commit and/or PR in our CI.