Skip to content

Commit cac2913

Browse files
committed
add README and remove private submodules
1 parent eb2b724 commit cac2913

File tree

115 files changed

+17465
-8
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

115 files changed

+17465
-8
lines changed

.gitmodules

Lines changed: 0 additions & 6 deletions
This file was deleted.

README.md

Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
# Aqua.Bot 2023
2+
3+
![](assets/aquabot_cover.png)
4+
5+
## About
6+
7+
Aqua.Bot is a challenge organized by Sirehna (Naval Group) aimed at developing a program capable of controlling an Unmanned Surface Vehicle (USV) tasked with monitoring a maritime zone and relaying the positions of intruding vessels.
8+
9+
The competition spanned 2 months, during which we developed two key modules:
10+
11+
### Navigation
12+
The navigation module enables autonomous control of the drone within its environment. The initial objective involves reaching the buoy that delineates the search area where the threat is located. Subsequently, it demonstrates the capability to maneuver the surface drone while effectively tracking the identified threat.
13+
14+
https://github.com/EthanDelage/aquabot/assets/50496792/67a0170c-d944-461a-99a4-69b9b991643f
15+
16+
17+
18+
### Perception
19+
The perception module is designed to detect threats utilizing the camera and estimate their distance using lidar sensor. Threat recognition is achieved through color detection, while distance estimation involves projecting the lidar's 3D points onto the camera rendering. By leveraging the threat's distance and angle, the module can calculate its GPS position.
20+
21+
https://github.com/EthanDelage/aquabot/assets/50496792/6377734d-59ac-47a8-b206-32733cc76101
22+
23+
For additional details, please refer to the report available:
24+
25+
- [PDF report](assets/report.pdf)
26+
- [PowerPoint presentation](assets/presentation.pptx)
27+
28+
## Usage
29+
30+
### Dependencies
31+
32+
- OpenCV 4.8.1
33+
- Eigen3
34+
- C++ 17
35+
- Ros Humble
36+
- Gazebo Garden
37+
38+
### Installation
39+
40+
- Install [ROS 2 Humble](https://docs.ros.org/en/humble/Installation/Ubuntu-Install-Debians.html)
41+
- Install [Gazebo Garden](https://gazebosim.org/docs/garden/install_ubuntu)
42+
43+
### Source Ros
44+
45+
```shell
46+
source /opt/ros/humble/setup.sh
47+
```
48+
49+
### Build
50+
51+
```shell
52+
make build
53+
. install/setup.sh
54+
```
55+
56+
### Run
57+
58+
```shell
59+
make launch
60+
```
61+
62+
## Acknowledgments
63+
64+
Following two months of dedicated research and hard work, we are proud to announce that we earned **SECOND PLACE** 🥈 in the competition!
65+
We would like to thank Sirehna and Naval Group for organizing the competition and supporting us.

assets/aquabot_cover.png

327 KB
Loading

assets/navigation.mp4

16.9 MB
Binary file not shown.

assets/perception.mp4

7.08 MB
Binary file not shown.

assets/presentation.pptx

14.7 MB
Binary file not shown.

assets/report.pdf

5.18 MB
Binary file not shown.

src/aquabot

Lines changed: 0 additions & 1 deletion
This file was deleted.

src/aquabot-competitor

Lines changed: 0 additions & 1 deletion
This file was deleted.

src/aquabot-competitor/README.md

Lines changed: 146 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,146 @@
1+
# Aquabot_competitor
2+
3+
# Installation
4+
5+
Before preoceed to this installation you first needs to install vrx and aquabot simulation.
6+
7+
## Step 1 : Aquabot repository
8+
9+
Follow the aquabot installation steps first :
10+
[Aquabot repository](https://github.com/sirehna/Aquabot)
11+
12+
## Step 2 : Additional dependencies
13+
14+
Install OpenCV dependency :
15+
```
16+
sudo apt install libopencv-dev python3-opencv
17+
```
18+
19+
## Step 3 : Aquabot_competitor
20+
21+
Clone this respository inside "~/vrx_ws/src" folder
22+
* Important : File path of this readme should be ~/vrx_ws/src/aquabot_competitor/README.md
23+
24+
Build :
25+
```
26+
cd ~/vrx_ws
27+
colcon build --merge-install
28+
. install/setup.bash
29+
```
30+
31+
# Commands
32+
33+
List of helpful commands and tips.
34+
35+
**Creating your participation package**
36+
37+
To create a package you can create a sub folder and implement the 2 nessessary files (CMakeLists.txt and package.xml) or simply use the next command.
38+
39+
```
40+
cd ~/vrx_ws/src/aquabot_competitor
41+
ros2 pkg create --build-type ament_cmake --node-name my_team_node my_team_package
42+
```
43+
44+
**Compile our package :**
45+
```
46+
cd ~/vrx_ws
47+
colcon build --merge-install
48+
. install/setup.bash
49+
```
50+
51+
**Run our node (C++ or Python):**
52+
53+
To run a ros node you can use 'ros2 run' command :
54+
```
55+
ros2 run package_example example_node_cpp
56+
ros2 run package_example example_node.py
57+
```
58+
59+
**Monitor our topics using commands**
60+
In an other terminal you can read our "status_string" topic :
61+
```
62+
source /opt/ros/humble/setup.bash
63+
ros2 topic echo status_string
64+
```
65+
66+
**Monitor our topics using RQT**
67+
RQT is a powerfull toolbox that contains many ros tools :
68+
```
69+
source /opt/ros/humble/setup.bash
70+
rqt
71+
```
72+
73+
**Monitor our topics using rviz**
74+
RVIZ2 is a powerfull visualization tool that provides a 3D graphical interface to visualize and
75+
interact with ros environnement, such as sensor data, robot models, and trajectories.
76+
It allows users to monitor and debug their robot systems in a user-friendly and intuitive manner.
77+
78+
After start a simulation you can start rviz2 :
79+
```
80+
rviz2
81+
```
82+
Then you can press Add -> By topic and select what you want to see.
83+
84+
**Start the competition simulation**
85+
86+
Without the gazebo graphical environnement. (lightweight) I recommend it for non GPU configurations.
87+
88+
89+
## Permanent sourcing and aliases
90+
91+
I share my additions to the "bashrc" file :
92+
93+
```
94+
gedit ~/.bashrc
95+
```
96+
97+
Add these lines have everythink sourced when starting new terminal :
98+
```
99+
# Source ROS Humble
100+
source /opt/ros/humble/setup.bash
101+
# Source VRX Workspace
102+
source ~/vrx_ws/install/setup.bash
103+
```
104+
105+
Add these lines to add 3 alias to build, source and code for the project :
106+
```
107+
# Add Alias
108+
alias aquabot_build='cd ~/vrx_ws && colcon build --merge-install'
109+
alias aquabot_source='source ~/vrx_ws/install/setup.bash'
110+
alias aquabot_code='code ~/vrx_ws/src/aquabot_competitor'
111+
```
112+
113+
114+
## Example content (aquabot_examples):
115+
116+
This project already contains example content inside aquabot_example folder
117+
- package_example
118+
- opencv_example
119+
- aquabot_example
120+
121+
These are 3 package that contains cpp and python nodes that can serve as examples packages.
122+
123+
### package_example
124+
125+
This is a simple package example, contain cpp and python node examples.
126+
127+
You can refer to this ROS tutorial :
128+
Link : https://docs.ros.org/en/humble/Tutorials/Beginner-Client-Libraries/Writing-A-Simple-Cpp-Publisher-And-Subscriber.html
129+
130+
### opencv_example
131+
132+
This is a opencv example package, you can refer to this example for opencv implementation.
133+
134+
Contains 2 nodes :
135+
CPP Node : minimal_opencv_ros2_node
136+
Creates and publish random_image
137+
138+
Python Node : minimal_opencv_subscriber
139+
Subscribe to the random_image topic and show the image
140+
141+
### aquabot_example
142+
143+
This is an example applied to the aquabot competition
144+
145+
Contains 1 node :
146+
CPP Node : That moves the motor and retrieve that position
Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
cmake_minimum_required(VERSION 3.8)
2+
project(aquabot_example)
3+
4+
if(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang")
5+
add_compile_options(-Wall -Wextra -Wpedantic)
6+
endif()
7+
8+
###########################
9+
10+
11+
# Find dependencies
12+
find_package(ament_cmake REQUIRED)
13+
find_package(rclcpp REQUIRED)
14+
find_package(std_msgs REQUIRED)
15+
find_package(tf2 REQUIRED)
16+
find_package(tf2_ros REQUIRED)
17+
18+
# Executables
19+
add_executable(aquabot_node src/aquabot_node.cpp)
20+
ament_target_dependencies(aquabot_node rclcpp std_msgs tf2 tf2_ros)
21+
target_include_directories(aquabot_node PUBLIC
22+
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
23+
$<INSTALL_INTERFACE:include>)
24+
target_compile_features(aquabot_node PUBLIC c_std_99 cxx_std_17) # Require C99 and C++17
25+
install(TARGETS aquabot_node
26+
DESTINATION lib/${PROJECT_NAME})
27+
28+
# Resources
29+
install(DIRECTORY
30+
launch
31+
DESTINATION share/${PROJECT_NAME})
32+
33+
34+
###########################
35+
36+
if(BUILD_TESTING)
37+
find_package(ament_lint_auto REQUIRED)
38+
# the following line skips the linter which checks for copyrights
39+
# comment the line when a copyright and license is added to all source files
40+
set(ament_cmake_copyright_FOUND TRUE)
41+
# the following line skips cpplint (only works in a git repo)
42+
# comment the line when this package is in a git repo and when
43+
# a copyright and license is added to all source files
44+
set(ament_cmake_cpplint_FOUND TRUE)
45+
ament_lint_auto_find_test_dependencies()
46+
endif()
47+
48+
ament_package()
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
from launch import LaunchDescription
2+
from launch.actions import IncludeLaunchDescription
3+
from launch.actions import DeclareLaunchArgument
4+
from launch.launch_description_sources import PythonLaunchDescriptionSource
5+
from launch_ros.actions import Node
6+
7+
import os
8+
from ament_index_python.packages import get_package_share_directory
9+
10+
def generate_launch_description():
11+
ld = LaunchDescription()
12+
13+
default_world_name = 'aquabot_regatta'
14+
world_arg = DeclareLaunchArgument(
15+
'world',
16+
default_value = default_world_name,
17+
description = 'World name')
18+
ld.add_action(world_arg)
19+
20+
aquabot_competition_launch_file = IncludeLaunchDescription(
21+
PythonLaunchDescriptionSource(
22+
os.path.join(get_package_share_directory('aquabot_gz'),
23+
'launch/competition.launch.py')),
24+
launch_arguments={}.items()
25+
)
26+
27+
# Add executable aquabot_example aquabot_node
28+
aquabot_example_node = Node(
29+
package='aquabot_example',
30+
executable='aquabot_node',
31+
)
32+
33+
ld.add_action(world_arg)
34+
ld.add_action(aquabot_competition_launch_file)
35+
ld.add_action(aquabot_example_node)
36+
37+
return ld
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
<?xml version="1.0"?>
2+
<?xml-model href="http://download.ros.org/schema/package_format3.xsd" schematypens="http://www.w3.org/2001/XMLSchema"?>
3+
<package format="3">
4+
<name>aquabot_example</name>
5+
<version>0.2.0</version>
6+
<description>TODO: Package description</description>
7+
<maintainer email="contact@sirehna.com">competitor</maintainer>
8+
<license>TODO: License declaration</license>
9+
10+
<buildtool_depend>ament_cmake</buildtool_depend>
11+
12+
<depend>rclcpp</depend>
13+
<depend>std_msgs</depend>
14+
<depend>tf2</depend>
15+
<depend>tf2_ros</depend>
16+
17+
<test_depend>ament_lint_auto</test_depend>
18+
<test_depend>ament_lint_common</test_depend>
19+
20+
<export>
21+
<build_type>ament_cmake</build_type>
22+
</export>
23+
</package>

0 commit comments

Comments
 (0)