You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
*Warning:* The collision avoidance system is a **last-resort safety feature**, not something to be heavily relied on!
10
+
Always strive to design your experiments to be collision-free by default and have a sufficient number of skilled safety pilots to take over if somethings goes wrong.
11
+
**Do not rely on collision avoidance to save you!**
12
+
9
13
The mutual collision avoidance of the UAVs is implemented by the [MPC tracker](/docs/features/trackers/).
10
14
In short, each UAV shares its **predicted trajectory** with the other UAVs, and checks whether its own predicted trajectory does not collide with the trajectories of the others (with a specified **safety margin**).
11
15
This is illustrated in the figure below ($r$ is the safety margin radius).
12
16
13
17

14
18
15
-
If a future collision is detected, a collision avoidance maneuver is executed by the UAV with the lower **priority**:
19
+
If a future collision is detected, a collision avoidance maneuver is executed by the UAVs:
16
20
17
21
* Both UAVs slow down.
18
-
* The lower-priority UAV (or several UAVs if multiple collisions are predicted) increases its altitude to avoid the collision.
22
+
* The **lower-priority** UAV (or several UAVs if multiple collisions are predicted) increases its altitude to avoid the collision.
19
23
20
-
The UAV priority is selected based on the UAV name: the UAV with the higher number has a lower priority.
21
-
If a UAV has collision avoidance disabled, then it has the highest priority (all other UAVs with enabled collision avoidance will try to avoid it).
24
+
The UAV priority is selected based on the UAV name: the UAV with the higher number has a lower priority (i.e. in the example in the figure above, UAV2 would climb up to avoid UAV1).
25
+
If a UAV has only passive collision avoidance (see below), then it has the highest priority (all other UAVs with enabled collision avoidance will try to avoid it).
22
26
23
27
*Note:* This system relies on communication between the UAVs.
24
28
Therefore, for collision avoidance to work, **the UAVs must be on the same WiFi**, and sharing of the required messages over the LAN must be configured (see below).
25
-
Everything **except the UAV names list** should be set up correctly by default, but it is good practice to double-check before any experiments.
29
+
Everything should be set up correctly by default except for the UAV names list, which you typically **have to set up by yourself** depending on the specific UAVs that you use!
30
+
It is good practice to double-check before any experiments.
26
31
27
32
## Configuring the collision avoidance
28
33
29
-
The parameters of the collision avoidance subsystem are configured in the standard custom config (called simply `custom_config.yaml`) passed to `mrs_uav_core core.launch`.
34
+
The parameters of the collision avoidance subsystem are configured in the standard custom config file (called simply `custom_config.yaml`) passed to `mrs_uav_core core.launch`.
30
35
A tutorial on how to use custom configs is [here](/docs/api/custom_configs/).
31
36
The relevant parameters are:
32
37
```yaml
@@ -42,19 +47,23 @@ mrs_uav_trackers:
42
47
correction: 3.0# the altitude increase step when avoiding collision [m]
43
48
```
44
49
45
-
*Note:* In case the names or the structure of these paremeters change, you can always find the most up-to-date information using the `get_public_params.py` script (see [here](/docs/api/custom_configs/)).
50
+
*Note:* In case the names or the structure of these paremeters change in the future, you can always find the most up-to-date information using the `get_public_params.py` script (see [here](/docs/api/custom_configs/)).
46
51
47
52
Furthermore, as mentioned above, the UAVs need to communicate with each other and share their predicted trajectories.
48
-
Configuration of the inter-UAV communication has two parts:
53
+
Configuration of the inter-UAV communication has three parts:
49
54
50
55
1. Specifying the list of UAVs in the group that should avoid collisions.
51
56
2. Configuring ROS topics to be shared between the UAVs (the trajectories).
57
+
3. Setting up the hostnames in `/etc/hosts`.
52
58
53
59
The UAV names list is specified in a special custom config called `network_config.yaml`, that is passed to `mrs_uav_core core.launch` and to `mrs_uav_deployment run_nimbro.py`.
54
60
55
-
In real-world deployments, the ROS topic sharing between UAVs is implemented using the NimbRo system (see our documentation [here](/docs/features/nimbro-network/)).
61
+
In real-world deployments, the sharing of ROS topics between UAVs is implemented using the NimbRo system (see our documentation [here](/docs/features/nimbro-network/)).
56
62
In simulation, all topics are available for all UAVs by default, so NimbRo is not required, but the UAV names list still has to be provided in the `network_config.yaml`.
57
63
64
+
The `/etc/hosts` file should be set up by default, unless you are using some custom-made UAV with special names.
65
+
Check that the IP addresses and the corresponding hostnames of all UAVs are present in the file.
66
+
58
67
## Things to double-check for collision avoidance
59
68
60
69
For all UAVs, check the following conditions to ensure that collision avoidance will work:
0 commit comments