Victron Power System Monitor - Boat, RV and Power Systems
by @lkilpatrick
Monitor Victron Energy power systems and generate beautiful daily email reports with battery status, solar generation, and active alarms. Integrates with Vic...
clawhub install boat-daily-checkπ About This Skill
name: boat-daily-check description: Monitor Victron Energy power systems and generate beautiful daily email reports with battery status, solar generation, and active alarms. Integrates with Victron VRM API to fetch real-time metrics for multiple installations and sends formatted HTML emails. Perfect for boat owners, RV enthusiasts, and off-grid solar systems.
Boat Daily Check β Victron VRM API Monitor
Monitor your Victron power systems with automated daily reports. Fetch real-time battery state of charge, voltage, current, solar generation, and active alarms from the Victron VRM API, then deliver beautifully formatted HTML emails showing status of all your installations.
Overview
This skill:
What You'll Get
Each morning, a clean HTML email with:
Setup
1. Get Your Victron VRM API Token
1. Visit https://vrm.victronenergy.com/access-tokens 2. Create a new access token 3. Copy the token (you'll need this for configuration)
2. Find Your Installation IDs
Each Victron system has an installation ID visible in the VRM URL:
https://vrm.victronenergy.com/installation/000000/dashboard
^^^^^^
Installation ID
3. Identify Your SmartShunt Instance
The skill uses the SmartShunt (battery monitor) to fetch battery data. Find its instance number:
279 (adjust if yours differs)4. Configure Your Installation
Edit the Python script with your details:
vim /home/jeanclaude/.openclaw/workspace/skills/boat-daily-check/scripts/boat-email-report.py
Update these variables:
VRM_TOKEN = "your-token-here"INSTALLATIONS = {
"boat1": {
"id": 000000, # Your installation ID
"name": "Titanic", # Display name
"batteryInstance": 279, # SmartShunt instance number
},
"boat2": {
"id": 000001,
"name": "Endeavour",
"batteryInstance": 279,
}
}
Usage
Generate a Report Now
python3 /home/jeanclaude/.openclaw/workspace/skills/boat-daily-check/scripts/boat-email-report.py
This generates:
out/boat-daily-email.htmlout/boat-status.jsonout/boat-status.csvIntegrate with OpenClaw Cron
Add to your morning email report (or standalone):
openclaw cron add -j '{
"name": "boat-daily-check",
"schedule": {"kind": "cron", "expr": "0 7 * * *", "tz": "America/Los_Angeles"},
"payload": {
"kind": "agentTurn",
"message": "Run boat power system check: python3 /path/to/boat-email-report.py"
},
"delivery": {"mode": "announce"},
"sessionTarget": "isolated"
}'
Or embed in an existing job to include boat status with fishing/weather reports.
API Reference
The skill queries the Victron VRM API v2:
Endpoint: Battery Summary
GET /v2/installations/{id}/widgets/BatterySummary/latest?instance={instance}
Returns: SOC%, voltage, current, temperature, time to go, and alarm states.
Endpoint: Diagnostics
GET /v2/installations/{id}/diagnostics
Returns: All device metadata including solar charger power, inverter status, etc.
Endpoint: Alarms
GET /v2/installations/{id}/alarms?limit=10
Returns: Active alarms with details and device information.
Authentication: All requests use X-Authorization: Token {your-token}
Rate Limits: VRM API has reasonable rate limits (~10 req/sec). The daily script respects these.
Files
boat-daily-check/
βββ SKILL.md (this file)
βββ scripts/
β βββ boat-email-report.py # Main data collection + HTML generation
βββ references/
β βββ victron_attributes.md # Victron attribute code reference
β βββ vrm_api_guide.md # VRM API quick reference
βββ out/
β βββ boat-daily-email.html # Generated email (latest run)
β βββ boat-status.json # JSON data export
β βββ boat-status.csv # CSV export
βββ templates/ (optional)
βββ boat-email-template.html # Email template (customizable)
Customization
Change Email Recipients
Edit boat-email-report.py and modify the email sending logic:
# Change recipient email
recipients = ["your-email@example.com"]
Customize HTML Template
The email template uses Handlebars-style placeholders. Edit the HTML section in the Python script:
html = html.replace("{{pitterPatter.battery.soc}}", f"{value}%")
Or create a custom template file and modify the script to load it.
Add More Installations
Add entries to the INSTALLATIONS dict:
"boat3": {
"id": 999999,
"name": "My Third Boat",
"batteryInstance": 279,
}
Then update the report generation logic to include your new installation.
Modify Metric Selection
Pick different metrics from the Victron widget response. Edit the battery data extraction:
def fetch_battery_data(installation_id, instance):
# Returns: soc, voltage, current, temp
# Add fields like: time_to_go, mid_voltage, etc.
Troubleshooting
"Child 'BatterySummary' not found"
Missing solar/inverter data
python3 boat-email-report.py manually to debugEmail not sending
"delivery": {"mode": "announce"}Empty data in email
Performance
Requirements
requests library (pip install requests)Limitations
Next Steps
1. β
Get your VRM API token
2. β
Find your installation IDs and battery instance numbers
3. β
Update the Python script with your details
4. β
Test with: python3 boat-email-report.py
5. β
Set up a cron job for daily automated reports
Support & Contributions
License
This skill is open source. Feel free to fork, modify, and share!
π‘ Examples
Generate a Report Now
python3 /home/jeanclaude/.openclaw/workspace/skills/boat-daily-check/scripts/boat-email-report.py
This generates:
out/boat-daily-email.htmlout/boat-status.jsonout/boat-status.csvIntegrate with OpenClaw Cron
Add to your morning email report (or standalone):
openclaw cron add -j '{
"name": "boat-daily-check",
"schedule": {"kind": "cron", "expr": "0 7 * * *", "tz": "America/Los_Angeles"},
"payload": {
"kind": "agentTurn",
"message": "Run boat power system check: python3 /path/to/boat-email-report.py"
},
"delivery": {"mode": "announce"},
"sessionTarget": "isolated"
}'
Or embed in an existing job to include boat status with fishing/weather reports.
βοΈ Configuration
1. Get Your Victron VRM API Token
1. Visit https://vrm.victronenergy.com/access-tokens 2. Create a new access token 3. Copy the token (you'll need this for configuration)
2. Find Your Installation IDs
Each Victron system has an installation ID visible in the VRM URL:
https://vrm.victronenergy.com/installation/000000/dashboard
^^^^^^
Installation ID
3. Identify Your SmartShunt Instance
The skill uses the SmartShunt (battery monitor) to fetch battery data. Find its instance number:
279 (adjust if yours differs)4. Configure Your Installation
Edit the Python script with your details:
vim /home/jeanclaude/.openclaw/workspace/skills/boat-daily-check/scripts/boat-email-report.py
Update these variables:
VRM_TOKEN = "your-token-here"INSTALLATIONS = {
"boat1": {
"id": 000000, # Your installation ID
"name": "Titanic", # Display name
"batteryInstance": 279, # SmartShunt instance number
},
"boat2": {
"id": 000001,
"name": "Endeavour",
"batteryInstance": 279,
}
}
π Tips & Best Practices
"Child 'BatterySummary' not found"
Missing solar/inverter data
python3 boat-email-report.py manually to debugEmail not sending
"delivery": {"mode": "announce"}