Files
venus/dbus-lightning/config.py
dev 9756538f16 Initial commit: Venus OS boat addons monorepo
Organizes 11 projects for Cerbo GX/Venus OS into a single repository:
- axiom-nmea: Raymarine LightHouse protocol decoder
- dbus-generator-ramp: Generator current ramp controller
- dbus-lightning: Blitzortung lightning monitor
- dbus-meteoblue-forecast: Meteoblue weather forecast
- dbus-no-foreign-land: noforeignland.com tracking
- dbus-tides: Tide prediction from depth + harmonics
- dbus-vrm-history: VRM cloud history proxy
- dbus-windy-station: Windy.com weather upload
- mfd-custom-app: MFD app deployment package
- venus-html5-app: Custom Victron HTML5 app fork
- watermaker: Watermaker PLC control UI

Adds root README, .gitignore, project template, and per-project
.gitignore files. Sensitive config files excluded via .gitignore
with .example templates provided.

Made-with: Cursor
2026-03-16 17:04:16 +00:00

52 lines
1017 B
Python

"""
Configuration for Lightning Monitor Venus OS service.
"""
SERVICE_NAME = 'com.victronenergy.lightning'
# Blitzortung WebSocket endpoints (cycle through on failure)
BLITZORTUNG_SERVERS = [
'wss://ws1.blitzortung.org',
'wss://ws5.blitzortung.org',
'wss://ws6.blitzortung.org',
'wss://ws7.blitzortung.org',
]
BLITZORTUNG_INIT_MSG = '{"a": 111}'
STRIKE_RADIUS_MILES = 500.0 # TODO: restore to 75.0 after testing
STRIKE_MAX_AGE_SECONDS = 7200 # 2 hours
MIN_STRIKES_ACTIVE = 1 # TODO: restore to 3 after testing
ANALYSIS_INTERVAL_SECONDS = 60
WINDOW_SIZE_SECONDS = 900 # 15 minutes
NUM_WINDOWS = 4
MIN_WINDOWS_FOR_APPROACH = 3
R_SQUARED_APPROACHING = 0.7
R_SQUARED_DOWNGRADE = 0.5
MAX_BEARING_STDDEV = 30.0
MAX_ETA_MINUTES = 240
RECONNECT_BASE_DELAY = 1.0
RECONNECT_MAX_DELAY = 60.0
GPS_SAMPLE_INTERVAL = 30
STALE_THRESHOLD_SECONDS = 900 # 15 minutes
DATA_DIR = '/data/dbus-lightning'
LOGGING_CONFIG = {
'level': 'INFO',
'console': True,
'include_timestamp': False,
}