Pilot v2: Core implementation + battery telemetry

Major updates:
- Complete Rust rewrite (pilot-v2/) with working MQTT client
- Fixed MQTT event loop deadlock (background task pattern)
- Battery telemetry for Linux (auto-detected via /sys/class/power_supply)
- Home Assistant auto-discovery for all sensors and switches
- Comprehensive documentation (AVANCEMENT.md, CLAUDE.md, roadmap)
- Docker test environment with Mosquitto broker
- Helper scripts for development and testing

Features working:
 MQTT connectivity with LWT
 YAML configuration with validation
 Telemetry: CPU, memory, IP, battery (Linux)
 Commands: shutdown, reboot, sleep, screen (dry-run tested)
 HA discovery and integration
 Allowlist and cooldown protection

Ready for testing on real hardware.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
This commit is contained in:
Gilles Soulier
2025-12-30 06:23:00 +01:00
parent b7e67c6501
commit c5381b7112
4453 changed files with 78647 additions and 0 deletions

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=../../sysinfo/enum.DiskKind.html">
<title>Redirection</title>
</head>
<body>
<p>Redirecting to <a href="../../sysinfo/enum.DiskKind.html">../../sysinfo/enum.DiskKind.html</a>...</p>
<script>location.replace("../../sysinfo/enum.DiskKind.html" + location.search + location.hash);</script>
</body>
</html>

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=../../sysinfo/enum.ProcessStatus.html">
<title>Redirection</title>
</head>
<body>
<p>Redirecting to <a href="../../sysinfo/enum.ProcessStatus.html">../../sysinfo/enum.ProcessStatus.html</a>...</p>
<script>location.replace("../../sysinfo/enum.ProcessStatus.html" + location.search + location.hash);</script>
</body>
</html>

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=../../sysinfo/enum.Signal.html">
<title>Redirection</title>
</head>
<body>
<p>Redirecting to <a href="../../sysinfo/enum.Signal.html">../../sysinfo/enum.Signal.html</a>...</p>
<script>location.replace("../../sysinfo/enum.Signal.html" + location.search + location.hash);</script>
</body>
</html>

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=../../sysinfo/enum.ThreadKind.html">
<title>Redirection</title>
</head>
<body>
<p>Redirecting to <a href="../../sysinfo/enum.ThreadKind.html">../../sysinfo/enum.ThreadKind.html</a>...</p>
<script>location.replace("../../sysinfo/enum.ThreadKind.html" + location.search + location.hash);</script>
</body>
</html>

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=../../sysinfo/enum.UpdateKind.html">
<title>Redirection</title>
</head>
<body>
<p>Redirecting to <a href="../../sysinfo/enum.UpdateKind.html">../../sysinfo/enum.UpdateKind.html</a>...</p>
<script>location.replace("../../sysinfo/enum.UpdateKind.html" + location.search + location.hash);</script>
</body>
</html>

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=../../sysinfo/fn.get_current_pid.html">
<title>Redirection</title>
</head>
<body>
<p>Redirecting to <a href="../../sysinfo/fn.get_current_pid.html">../../sysinfo/fn.get_current_pid.html</a>...</p>
<script>location.replace("../../sysinfo/fn.get_current_pid.html" + location.search + location.hash);</script>
</body>
</html>

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=../../sysinfo/struct.CGroupLimits.html">
<title>Redirection</title>
</head>
<body>
<p>Redirecting to <a href="../../sysinfo/struct.CGroupLimits.html">../../sysinfo/struct.CGroupLimits.html</a>...</p>
<script>location.replace("../../sysinfo/struct.CGroupLimits.html" + location.search + location.hash);</script>
</body>
</html>

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=../../sysinfo/struct.Component.html">
<title>Redirection</title>
</head>
<body>
<p>Redirecting to <a href="../../sysinfo/struct.Component.html">../../sysinfo/struct.Component.html</a>...</p>
<script>location.replace("../../sysinfo/struct.Component.html" + location.search + location.hash);</script>
</body>
</html>

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=../../sysinfo/struct.Components.html">
<title>Redirection</title>
</head>
<body>
<p>Redirecting to <a href="../../sysinfo/struct.Components.html">../../sysinfo/struct.Components.html</a>...</p>
<script>location.replace("../../sysinfo/struct.Components.html" + location.search + location.hash);</script>
</body>
</html>

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=../../sysinfo/struct.Cpu.html">
<title>Redirection</title>
</head>
<body>
<p>Redirecting to <a href="../../sysinfo/struct.Cpu.html">../../sysinfo/struct.Cpu.html</a>...</p>
<script>location.replace("../../sysinfo/struct.Cpu.html" + location.search + location.hash);</script>
</body>
</html>

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=../../sysinfo/struct.CpuRefreshKind.html">
<title>Redirection</title>
</head>
<body>
<p>Redirecting to <a href="../../sysinfo/struct.CpuRefreshKind.html">../../sysinfo/struct.CpuRefreshKind.html</a>...</p>
<script>location.replace("../../sysinfo/struct.CpuRefreshKind.html" + location.search + location.hash);</script>
</body>
</html>

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=../../sysinfo/struct.Disk.html">
<title>Redirection</title>
</head>
<body>
<p>Redirecting to <a href="../../sysinfo/struct.Disk.html">../../sysinfo/struct.Disk.html</a>...</p>
<script>location.replace("../../sysinfo/struct.Disk.html" + location.search + location.hash);</script>
</body>
</html>

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=../../sysinfo/struct.DiskUsage.html">
<title>Redirection</title>
</head>
<body>
<p>Redirecting to <a href="../../sysinfo/struct.DiskUsage.html">../../sysinfo/struct.DiskUsage.html</a>...</p>
<script>location.replace("../../sysinfo/struct.DiskUsage.html" + location.search + location.hash);</script>
</body>
</html>

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=../../sysinfo/struct.Disks.html">
<title>Redirection</title>
</head>
<body>
<p>Redirecting to <a href="../../sysinfo/struct.Disks.html">../../sysinfo/struct.Disks.html</a>...</p>
<script>location.replace("../../sysinfo/struct.Disks.html" + location.search + location.hash);</script>
</body>
</html>

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=../../sysinfo/struct.Gid.html">
<title>Redirection</title>
</head>
<body>
<p>Redirecting to <a href="../../sysinfo/struct.Gid.html">../../sysinfo/struct.Gid.html</a>...</p>
<script>location.replace("../../sysinfo/struct.Gid.html" + location.search + location.hash);</script>
</body>
</html>

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=../../sysinfo/struct.Group.html">
<title>Redirection</title>
</head>
<body>
<p>Redirecting to <a href="../../sysinfo/struct.Group.html">../../sysinfo/struct.Group.html</a>...</p>
<script>location.replace("../../sysinfo/struct.Group.html" + location.search + location.hash);</script>
</body>
</html>

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=../../sysinfo/struct.Groups.html">
<title>Redirection</title>
</head>
<body>
<p>Redirecting to <a href="../../sysinfo/struct.Groups.html">../../sysinfo/struct.Groups.html</a>...</p>
<script>location.replace("../../sysinfo/struct.Groups.html" + location.search + location.hash);</script>
</body>
</html>

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=../../sysinfo/struct.LoadAvg.html">
<title>Redirection</title>
</head>
<body>
<p>Redirecting to <a href="../../sysinfo/struct.LoadAvg.html">../../sysinfo/struct.LoadAvg.html</a>...</p>
<script>location.replace("../../sysinfo/struct.LoadAvg.html" + location.search + location.hash);</script>
</body>
</html>

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=../../sysinfo/struct.MacAddr.html">
<title>Redirection</title>
</head>
<body>
<p>Redirecting to <a href="../../sysinfo/struct.MacAddr.html">../../sysinfo/struct.MacAddr.html</a>...</p>
<script>location.replace("../../sysinfo/struct.MacAddr.html" + location.search + location.hash);</script>
</body>
</html>

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=../../sysinfo/struct.MemoryRefreshKind.html">
<title>Redirection</title>
</head>
<body>
<p>Redirecting to <a href="../../sysinfo/struct.MemoryRefreshKind.html">../../sysinfo/struct.MemoryRefreshKind.html</a>...</p>
<script>location.replace("../../sysinfo/struct.MemoryRefreshKind.html" + location.search + location.hash);</script>
</body>
</html>

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=../../sysinfo/struct.NetworkData.html">
<title>Redirection</title>
</head>
<body>
<p>Redirecting to <a href="../../sysinfo/struct.NetworkData.html">../../sysinfo/struct.NetworkData.html</a>...</p>
<script>location.replace("../../sysinfo/struct.NetworkData.html" + location.search + location.hash);</script>
</body>
</html>

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=../../sysinfo/struct.Networks.html">
<title>Redirection</title>
</head>
<body>
<p>Redirecting to <a href="../../sysinfo/struct.Networks.html">../../sysinfo/struct.Networks.html</a>...</p>
<script>location.replace("../../sysinfo/struct.Networks.html" + location.search + location.hash);</script>
</body>
</html>

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=../../sysinfo/struct.Pid.html">
<title>Redirection</title>
</head>
<body>
<p>Redirecting to <a href="../../sysinfo/struct.Pid.html">../../sysinfo/struct.Pid.html</a>...</p>
<script>location.replace("../../sysinfo/struct.Pid.html" + location.search + location.hash);</script>
</body>
</html>

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=../../sysinfo/struct.Process.html">
<title>Redirection</title>
</head>
<body>
<p>Redirecting to <a href="../../sysinfo/struct.Process.html">../../sysinfo/struct.Process.html</a>...</p>
<script>location.replace("../../sysinfo/struct.Process.html" + location.search + location.hash);</script>
</body>
</html>

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=../../sysinfo/struct.ProcessRefreshKind.html">
<title>Redirection</title>
</head>
<body>
<p>Redirecting to <a href="../../sysinfo/struct.ProcessRefreshKind.html">../../sysinfo/struct.ProcessRefreshKind.html</a>...</p>
<script>location.replace("../../sysinfo/struct.ProcessRefreshKind.html" + location.search + location.hash);</script>
</body>
</html>

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=../../sysinfo/struct.RefreshKind.html">
<title>Redirection</title>
</head>
<body>
<p>Redirecting to <a href="../../sysinfo/struct.RefreshKind.html">../../sysinfo/struct.RefreshKind.html</a>...</p>
<script>location.replace("../../sysinfo/struct.RefreshKind.html" + location.search + location.hash);</script>
</body>
</html>

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=../../sysinfo/struct.System.html">
<title>Redirection</title>
</head>
<body>
<p>Redirecting to <a href="../../sysinfo/struct.System.html">../../sysinfo/struct.System.html</a>...</p>
<script>location.replace("../../sysinfo/struct.System.html" + location.search + location.hash);</script>
</body>
</html>

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=../../sysinfo/struct.Uid.html">
<title>Redirection</title>
</head>
<body>
<p>Redirecting to <a href="../../sysinfo/struct.Uid.html">../../sysinfo/struct.Uid.html</a>...</p>
<script>location.replace("../../sysinfo/struct.Uid.html" + location.search + location.hash);</script>
</body>
</html>

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=../../sysinfo/struct.User.html">
<title>Redirection</title>
</head>
<body>
<p>Redirecting to <a href="../../sysinfo/struct.User.html">../../sysinfo/struct.User.html</a>...</p>
<script>location.replace("../../sysinfo/struct.User.html" + location.search + location.hash);</script>
</body>
</html>

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="refresh" content="0;URL=../../sysinfo/struct.Users.html">
<title>Redirection</title>
</head>
<body>
<p>Redirecting to <a href="../../sysinfo/struct.Users.html">../../sysinfo/struct.Users.html</a>...</p>
<script>location.replace("../../sysinfo/struct.Users.html" + location.search + location.hash);</script>
</body>
</html>