SolarMax Inverter Integration

I know this is an old thread but I have managed to integrate our older solarmax controller quite easily.

The steps I followed were:
Download the solarmax MaxTalk software from here https://www.solarmax.com/wp-content/uploads/MaxTalk-1.zip

Connect to your Inverters using this software first (you have to configure the IP and serial address on the inverter itself first)

Here I could check they were actually outputting data

The next step is optional and only needed if the config below doesn’t work with your model of SolarMax inverters

Once MaxTalk is getting data from your inverters, download Wire Shark, while running MaxTalk capture the packets using Wire Shark and filter on port 12345

In the data of the packets to the inverter you will find the request string used for the payload in the example below.


sensor:
  - platform: tcp
    scan_interval:
      seconds: 5
    name: solarmax3
    host: 10.129.xxx.xxx
    port: 12345
    payload: '{FB;F8;26|64:KDY;KMT;KT0;KYR;PAC|08D9}'

In the example above F8 in the string is the serial address I set on the inverter (represented in hex)
Because I’m lazy I use this website for my conversions: Hexadecimal to Decimal Converter

I believe 08D9 at the end also has something to do with the address as this changes for each of my inverters. This is shown in the output of the WireShark capture

The above code receives a nice hex string and I break it down into the useful bits using the templates below.


- sensor:
      - name: solar_3_monthly
        device_class: energy
        unit_of_measurement: "kWh"
        state: >
          {{ states('sensor.solarmax3').split(';')[3] | regex_findall_index('\=(.*)') | int(base=16) }}
          
  - sensor:
      - name: solar_3_daily
        device_class: energy
        state_class: total_increasing
        unit_of_measurement: "kWh"
        state: >
          {{ states('sensor.solarmax3').split(';')[2] | regex_findall_index('\=(.*)') | int(base=16) | int / 10 }}
          
  - sensor:
      - name: solar_3_current_w
        device_class: power
        unit_of_measurement: "w"
        state: >
          {{ states('sensor.solarmax3').split(';')[6] | regex_findall_index('(?<=\=)(.*?)(?=\|)') | int(base=16) | int / 2 | int }}

I hope the above helps someone figure out theirs as there is nothing more annoying than not having it in Home Assistant :slight_smile:

4 Likes