![]() |
uwrt_mars_rover repositoryuwrt_mars_rover uwrt_mars_rover_description uwrt_mars_rover_drivetrain uwrt_mars_rover_drivetrain_description uwrt_mars_rover_drivetrain_hw |
Repository Summary
Description | Ros Metapackage for UWRT Mars Rover |
Checkout URI | https://github.com/uwrobotics/uwrt_mars_rover.git |
VCS Type | git |
VCS Version | master |
Last Updated | 2023-09-22 |
Dev Status | UNKNOWN |
Released | UNRELEASED |
Tags | No category tags. |
Contributing |
Help Wanted (-)
Good First Issues (-) Pull Requests to Review (-) |
Packages
Name | Version |
---|---|
uwrt_mars_rover | 0.0.0 |
uwrt_mars_rover_description | 0.0.0 |
uwrt_mars_rover_drivetrain | 0.0.0 |
uwrt_mars_rover_drivetrain_description | 0.0.0 |
uwrt_mars_rover_drivetrain_hw | 0.0.0 |
README
uwrt_mars_rover
Repository Setup
Downloading the Repository and Getting Dependencies
- Navigate to your ROS2 workspace in the terminal (e.g:
dev_ws
oruwrt_ws
) - Create a
src
directory if you haven’t already:mkdir -p dev_ws/src
. - Navigate inside of your
src
directory:cd src
- Clone the repository into your
src
directory:git clone git@github.com:uwrobotics/uwrt_mars_rover.git
- Update your system before continuing:
sudo apt update -y --no-install-recommends && sudo apt dist-upgrade -y
- Install
rosdep
, the ROS dependency manager:sudo apt install -y python3-rosdep
- Download the repository’s upstream dependencies:
vcs import --input uwrt_mars_rover/common_upstream_dependencies.repos
- Update rosdep via
rosdep update --include-eol-distros
, including end-of-life ROS2 distros (we use Galactic). - Navigate back to the root of your workspace, and install all dependencies for your ROS packages:
rosdep install --from-paths src -y --ignore-src
.
You can re-navigate to the root of your workspace at any time and rerun #8 and #9 to update your ROS packages’ dependencies.
For clarification, the repository should live in ~/ros2_ws/src/uwrt_mars_rover
.
Building and Installing the Repository
- Run
source /opt/ros/galactic/setup.bash
- Navigate to the root of your ROS2 workspace (e.g:
cd ~/ros2_ws
) - Build everything in the workspace:
colcon build
- Install the built files:
. install/setup.bash
Adding Dependencies
For ease of setup on the Jetson, we should always try to use prebuilt binaries of dependent ROS packages, instead of
including their sources. This means that if a package you write is dependent on a 3rd party package, you should just
declare that dependency in the CMakelists.txt
and package.xml
. rosdep
will take care of resolving the
dependencies.
In the event that you cannot use the binaries (ex. we rely on a feature that has not been released), the package source
code should be cloned outside of our metapackage, so that our CI doesn’t run linting/formatting checks on it. To do
this, declare the source dependency in upstream_dependencies.repos
. If using unreleased features(ie. cloning 3rd
party master branch), please pin the rosinstall entry to a commit hash, rather than the branch.
If you need to declare dependencies that are not ROS packages, typically you can declare them as system dependencies in
a package.xml
. If it is an unreleased source dependency, (ex. the roboteq c++ driver we wrote), declare it in the
metapackage_dependencies.repos
. Source code modules are still subject to the clangformat and clangtidy checks
because they should only consist of code the team has written.
Hard Realtime Loop (OLD)
rover.launch
makes the assumption that you are running a linux kernel will realtime capabilities (like our NVIDIA
Jetsons where we have enabled the PREEMPT_RT kernel patch). If this assumption is not true(ex. you are running nodes on
your own development machines), you must run rover.launch
with use_realtime_kernel:=false
On machines with a realtime kernel, make sure you have permissions to lock unlimited memory for processes.
To check:
ulimit -l
If it does not return unlimited
, you must adjust your memory locking permissions:
- Open
/etc/security/limits.conf
as sudo in a text editor (ex. gedit, nano, vim) - Add the following line:
<your username> - memlock -1
- Reboot your computer
- Check that
ulimit -l
returnsunlimited
Git Workflow
Issues
Before writing code, assign yourself the issue that pertains to the code you are going to write. If there is no GitHub issue created yet, create one for yourself! Try to keep all discussions related to the task within the issue.
Branch Naming
To be able to quickly see work done by members, you should name you’re branches with the following scheme:
user/<username>/#<issue number>/<issue name>
For example:
user/wmmc88/#2/update-readme-with-git-workflow
Pull Requests
To merge code into master, you must open a pull request. Branches must be up to date with the latest master to be able
to merge. Choose people you think are familiar with your task to do code reviews of your code. After your PR is merged,
make sure you close the associated issue and delete the branch. Github will usually delete the branch automatically and
you can automatically close the issue by mentioning closes #<issue number>
in the PR or in one of the commits on the
branch.
If you have code that’s not ready to merge, but you’d still like people thoughts on it, open a draft pull request.
Adding New ROS Packages
When you add new ROS packages:
- Add the package name to
PACKAGES_TO_TEST
string in the Github Actions Config
File truncated at 100 lines see the full file