# Air Traffic Avoidance: UTM

## Air Traffic Avoidance: UAS Traffic Management (UTM)

PX4 can use MAVLink [`UTM_GLOBAL_POSITION`](https://mavlink.io/en/messages/common.html#UTM_GLOBAL_POSITION) messages to support simple air traffic avoidance in [missions](../../flying/flight_modes/mission). If a potential collision is detected, PX4 can _warn_, immediately [land](../../flying/flight_modes/land), or [return](../../flying/flight_modes/return) (depending on the value of [`NAV_TRAFF_AVOID`](#NAV_TRAFF_AVOID)).

:::note This implementation is exactly the same as for [ADS-B traffic avoidance](traffic_avoidance_adsb) (except for the source of other-vehicle data). For more information see [implementation](#implementation) below. :::

### Configure Traffic Avoidance

Configure the trigger distance and action when there is a potential collision using the parameters below:

| Parameter                                                                            | Description                                                                                                                                                                       |
| ------------------------------------------------------------------------------------ | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| [NAV\_TRAFF\_AVOID](../../../advanced_config/parameter_reference#NAV_TRAFF_AVOID)    | Enable traffic avoidance mode specify avoidance response. 0: Disable, 1: Warn only, 2: Return mode, 3: Land mode.                                                                 |
| [NAV\_TRAFF\_A\_HOR](../../../advanced_config/parameter_reference#NAV_TRAFF_A_HOR)   | Horizonal radius of cylinder around the vehicle that defines its airspace (i.e. the airspace in the ground plane).                                                                |
| [NAV\_TRAFF\_A\_VER](../../../advanced_config/parameter_reference#NAV_TRAFF_A_VER)   | Vertical height above and below vehicle of the cylinder that defines its airspace (also see [NAV\_TRAFF\_A\_HOR](#NAV_TRAFF_A_HOR)).                                              |
| [NAV\_TRAFF\_COLL\_T](../../../advanced_config/parameter_reference#NAV_TRAFF_COLL_T) | Collision time threshold. Avoidance will trigger if the estimated time until collision drops below this value (the estimated time is based on relative speed of traffic and UAV). |

### Implementation

PX4 listens for `UTM_GLOBAL_POSITION` MAVLink messages during missions. When a valid message is received, its validity flags, position and heading are mapped into the same `transponder_report` UORB topic used for _ADS-B traffic avoidance_.

The implementation is otherwise _exactly_ as described in: [ADS-B traffic avoidance > Implementation](../traffic_avoidance_adsb#implementation).

:::note [UTM\_GLOBAL\_POSITION](https://mavlink.io/en/messages/common.html#UTM_GLOBAL_POSITION) contains additional fields that are not provided by an ADSB transponder (see [ADSB\_VEHICLE](https://mavlink.io/en/messages/common.html#ADSB_VEHICLE)). The current implementation simply drops the additional fields (including information about the vehicle's planned next waypoint). :::

### Further Information

* [ADS-B Traffic Avoidance](traffic_avoidance_adsb)
