Home Assistant custom integration that keeps a configured OpenUV instance aligned with a moving GPS position.
- Watches configurable latitude and longitude sensor entities.
- Updates OpenUV only after movement exceeds a configurable distance threshold.
- Debounces GPS updates so paired coordinates can settle.
- Supports reconfiguration from Home Assistant without deleting the entry.
- Reuses the existing OpenUV entities and service device when coordinates change.
- Cleans up stale OpenUV service devices/entities left by older location updates.
- Exposes diagnostic distance and last-successful-update sensors.
- Persists the last applied coordinates across Home Assistant restarts.
- Home Assistant
- OpenUV already configured
- Sensor entities that provide latitude and longitude in decimal degrees
- In HACS, add
https://github.com/danfulton72/openuv_dynamic_locationas a custom repository of type Integration. - Install OpenUV Dynamic Location.
- Restart Home Assistant.
- Go to Settings → Devices & services → Add integration and search for OpenUV Dynamic Location.
Copy custom_components/openuv_dynamic_location from this repository to config/custom_components/openuv_dynamic_location and restart Home Assistant.
During setup, choose the latitude sensor, longitude sensor, and the OpenUV config entry to update. The target is required so a multi-instance installation can never update an arbitrary first entry.
Options control the movement threshold (default 25 km) and debounce delay (default 2 seconds). Use Reconfigure to change GPS sensors or the target integration.
When the configured location changes, the integration migrates OpenUV's coordinate-based entity and device registry identifiers before setting OpenUV back up. This keeps one OpenUV service/device and preserves the existing entity IDs instead of creating a new set for every location.
- Distance since last update reports the most recently measured distance from the last successfully applied location.
- Last updated changes only after OpenUV is actually updated and reloads successfully; initializing a reference after startup does not change this timestamp.
The integration manifest is versioned 1.0.3. HACS displays the latest published GitHub Release; publish a matching v1.0.3 release for the stable release channel.
MIT — see LICENSE.