Custom Integration for Home Assistant: Davey Lifeguard!
Hey Home Assistant Community!
I’m thrilled to announce my first custom integration for Home Assistant: Davey Lifeguard!
For those of you who own a Davey Lifeguard connected pool management system, this integration aims to bring your pool data and controls directly into your Home Assistant dashboard. As an independent developer and a Davey Lifeguard user myself, my goal is to centralize pool management within our favorite home automation platform.
What does this integration offer?
This initial version provides the following key features:
Real-time Sensor Monitoring:
Keep an eye on crucial pool parameters:
- Water pH
- ORP (Oxidation-Reduction Potential)
- Water Temperature
- Salinity
- Chlorine Production Rate
- VSD Pump Speed
Equipment Status and Diagnostics:
Get insights into the health of your system:
- Connection status of all probes
- Overall device status
- Detection of common errors (flow, ORP, pH, salt)
Equipment Control:
Take charge of essential functions directly from Home Assistant:
- Activate/deactivate operating modes (manual, boost)
- Set your desired pH level
- Set your desired ORP level
- Adjust the speed of your VSD pump
Technical Details:
- This integration utilizes Home Assistant’s
DataUpdateCoordinator
for efficient data fetching. - Communication is established with the Davey cloud API (unfortunately, local access doesn’t seem to be an option at this time).
- Authentication uses tokens and refresh tokens, managed securely within
config_entry
. - API requests are grouped and optimized using
asyncio.gather
. - The integration includes translations for English and French, with dynamic naming based on your chosen language.
- Entities are organized logically as sensors, binary sensors, switches, and select entities.
- It’s a UI-first integration, meaning no manual YAML configuration is required!
- Requires Home Assistant version 2023.x or later.
Target Audience:
This integration is primarily for:
- Home Assistant users who own a Davey Lifeguard system.
- Anyone looking to integrate their pool management into their smart home setup.
- Developers who might be interested in contributing to expand its capabilities.
Project Status:
This is the first functional version and is currently under development. It has been successfully tested on my own Davey Lifeguard system.
Installation:
There are two ways to install this integration: via HACS (recommended) or manually.
Installation via HACS (Home Assistant Community Store):
If you have HACS installed, you can easily add this integration as a custom repository and install it:
-
Ensure HACS is installed. If you don’t have HACS, follow the installation guide here: https://hacs.xyz/docs/use/.
-
Add this repository as a custom repository in HACS:
- In Home Assistant, navigate to “HACS” in the sidebar.
- Click on “Integrations”.
- Click the three dots (
...
) in the top right corner and select “Custom repositories”. - In the “Add custom repository” dialog:
- Repository:
https://github.com/ForWarZz/davey_lifeguard_ha
- Category: Integration
- Click “Add”.
- Repository:
-
Install the “Davey Lifeguard” integration:
- After adding the repository, close the “Custom repositories” dialog.
- Click the “+” button in the bottom right corner of the HACS Integrations page (“Explore & add repositories”).
- Search for “Davey Lifeguard” and click on it.
- Click the “Download” button.
-
Restart your Home Assistant server.
-
Configure the integration:
- After the restart, go to “Settings” > “Devices & Services”.
- Click the “+ Add Integration” button in the bottom right corner.
- Search for “Davey Lifeguard” and click on it.
- Follow the on-screen instructions to enter your Davey Lifeguard account credentials (likely the email and password used for the Davey mobile app).
Manual Installation (Alternative):
-
Access your Home Assistant configuration directory. This is the directory where your
configuration.yaml
file is located. -
Create a new directory named
custom_components
within your configuration directory if it doesn’t already exist. -
Inside the
custom_components
directory, create another new directory nameddavey_lifeguard
. -
Download the files for this integration from the repository and place them inside the
custom_components/davey_lifeguard/
directory. The file structure should look like this:<your_config_directory>/ └── custom_components/ └── davey_lifeguard/ ├── __init__.py ├── config_flow.py ├── sensor.py ├── switch.py └── ... (other integration files)
-
Restart your Home Assistant server.
-
Configure the integration: Follow the same steps as in the HACS installation (step 5).
Contributing:
As this is my first integration, I welcome any contributions! Here are some areas where help would be greatly appreciated:
- Code optimization
- Developing an advanced configuration UI
- Adding support for more sensors or entities
- Providing additional translations
Important Notes:
Please be aware that this is an initial release by a first-time integrator. Improvements are definitely needed, and bugs are likely present. Your patience and feedback during this early stage are highly valued. Also, please note that not all planned features are implemented yet, and development will continue based on feedback and my own progress.
Thank you for your interest, and I look forward to hearing your thoughts and feedback! Let’s make pool management in Home Assistant even better!