SMA Tripower x (STP XX-50)

I would like to share my experience of integration the information of the inverter SMA Tripower x (STP XX-50) in Home Assistant. The SMA Tripower x series was released in summer 2022.
Much of the information available at this point on the internet refers to the old Tripower series and is only partially correct for the new series.
I’ll try to show you in this text what worked. What did not work. And where I had to code something myself.

  1. Since I also use the sunny home manger 2.0 in addition to the inverter, I started there. Access to the sunny home manager 2.0 was quite easily solvable with the SMA Energy Meter addon. GitHub - kellerza/hassio-sma-em: Home Assistant SMA Add-On

  2. I had less luck with the existing SMA Solar integration (SMA Solar - Home Assistant) . After some testing, I decided to look at used library (pysma) directly. pysma doesn’t seem to work with the new Tripower series.

  3. Tried ha-sunspec. No luck. Tripower X probably doesn’t support sunspec.
    [Update Aug 2023] SunSpec is now supported.

  4. Next try mobus.
    The modbus examples available on the net for access via Modbus did not work either, as they were for older/different devices.

    Based on the SMA information (Sunny Tripower X: Wechselrichter jetzt entdecken! | SMA Solar // Download / Modus), I created a new modbus configuration. I have focused on the fields that are most important to me. Unfortunately, I have not found any information on how to interpret the fields (e.g. sma status) marked TAGLIST. You can always find approaches on the internet, but no complete or official information.

modbus:
  - name: SMA
    type: tcp
    host: 192.168.2.161
    port: 502
    sensors:
      - name: sma_power_ac_raw
        state_class: measurement
        unit_of_measurement: W
        slave: 3
        address: 30775
        count: 2
        data_type: uint32
        scan_interval: 60

     
      - name: sma_power_ac_l1_raw
        unit_of_measurement: W
        state_class: measurement
        slave: 3
        address: 30777
        count: 2
        data_type: int32
        scan_interval: 60

      - name: sma_power_ac_l2_raw
        unit_of_measurement: W
        state_class: measurement
        slave: 3
        count: 2
        address: 30779
        data_type: int32
        scan_interval: 60

      - name: sma_power_ac_l3_raw
        unit_of_measurement: W
        state_class: measurement
        slave: 3
        count: 2
        address: 30781
        data_type: int32
        scan_interval: 60

      - name: sma_power_total_production
        unit_of_measurement: Wh
        state_class: total_increasing
        device_class: energy
        slave: 3
        address: 30513
        scan_interval: 60
        data_type: int64

      - name: sma_status
        slave: 3
        address: 30201
        scan_interval: 60
        count: 2
        data_type: int32
        
[....]

template:
  - sensor:
      - name: "sma_power_ac"
        state: >-
               {% if states('sensor.sma_power_ac_raw')|float < 0 or states('sensor.sma_power_ac_raw')|float > 2000000000 %}
                 0
               {% else %}
                 {{ states('sensor.sma_power_ac_raw') }}
               {% endif %}
        unit_of_measurement: "W"
        state_class: measurement

  1. I was still not really satisfied, because I could not get the information about the individual strings via modus. This information is available on the inverter’s local website.

    So I wrote a small Python script that extracts the files from the website (via JSON) and makes them available im Home Assistant using MQTT-Discovery .
    Please consider this script as a proof of concept, even if I use it successfully myself.
    GitHub - littleyoda/Home-Assistant-Tripower-X-MQTT: Script which reads out the current measured values of an inverter of the SMA Tripower x (STP XX-50) series and makes them available via MQTT Home Assistant.

I hope that this will make life a little easier for other people.

2 Likes

EDIT: Nevermind, I read wrong, you are talking about the Tripower X, not the SE variant, sorry.

Have you ever tried SBFSpot?

Bimbo009, why this question again? I already answered your question in the other forum.

SBFSpot uses the same technology as SMA-EA. And bluetooth is not supported by my inverter.
Therefore brings no added value.

You don’t need Bluetooth, it also works with Lan. What is AE ?

as you could see from the context, I mean SMA-EM. See Point 1.

Bimbo009, if you don’t understand my post in English as well as in German, then I ask you not to reply to my posts in the future. Thanks.

look here:

Thanks a lot for sharing your efforts, @swante. I’m trying to get a Tripower X to work as well, but only modbus register 30775 appears to work properly.

Does register 30513 for the total energy produced work on your device? Mine does not appear to export that value, and it isn’t specified in the SMA documentation for the new Tripower X devices.

I had no luck with the register either. It is obviously not supported.
My experience is that it is best to forget about all the old Modbus registers. Registers not listed in the Tripower X documentation does not work.

For daily use, you can use the energy function of Home Assistant.
Or use a Utility Meter.

Why don’t you look at the documentation at SMA, everything is available online.
Try SBFSpot.
Try the 30531
If you send me the exact name of your WR I will try to send you the data.

Thought so. I’ll get in touch with SMA and see what they say, maybe they can add more measurements to the modbus in a future firmware update.

A riemann sum and utility meter works, of course, but it’s frustrating to have slightly less accurate data when the original data source is so close.

Hopefully the SMA integration will soon support the new devices.

I did. Both of those are unsupported on the new Sunny Tripower X line of inverters.

Do you have the exact name of the WR.
look over here

hello that’s all here already : MODBUS data from SMA Inverter - #250 by Bimbo009
See the post from March 16, 2023
You can also use SBFSpot, look here: SBFspot Bluetooth homeassistant addon - #220 by HasQT
See the post from Nov 22, it is also from me with the same system with Lan connection.

Again, those are the old modbus registers for SMA Tripower inverters. Mine is the new generation, called Tripower X, which does not support the old modbus registers apart from 30775.

Hello, then get the document for your inverter from SMA then you can change it and the problem is solved.

As both @swante and I pointed out above, those modbus registers simply do not exist on these devices. The entire API has changed.

1 Like

Can you access the WR with the Sunny Explorer and do you have the admin password? then take a look here and see if the Modbus is switched on. I would also recommend not looking here but under SMA Modbus. MODBUS data from SMA Inverter - #249 by wwwebrat

I use this script in a docker container, with great success, to feed my mqtt broker with STP data. Thanx!

1 Like

came across the same issue and pinged the SMA support. Response shared here. TL;DR: stay tuned for Q4/23, more registers are coming.

1 Like

According to a statement in a German forum, the SMA_support has also indicated that Sunspec support will be added.
I can imagine that both changes will then be done together.