Skip to content

Commit 3f463c5

Browse files
committed
minor updates to inter-UAV collision avoidance
1 parent 5c3d62c commit 3f463c5

1 file changed

Lines changed: 18 additions & 9 deletions

File tree

  • docs/50-features/59-inter-uav-collision-avoidance

docs/50-features/59-inter-uav-collision-avoidance/index.md

Lines changed: 18 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -6,27 +6,32 @@ description: Inter-UAV collision avoidance
66

77
# Inter-UAV collision avoidance
88

9+
*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+
913
The mutual collision avoidance of the UAVs is implemented by the [MPC tracker](/docs/features/trackers/).
1014
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**).
1115
This is illustrated in the figure below ($r$ is the safety margin radius).
1216

1317
![Trajectory prediction and collision detection.](fig/inter-uav-collision-avoidance.svg)
1418

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:
1620

1721
* 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.
1923

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).
2226

2327
*Note:* This system relies on communication between the UAVs.
2428
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.
2631

2732
## Configuring the collision avoidance
2833

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`.
3035
A tutorial on how to use custom configs is [here](/docs/api/custom_configs/).
3136
The relevant parameters are:
3237
```yaml
@@ -42,19 +47,23 @@ mrs_uav_trackers:
4247
correction: 3.0 # the altitude increase step when avoiding collision [m]
4348
```
4449
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/)).
4651

4752
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:
4954

5055
1. Specifying the list of UAVs in the group that should avoid collisions.
5156
2. Configuring ROS topics to be shared between the UAVs (the trajectories).
57+
3. Setting up the hostnames in `/etc/hosts`.
5258

5359
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`.
5460

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/)).
5662
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`.
5763

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+
5867
## Things to double-check for collision avoidance
5968

6069
For all UAVs, check the following conditions to ensure that collision avoidance will work:

0 commit comments

Comments
 (0)