Skip to content

fix(solis_string): keep asking a sleeping inverter, never send 0 W (1.1.4) - #291

Open
frahlg wants to merge 2 commits into
mainfrom
solis-string-recovery
Open

frahlg wants to merge 2 commits into
mainfrom
solis-string-recovery

Conversation

@frahlg

@frahlg frahlg commented Dec 1, 2026

Copy link
Copy Markdown
Member

Problem

A Solis string inverter stops answering Modbus when the sun is gone. 1.1.3 gave up on its power block (3004-3009) after three misses, the same way it gives up on an optional block, and then sent w = 0 until the driver restarted. So an inverter that slept through the night read 0 W all the next day. An owner reported this on an S5-GC20K.

1.1.3 also filled every field from a failed read with 0. invented-number-baseline.json listed 21 such fields for this driver.

Change

  • The power block is read on every poll. While it is silent the driver sends nothing, so FTW sees no reading rather than a false 0 W. test_absent_register_settles.py allows this: a driver that emits nothing while failing is not a violation.
  • The detail blocks (3021, 3033, 3040) keep the three-try rule from docs/WRITING-A-DRIVER.md. They are not read while the power block is silent, and they get three fresh tries when it answers again. A sleeping inverter says nothing about which blocks it has.
  • A field whose register did not answer is left out, never sent as 0. solis_string leaves invented-number-baseline.json.
  • Field names, scales and registers are unchanged. The driver logs once when the power block stops answering and once when it comes back.

The owner also sent a candidate driver. It was not used as is: it dropped the DRIVER table, PROTOCOL and set_make (6 test failures), renamed the PV fields to names Core does not accept, read phase current in 0.01 A where Solis's map says 0.1 A, and retried absent blocks with a backoff capped at 12 polls. That cap means one failed read a minute forever on a model that lacks a block. The 10-poll absent-register probe is too short to catch it.

Test evidence

  • make check: 5575 passed, 927 skipped.
  • New drivers/tests/test_solis_string_recovery.py: 5 tests. Four fail on 1.1.3: night then morning, absent block left alone, fresh tries after an outage, and no frequency or temperature from a failed status block. The fifth pins phase current at 0.1 A.
  • make absent-register-report ID=solis_string:
    ADDR 3004 SETTLED 0 EMITTED 0 COUNTS 1,1,1,1,1,1,1,1,1,1
    ADDR 3021 SETTLED 1 EMITTED 10 COUNTS 1,1,1,0,0,0,0,0,0,0
    ADDR 3033 SETTLED 1 EMITTED 10 COUNTS 1,1,1,0,0,0,0,0,0,0
    ADDR 3040 SETTLED 1 EMITTED 10 COUNTS 1,1,1,0,0,0,0,0,0,0
    
  • make invented-number-report ID=solis_string: "invented":[]. 1.1.3 invented 0 for dc_w, hz, l1_v…l3_a and the rest.

Not yet verified

  • No hardware run yet. The owner will run 1.1.4 as a local driver through a night and a morning on the S5-GC20K and send PV readings and the Solis string log lines. verification_status stays experimental.
  • With 1.1.4 the inverter shows as offline at night. Nobody has checked how the apps show that.
  • After merge, FTW's pin in drivers/BUNDLED_SOURCE.json has to move, or an offline boot keeps running 1.1.3.

🤖 Generated with Claude Code

….1.4)

A Solis string inverter stops answering Modbus when the sun is gone. 1.1.3
gave up on its power block (3004-3009) after three misses, like an optional
block, then sent 0 W until the driver restarted. An inverter that slept
through the night read 0 W all the next day. An owner reported it on an
S5-GC20K.

The power block is now asked on every poll, and the driver sends nothing
while it is silent. The detail blocks keep the three-try rule, are not asked
while the power block is silent, and get three fresh tries when it answers
again. A field whose register did not answer is left out, never sent as 0,
so solis_string leaves invented-number-baseline.json. Field names, scales
and registers are unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Dec 1, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-12-01T05:07:00.451923Z 254135e PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

Brings in deye-svk 0.2.3 (#224) and vag_vehicle 0.3.1 (#213). The only
conflict was CHANGELOG.md, where both sides added an Unreleased entry;
both are kept.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant