-
It is highly recommended to use a Ubuntu linux operating system.
-
If needed a virtual machine will work
-
Follow the installation instructions found here
-
Create python virtual environment:
python3 -m venv venv
-
Enable virtual environment (venv):
source venv/bin/activate
- Note: venv can be disabled by running
deactivate
at any time
- Note: venv can be disabled by running
-
Install dependencies (must have ros 2 already installed):
pip install -r requirements.txt
- Note: requirements.txt can be updated with new dependencies by running
pip freeze > requirements.txt
- Note: requirements.txt can be updated with new dependencies by running
-
Run
source build_packages.bash
while in the workspace (only needs to be done once) -
Launch the rover with
ros2 launch rover_launch.xml
-
Launch the laptop with
ros2 launch home_launch.xml
- All ROS2 packages are contained in
src/
directory - Packages can be built by running
colcon build --symlink-install
from workspace - Add built packages to ROS2 environment by running
source install/setup.bash
-
Packages can be created by navigating to
src/
and runningros2 pkg create --build-type ament_python <package_name>
-
Add node files to
src/package_name/package_name
-
Add node to source script
src/package_name/setup.py
by modifying like so:
entry_points={
'console_scripts': [
'node_name = package_name.node_name:main',
],
}