SAJ Solar inverter

@fredericvl If that is any help for you, here is mine, also WiFi based inverter

Device Type: Suntrio Plus 10K

And the result

21030G1628XXYYYYY,ST10KMTL2BE6XXYYYY,21,2710,10,43,2031,2009,2009,1.0.0,1012,srv1.saj-solar.com,0,0,0,301001728YYYYYY

Also in WiFi version I have more variables available the SAJ component returns

Here is the input of inverter 1:
14020G1728EN19744,SU04KMTL2EN6SD0000,12,0FA0,2,6,1201,1020,65535,1.0.1,1017,srv1.saj-solar.com,0,0,0,301001742008928
Inverter 2:
11020G1748EN27365,SU01KSTL2EN6SD0000,11,03E8,2,6,1205,1050,65535,1.0.1,1017,srv1.saj-solar.com,0,0,0,301001742008995

The first parameter is the serial number of the inverter. I hope this helps you. If you need anything, let me know.

@theleshek @sen many thanks to both of you, this is indeed the output I wanted to see :slight_smile:

@fredericvl, I just updated an the naming option works great. Thanks!!

1 Like

Hi Community,

Here is a newbie question. I recently started to play with Home Assistant but fail to connect my SAJ inverter. I modified my configuration.yaml as described (my inverter is ethernet connected and I have access to the xml) but the integration and sensors do not show up when I restart HA. What am I missing? thanks for you assistance.

Hi Manu, could you please share your real_time_data.xml file with me?
Then I can take a look at it.

Hi Frederic,

thanks for taking the time to look into this. My XML looks like this :

<real_time_data>

<state>Normal</state>

<v-grid>243.0</v-grid>

<i-grid>20.38</i-grid>

<f-grid>49.99</f-grid>

<p-ac>4986</p-ac>

<temp>46.8</temp>

<e-today>14.7</e-today>

<t-today>8.5</t-today>

<e-total>2340.2</e-total>

<CO2>2333.18</CO2>

<t-total>2267.4</t-total>

<v-pv1>316.4</v-pv1>

<i-pv1>9.43</i-pv1>

<v-pv2>343.2 V</v-pv2>

<i-pv2>7.76 A</i-pv2>

<v-bus>383.8</v-bus>

</real_time_data>

Hi Manu,

Could you also share the “equipment_data.xml” file for the record?
Then I have all information about your SAJ inverter model.

I think I’m onto a solution already, it seems that there are too many different forms of XML’s for all models and without them being documented there is nowhere to start ofcourse.
I’ll try to change the code so it will try and all possible parameters but if one is not found it can just skip it and continue with the rest instead of generating an error.

Grtz

Frederic,

Here’s the info :

Sununo-TL5K 5200 580 &nbsp&nbspMax.DC Current Input/Per String 16A/16A 2 2 5000 21.7 >0.99(full load) <0.2 97.7% 97.1% AS4777 V1.25 V1.25 EV1.61.6 15020G1908EN9XXXX SU05KMTL1EN6ED0000

Manu,

In the meantime I have changed the code to solve your problem.
The code change has been merged by Home Assistant earlier today: https://github.com/home-assistant/core/pull/34978
Please note that this does not mean that it is present in the latest version of HA.
Normally it will be in the next main release: 0.110

Hi Frederic,

This is great news. Thank you for taking the time and putting effort in solving my issue.

Hi Frederic,
I’m pretty new to Home Assistant, so apologies for my question. I saw you made a lot of work into the SAJ integration. Thanks for that.
At this moment I added the following information at configuration.yaml:

sensor:

  • platform: saj
    host: IP_ADDRESS_OF_DEVICE

This is working for a day … but it seems the next day I don’t receive updates anymore. Also during the night the sensor get’s an error, which is due to the inverter shutting down. And it stays in that state the next day.
Except for adding these lines of code to the configuration.yaml, is there anything else I need to install? I saw you mentioned somewhere code. Which points out this problem. But I don’t know how to install it.
Many thanks.

Hi Tim,

No extra configuration is needed if it was working already.

When my inverter is offline and I restart Home Assistant at that moment, it will indeed stay in the same state the next day.
Restarting HA while inverter is offline is a still a “bug” that I can’t find any fix for at the moment.
But when I restart HA when the inverter is still online and generating electricity it should keep on working the next day.

Perhaps you did restart Home Assistant when the inverter was offline?

You’re right … I did a restart yesterday evening. I guess that will be the problem then. Thanks for the explanation!

Is there any way to prevent this from happening?
I usually do my coding at night and for it to take affect i would need to restart?

Hello,

I’ve got the exact same issue, the data is collected correctly from the inverter, and the code works great in the daytime but if HA was restarted while the inverter was offline, the data collection stops.

Is there any way to just reload the saj inverter polling code only when HA was restarted during the night? Or shall we just live with it like this?

Hi frederic, i’ve been looking for answer to my problem and every where i google you name appaers.
So i hope you can find the time to help me. I’m having problems in connecting to my saj inverter.
It is ethernet connected and i can reach it by ip but can not integrate it into Home assistant. What am i doing wrong?

This is my configuration :

sensor:

My real time data:
<real_time_data>
Normal
<Vac_l1>235.6</Vac_l1>
<Vac_l2>-</Vac_l2>
<Vac_l3>-</Vac_l3>
<Iac_l1>7.48</Iac_l1>
<Iac_l2>-</Iac_l2>
<Iac_l3>-</Iac_l3>
49.94
-
-
1718
-
-
1718
46.5
7.88
4.7
28174.76
28090.24
16003.5
385.2
2.08
395.0
2.14
419.9
5070
</real_time_data>

My equipment data:

<equipment_data>
Sununo Plus 5K-M
<Max_DC_POWER>5300</Max_DC_POWER>
<Max_DC_Volt>600</Max_DC_Volt>
<DC_Current_String>&nbsp&nbspMax.DC Current Input/Per String</DC_Current_String>
<DC_Current_Content>11A/11A</DC_Current_Content>
<DC_Conn_Sets>2</DC_Conn_Sets>
<Num_MPPT>2</Num_MPPT>
<Rated_AC_Power>5000</Rated_AC_Power>
<Rated_AC_Current>21.7</Rated_AC_Current>
<Power_Factor>0.95 leading~0.95 lagging</Power_Factor>
<Consum_Night><0.2</Consum_Night>
<Max_Eff>97.6%</Max_Eff>
<Euro_Eff>97.2%</Euro_Eff>
<Grid_comp> C10_11 </Grid_comp>
V1.011
V1.011
V1.018
15020G1627BE81286
<Product_Code>SU05KMTL2BE6WD0000</Product_Code>
<eth_ver>V1.002</eth_ver>
</equipment_data>

Hope you can help me, and i am sure to buy you a coffee

Hello everbody no need to reply. I found out that the problem was with my host name .
You shouldn’t have to put http in front of the ip device.
Hope my mistake helps somebody !!

1 Like

So when i make changes with HA and restart after sunset… the next day SAJ does now show any readings… I know when i restart the whole thing after sunrise… it all works again…

So I might have missed it or don’t know what to look for, but I was wondering if anyone know what service to call to reload SAJ and I do not have to restart HA. to get the sensors back again…

1 Like

So far, I have not seen any solution for this. For now, I’m experimenting with an automation that restarts HA 30min after sunrise if the state of the SAJ is not “Normal”, which seems to work. I’m still fine-tuning it, though (offset may need some tuning and I’m wondering whether I should check for state “Wating” as well - I have not tried whether I can check directly for state = unknown, otherwise that would be the best option). Of course, if would be a lot nicer if that was not necessary.