Skip to main content
GNSS Documentation
GitHub Toggle Dark/Light/Auto mode Toggle Dark/Light/Auto mode Toggle Dark/Light/Auto mode Back to homepage

Geofencing

Configure multiple geofence zones and monitor their status in real time.

Source: examples/CPP/Geofencing/, examples/C/Geofencing/, examples/Python/geofencing.py

Note
HAT Compatibility — Geofencing is available on the L1 GNSS HAT and L1/L5 RTK HAT only.

What It Does

  1. Configures 1–4 circular geofences (lat, lon, radius)
  2. Sets confidence level for Inside/Outside determination
  3. Optionally enables PIO pin output for hardware signaling
  4. Continuously prints combined and per-fence geofence status

Running

python3 examples/Python/geofencing.py

Edit the geofence coordinates in the script to match your location before running.

See Geofencing Feature and Geofencing Config for full details.