
Geofences
A geofence is a virtual boundary that the flight controller enforces. If the drone approaches or crosses the boundary, the FC takes a configured action (RTL, land, report only, or brake).Fence Types
You can combine multiple fences. For example, one large inclusion polygon for the general flight area and one or more small exclusion polygons around buildings, roads, or restricted zones.
Creating a Geofence
1
Open the Geofence Editor
In the Plan tab, click the geofence tool in the map toolbar (shield icon).
2
Draw the boundary
Click on the map to place vertices of the polygon. Double-click to close the polygon. For a circle, click the center and drag to set the radius.
3
Set the type
Choose inclusion or exclusion. Inclusion fences define where the drone CAN fly. Exclusion fences define no-fly zones.
4
Configure the action
The breach action is configured in the FC’s failsafe parameters (see FC Configuration). Common actions:
- Report Only: Log the breach but take no action
- RTL: Return to launch
- Land: Land immediately
- Brake: Stop and hover (copter only)
5
Upload to FC
Click “Upload Fence” to send the geofence to the flight controller. The FC stores the fence and enforces it during flight.
Editing Fences
After creating a fence:- Drag vertices to reshape the polygon
- Add vertices by clicking on an edge
- Delete vertices by right-clicking a vertex
- Delete the entire fence from the fence list
Downloading Fences
Click “Download Fence” to read the currently stored fence from the flight controller. This is useful when a fence was uploaded from another GCS.Rally Points
Rally points are pre-defined landing positions for emergencies. When the drone triggers an RTL failsafe (low battery, lost link, geofence breach), the FC can fly to the nearest rally point instead of the home position.Why Use Rally Points?
- Home position might be obstructed (crowd, vehicle, obstacle)
- Closer landing options exist in different directions
- Wind direction makes certain landing spots safer
- Multiple takeoff/landing areas in a large field
Creating Rally Points
1
Open the Rally Point Editor
In the Plan tab, click the rally point tool (flag icon) in the toolbar.
2
Click the map to place points
Each click adds a rally point at that location. Add as many as you need.
3
Set altitude
Each rally point has a loiter altitude. The drone will loiter at this altitude above the rally point before landing.
4
Upload to FC
Click “Upload Rally Points” to send them to the flight controller.
Editing Rally Points
- Drag a rally point marker to reposition it
- Click a rally point to edit its altitude
- Right-click to delete a rally point
- Download existing rally points from the FC
How the FC Uses Rally Points
When RTL is triggered:- The FC checks if any rally points are stored.
- If rally points exist, the drone flies to the nearest one (by straight-line distance).
- The drone loiters at the rally point’s configured altitude.
- Depending on FC settings, it either loiters indefinitely or lands automatically.
Rally point behavior depends on the ArduPilot
RALLY_LIMIT_KM parameter. Points beyond this distance from the home position are ignored. Set this parameter to cover your entire operating area.Fence + Rally Combined
A common setup:- One large inclusion polygon defining the entire safe flight area
- Exclusion polygons around buildings, roads, or people
- 3-4 rally points at safe, clear landing areas within the inclusion zone
- Altitude fence set in the FC parameters as a ceiling
Upload and Download
All operations use the MAVLink mission protocol with the appropriate mission type flag.