jblance / mpp-solar

Python package to communicate to MPP Solar PIP-4048MS inverters (and similar)
MIT License
365 stars 151 forks source link

Implement Voltronic (Infini and compatible) Hybrid 10K inverter #199

Closed cbr303 closed 1 year ago

cbr303 commented 2 years ago

Hello, could you please implement Voltronic Hybrid 10K Inverter?

All information about this could be found here: https://github.com/riogrande75/infinipoll10k

Thank you and regards,

Chris

jblance commented 2 years ago

Have you tried PI17 protocol?

cbr303 commented 2 years ago

Hi John,

yes, 10K speaks P17. Here ist the output from the get commands, I did not test all set commands for now. There appear some „unknown“ answers and ET is rejected which may happen because its zero in the device, but there is no error in SolarPower wich correctly shows "0".

Have a look at infinipoll10k: INGS, RTCP, EMINFO could be implemented for P17 and ^P014EDyyyymmddnnn: Query generated energy of day, ^P016EHyyyymmddhhnnn: Query generated energy of hour, to get infos for day and hourly produced energy.

root@solar:~# mpp-solar -p /dev/hidraw0 -P PI17 -c PI
Command: PI - Device Protocol Version inquiry
------------------------------------------------------------
Parameter                       Value           Unit
protocol_version                17                  
root@solar:~# mpp-solar -p /dev/hidraw0 -P PI17 -c ID
Command: ID - Device Serial Number inquiry
------------------------------------------------------------
Parameter                       Value           Unit
serial_number                   1496162107100016000000      
root@solar:~# mpp-solar -p /dev/hidraw0 -P PI17 -c VFW
Command: VFW - Device CPU version inquiry
------------------------------------------------------------
Parameter                       Value           Unit
cpu_version                     VERFW:00001.01      
root@solar:~# mpp-solar -p /dev/hidraw0 -P PI17 -c VFW2
Command: VFW2 - Device CPU 2 version inquiry
------------------------------------------------------------
Parameter                       Value           Unit
cpu_2_version                   VERFW2:00001.01     
root@solar:~# mpp-solar -p /dev/hidraw0 -P PI17 -c MD
Command: MD - Device Model inquiry
------------------------------------------------------------
Parameter                       Value           Unit
machine_number                  Infini-Solar 10KW/3P        
output_rated_va                 10000           kW  
output_power_factor             99              pf  
ac_input_phase_number           3               number
ac_output_phase_number          3               number
norminal_ac_output_voltage      2300            0.1V
norminal_ac_input_voltage       2300            0.1V
battery_piece_number            04              ea  
battery_standard_voltage_per_unit   120             0.1V
root@solar:~# mpp-solar -p /dev/hidraw0 -P PI17 -c PIRI
Command: PIRI - Device rated information
------------------------------------------------------------
Parameter                       Value           Unit
ac_input_rated_voltage          2300            0.1V
ac_input_rated_frequency        500             Hz  
ac_input_rated_current          0434            0.1A
ac_output_rated_voltage         2300            0.1V
ac_output_rated_current         0434            0.1A
mppt_rated_current_per_string   0187            0.1A
battery_rated_voltage           0480            0.1V
mppt_track_number               2               ea  
machine_type                    Hybrid type         
topology                        transformerless     
parallel_for_output             enabled             
unknown_value_in_response_11    0                   
root@solar:~# mpp-solar -p /dev/hidraw0 -P PI17 -c GS
Command: GS - Device rated information
------------------------------------------------------------
Parameter                       Value           Unit
solar_input_voltage_1           0               0.1V
solar_input_voltage_2           0               0.1V
solar_input_current_1           0               0.1A
solar_input_current_2           0               0.1A
battery_voltage                 0               0.1V
battery_capacity                0               %   
battery_current                 0               0.1A
ac_input_voltage_r              2318            0.1V
ac_input_voltage_s              2298            0.1V
ac_input_voltage_t              2309            0.1V
ac_input_frequency              4983            0.01Hz
ac_input_current_r              0               0.1A
ac_input_current_s              0               0.1A
ac_input_current_t              0               0.1A
ac_output_voltage_r             0               0.1V
ac_output_voltage_s             0               0.1V
ac_output_voltage_t             0               0.1V
ac_output_frequency             0               0.01Hz
ac_output_current_r                             0.1A
ac_output_current_s                             0.1A
ac_output_current_t                             0.1A
inner_temperature               24              °C  
component_max_temperature       24              °C  
external_battery_temperature    0               °C  
setting_change_bit              Settings changed - please refresh       
root@solar:~# mpp-solar -p /dev/hidraw0 -P PI17 -c PS
Command: PS - Device Power Status
------------------------------------------------------------
Parameter                       Value           Unit
solar_input_power_1             0               W   
solar_input_power_2             0               W   
battery_power                                   W   
ac_input_active_power_r         0               W   
ac_input_active_power_s         0               W   
ac_input_active_power_t         0               W   
ac_input_total_active_power     0               W   
ac_output_active_power_r        0               W   
ac_output_active_power_s        0               W   
ac_output_active_power_t        0               W   
ac_output_total_active_power    0               W   
ac_output_apparent_power_r      0               VA  
ac_output_apparent_power_s      0               VA  
ac_output_apparent_power_t      0               VA  
ac_output_total_apparent_power  0               VA  
ac_output_power_percentage      0               %   
ac_output_connect_status        Disconnected        
solar_input_1_work_status       Idle                
solar_input_2_work_status       Idle                
battery_power_direction         Idle                
dc/ac_power_direction           Idle                
line_power_direction            Idle                
root@solar:~# mpp-solar -p /dev/hidraw0 -P PI17 -c MOD
Command: MOD - Device working mode inquiry
------------------------------------------------------------
Parameter                       Value           Unit
working_mode                    Fault mode          
root@solar:~# mpp-solar -p /dev/hidraw0 -P PI17 -c WS
Command: WS - Warning status inquiry
------------------------------------------------------------
Parameter                       Value           Unit
solar_input_1_loss              1               bool
unknown_value_in_response_1     1                   
unknown_value_in_response_2     0                   
unknown_value_in_response_3     0                   
unknown_value_in_response_4     0                   
unknown_value_in_response_5     0                   
unknown_value_in_response_6     1                   
unknown_value_in_response_7     0                   
unknown_value_in_response_8     1                   
unknown_value_in_response_9     0                   
unknown_value_in_response_10    0                   
unknown_value_in_response_11    0                   
unknown_value_in_response_12    0                   
unknown_value_in_response_13    0                   
unknown_value_in_response_14    0                   
unknown_value_in_response_15    0                   
unknown_value_in_response_16    0                   
unknown_value_in_response_17    0                   
unknown_value_in_response_18    0                   
unknown_value_in_response_19    0                   
unknown_value_in_response_20    0                   
unknown_value_in_response_21    0                   
unknown_value_in_response_22                        
root@solar:~# mpp-solar -p /dev/hidraw0 -P PI17 -c FLAG
Command: FLAG - Query enable/disable flag status
------------------------------------------------------------
Parameter                       Value           Unit
mute_buzzer_beep                Enabled             
mute_buzzer_beep_in_standby_mode    Disabled            
mute_buzzer_beep_only_on_battery_discharged_status  Disabled            
generator_as_ac_input           Disabled            
wide_ac_input_range             Disabled            
n/g_relay_function              Disabled            
unknown_value_in_response_6     0                   
unknown_value_in_response_7     0                   
unknown_value_in_response_8     1                   
root@solar:~# mpp-solar -p /dev/hidraw0 -P PI17 -c T
Command: T - Query current time
------------------------------------------------------------
Parameter                       Value           Unit
datetime                        20220214220325  YYYYMMDDHHMMSS
root@solar:~# mpp-solar -p /dev/hidraw0 -P PI17 -c ET
Command: ET - Query total generated energy
------------------------------------------------------------
Parameter                       Value           Unit
warning0                        Command ET was rejected     
root@solar:~# mpp-solar -p /dev/hidraw0 -P PI17 -c BATS
Command: BATS - Query battery setting
------------------------------------------------------------
Parameter                       Value           Unit
battery_maximum_charge_current  600             0.1A
battery_constant_charge_voltage(c.v.)   560             0.1V
battery_floating_charge_voltage 540             0.1V
battery_stop_charger_current_level_in_floating_charging 0               0.1A
keep_charged_time_of_battery_catch_stopped_charging_current_level   60              Minutes
battery_voltage_of_recover_to_charge_when_battery_stop_charger_in_floating_charging 530             0.1V
battery_under_voltage           420             0.1V
battery_under_voltage_release   480             0.1V
battery_weak_voltage_in_hybrid_mode 480             0.1V
battery_weak_voltage_release_in_hybrid_mode 540             0.1V
battery_type                    Li-Fe               
reserved                                            
battery_install_date                            YYYYMMDDHHMMSS
ac_charger_keep_battery_voltage_function_enable/diable  Disabled            
ac_charger_keep_battery_voltage 480             0.1V
battery_temperature_sensor_compensation 0               0.m1V
max._ac_charging_current        600             0.1A
battery_discharge_max_current_in_hybrid_mode    300             A   

Greets Christoph

jblance commented 2 years ago

ok will look at creating a copy of the pi17 protocol and try to implement fixes for the above issues ET might be more problematic, let me think about that one

cbr303 commented 2 years ago

Hey John, thanks a lot for this

skoky commented 2 years ago

@cbr303 I have added those new commands INGS, RTCP, EMINFO in my fork here https://github.com/skoky/mpp-solar/tree/p17_new_commands and it seems to work on my InfiniSolar 10k as well. Anyway those are not documented anywhere in specs. Will improve results parsing and make pull request to @jblance for merging

skoky commented 2 years ago

I have implemented those undocumented commands INGS, RTCP, EMINFO Not sure how to name response params, suggest change if you wish. Commands to query energy seems to work on mine

pi@raspi4:~/mpp-solar $ sudo  mpp-solar -p /dev/hidraw0 -P PI17  -c ET
Command: ET - Query total generated energy
------------------------------------------------------------
Parameter                       Value           Unit
generated_energy                11131           kWh 

or

pi@raspi4:~/mpp-solar $ sudo  mpp-solar -p /dev/hidraw0 -P PI17  -c ED20211111 
Command: ED20211111 - Query generated energy of day
------------------------------------------------------------
Parameter                       Value           Unit
generated_energy                885             Wh  

When using ET commands, do not use nnn, it is calculated in the code