Fix 3-phase AC sensors showing zero/unknown on MOD and SPH TL3 - #22
Merged
Merged
Conversation
PROBLEM: User reported 3-phase AC voltage, current, and power sensors showing as "unknown" or not appearing at all on MOD 6000-15000TL3-XH inverter. Register scan showed valid AC data but sensors weren't created. ROOT CAUSES: 1. Register name mismatch: - Profiles defined: 'ac_voltage_r', 'ac_current_r', 'ac_power_r_low' - Code looked for: 'ac_voltage', 'ac_current', 'ac_power_low' - Result: Registers not found → zero values 2. Missing dataclass fields: - GrowattData only had generic ac_voltage/current/power - No individual phase fields (ac_voltage_r/s/t, etc.) 3. Missing sensors from profile: - THREE_PHASE_SENSORS didn't include 'ac_voltage_r/s/t' - Sensors defined but not enabled 4. No code to read individual phases: - Only generic AC reading code existed - Individual 3-phase registers never accessed FIXES: 1. Enhanced register lookup to support aliases: - _find_register_by_name() now checks both 'name' and 'alias' - Allows phase-specific registers to be found by generic names 2. Added generic aliases in profiles (MOD and SPH TL3): - ac_voltage_r → alias 'ac_voltage' - ac_current_r → alias 'ac_current' - ac_power_r_low → alias 'ac_power_low' - Phase R serves as "main" AC output for compatibility 3. Added 3-phase fields to GrowattData dataclass: - ac_voltage_r/s/t, ac_current_r/s/t, ac_power_r/s/t - ac_voltage_rs/st/tr (line-to-line) 4. Added code to read individual 3-phase registers: - Reads all phases R, S, T individually - Reads line-to-line voltages - Populates all phase-specific dataclass fields 5. Updated THREE_PHASE_SENSORS: - Added 'ac_voltage_r', 'ac_voltage_s', 'ac_voltage_t' - Now all phase sensors are enabled RESULT: - Generic AC sensors (ac_voltage/current/power) now work via Phase R alias - Individual phase sensors (R/S/T) now populate with correct values - All 3-phase inverters (MOD, SPH TL3) get full 3-phase monitoring - Backwards compatible with existing configs
0xAHA
added a commit
that referenced
this pull request
Mar 22, 2026
…UKdYcXFzhnaG5vzib Fix 3-phase AC sensors showing zero/unknown on MOD and SPH TL3
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
PROBLEM:
User reported 3-phase AC voltage, current, and power sensors showing as "unknown" or not appearing at all on MOD 6000-15000TL3-XH inverter. Register scan showed valid AC data but sensors weren't created.
ROOT CAUSES:
Register name mismatch:
Missing dataclass fields:
Missing sensors from profile:
No code to read individual phases:
FIXES:
Enhanced register lookup to support aliases:
Added generic aliases in profiles (MOD and SPH TL3):
Added 3-phase fields to GrowattData dataclass:
Added code to read individual 3-phase registers:
Updated THREE_PHASE_SENSORS:
RESULT: