Root cause of the grid-calibration auto-revert silently failing: lvx-control
and flash.py encode output_priority solar_battery_utility as "POP01", but PI18
POP is single-digit — the inverter silently rejects "POP01" (raw "POP1" works,
matches the POP_PIRI decoder). Compounded by powermon's adhoc queue wedging,
which dropped commands entirely until a restart. So the monitor logged "revert
done" while the cluster sat in SUB/grid mode for ~1.5h (no harm: battery full,
just running loads on grid).
- lvx-control + flash.py: POP_MAP "01" -> "1" (also patched the live
/usr/local/bin/lvx-control + restarted; verified it now emits POP1).
- grid-cal-monitor: revert now VERIFIES via behavior (line_power_direction
leaves 'input'), and on failure restarts powermon and re-sends raw POP1/PCP0,0,
with a loud manual-fallback message. No more trust-the-publish.
Recovery for the live run: restarted powermon (unstuck adhoc) + raw POP1 + PCP0,0;
confirmed POP=Solar-Battery-Utility, PCP=Solar First, mode=Battery, line_dir=donothing.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Discovered live 2026-06-25 driving an actual grid calibration: forcing a full
grid charge is done via OUTPUT PRIORITY, not voltage thresholds.
- SBU (everyday) won't grid-charge unless the bank is critically low; setting
charger_priority=solar_and_utility alone does nothing at 52V.
- SUB (output_priority=solar_utility_battery) runs loads on grid AND charges the
battery to full. Combined with charger_priority=solar_and_utility, grid charging
engages (device_mode->Hybrid/Line, line_dir->input, pack current jumps to ~120A).
- Both POP/PCP set via lvx-control (all-mode-safe, atomic, no flash/USB). Revert
POP->solar_battery_utility, PCP->solar_first when done.
The re_discharge/flash.py approach is dead (firmware NAKs stop_charge>float);
profile eg4-lp4-v2-calibration.yaml marked DEPRECATED.
- grid-cal-monitor: supervises a SUB grid charge, safety aborts (cell>3.60V/
temp>45C), detects re-anchor (all 6 packs ->100%), auto-reverts POP+PCP (trap).
- calibration-charge skill §3 rewritten to the POP lever.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>