Skip to content

Select a client for data collection

Jan Bouwhuis edited this page May 26, 2022 · 5 revisions

You need to tell Omnik data logger how to process your inverters logging so. Omnik data logger supports multiple methods to collect data. What client you can use depends on the inverter type and the possiblities you have in interception the logger traffic. Older inverters (First generation) not be accessed directly, some newer inverters have a direct interface at port 8899 than can be used. If you registered your inverter at https://www.omnikportal.com in the past, you can grab your actual data via the SolarmanPV API. Today the site https://www.omnikportal.com has been shutdown, but you can still access the data at https://home.solarmanpv.com/.

If your inverter supports polling at port 8899 using tcpclient is the easiest setup without the need of any cloud services. If this option is not available for you can fallback using the solarmanpv client to access Solarman API. This option may be unsure in the future. Since every Omnik inverter also submits updates to 176.58.117.69 (this is fixed behaviour) we could intercept this trafic and listen to the updates using the localproxy client.

So there are two client categories:

  • The client is polling for data. Polling clients are solarmanpv and tcpclient
  • The updates are pushed by the inverter and intercepted using the localproxy client belongs to this category. You could make use of omnikdataloggerproxy to intercept as well.

Polling clients

If you have an Solarman account, you can use the solarmanpv client. Set up requires a username and password. The interval key in the default section has to set. The Omnik portal credentials are probably set during the installation of your inverter when registering your datalogger. If you forgot your password, you can try to reset it at the Solarmanpv portal.

The tcpclient is also polled at a regular interval, but is trying to access your inverter directly. Not all inverter logger modules are compatible with this client. If your datalogger supports direct access this means you can decide your self how often your inverter data is polled. You will get detailed information and still will be able to use Solarmanportal as well. So this client is preferred if this works for you.

tcpclient client

To use the tcpclient client set this as client plugin in the section [plugins]

The plant id section in the configuration is used by Omnik data logger to store inverter serial number, logger serial number, ip address (and pvoutput system_id). Use the plant id from omnik portal or choose one you self and create the section. Make a section for each logger. In the section tcpclient configure the key plant_id_list with a list of all plant id's. The tcpclient will poll the configured plants and only accept data from inverters if the serial number matches the one that is configured for the inverter that is polled.

Example for config.yaml with tcpclient setup:

# The instance name is omnik_datalogger, this can be changed. Multiple instances are supported.
omnik_datalogger:
# General options
  module: omniklogger
  class: HA_OmnikDataLogger
  city: Amsterdam
  interval: 360

# Plugin section
  plugins:
    client: tcpclient

  client.tcpclient:
    plant_id_list:
      - '123'

# Section for your inverters specific settings
  plant.123:
    inverter_address: 192.168.1.1
    logger_sn: 123456789
    inverter_port: 8899
    inverter_sn: NLxxxxxxxxxxxxxx
    sys_id: <YOUR SYSTEM ID>
    http_only: false

The logger_sn will be used to make the request to inverter_address. The inverter_sn will be checked against the serial number of the inverter.


solarmanpv client

To use the solarmanpv client set this as client plugin in the section [plugins] The solarmanpv client needs a username and password, register an account at https://home.solarmanpv.com/login and add your inverter(s).


Processing pushed logging data

When using the command line, you also must set an positive interval or else the client will stop after receiving and processing one data package. The interval time it self is not used. Using AppDaemon setting an interval time is not needed.

The localproxy client can be used to push incoming inverter data to the output plugins without delays. There are three localproxy client plugins that can be used. It is possible to configure all plugins silmultanious, but most of the times you will only use one of the localproxy plugin's.

localproxy client

To use the localproxy client set this as client plugin in the section [plugins].

The tree localproxy client plugins that can be selected are:

  • tcp_proxy: for stand-a-lone data logging without forwarding.
  • mqtt_proxy: logging trigger by MQTT data published by the omnikloggerproxy.py script.
  • hassapi: loggging trigger through Home Assistant using AppDaemon HASSAPI using MQTT data published by the omnikloggerproxy.py script.

Both mqtt_proxy and hassapi require a omnikloggerproxy.py script to be able to intercept the inverters data and forward it to MQTT. The tcp_proxy plugin can accept the inverters messages directly, without using omnikloggerproxy.py. Read more about interception here.

Since interception of the logger data requires Network Address Translation, iptables with root privileges will be needed on the host. When using Omnik data logger with Home Assistant os, this cannot run at the same host. When using omnikloggerproxy.py you can still forward the data to the internet servers of Omnik/Solarman but due to the rerouting challenge you might wat to set up a second instance of omnikloggerproxy.py to do the final forarding, This way you can still make use of https://www.solarmanpv.com/portal. For more information on interception an the Omnik data logger architecture you might want to visit the website. See also the links in the footer.