Sorry, your browser does not support JavaScript!

Summary:how to use IAMMETER`s Wi-Fi energy meter in the Home assistant

This is a summary article that includes two parts.

  • Four methods that can integrate the Wi-Fi energy meter (@IAMMETER) into the Home assistant.
  • Some application notes about how to use IAMMETER`s energy meter in the Home Assistant.

how to integrate the IAMMETER`s Wi-Fi energy meter into Home assistant

integration method interface refresh period
1 Core integration HTTP 1 min
2 Modbus/TCP sensor Modbus/TCP 1 s
3 MQTT sensor MQTT 12 s
4 HACS HTTP or Modbus/TCP 1 min(http),1s(Modbus/TCP)

Core integration in home assistant

This is the first integration method that IAMMETER supported and has already been merged into the core of Home Assistant.

IAMMETER energy meter @ Home Assistant

Advantage & Disadvantage

Advantage:

  • Easy to use,support by the core of Home Assistant
  • Compatible with the IAMMETER system. If you like, you can use the Home Assistant and IAMMETER system at the same time.(of course, you can also just use Home assistant only).

Disadvantage:

Because it is very hard to merge new code in Home assistant core now(or maybe we still have not found a proper method), so many new features can not be used directly (such as device discovery, energy management component etc).

Tutorials & Video

how to integrate IAMMETER`s energy meter into Home assistant

how to integrate the Wi-Fi energy meter into home assistant

Modbus/TCP sensor

This is the best options if you want to refresh the energy meter`s reading (up to 1s/s) quickly in the home assistant. The support of high sample rate makes it can be used as the sensor value in some control loop.

modbus/tcp.Yaml in Home Assistant

Advantage & Disadvantage

Advantage

  • Support the sample rate of 1s/s(the highest sample rate in all four method).
  • Compatible with the IAMMETER system, you can decide whether to use home assistant only or use home assistant and IAMMETER system at the same time (The same as the core integration mode).

Disadvantage:

  • Only support one client to poll the data.

Tutorials & Video

Request the Wi-Fi energy meter from the Modbus TCP sensor in Home Assistant

Video tutorials:how to integrate the Wi-Fi power meter into home assistant by modbu/tcp

MQTT Sensor

It is a very common mode that integrates the device into the Home Assistant by MQTT.

The Wi-Fi energy meter of IAMMETER supports the MQTT uploading, with user/PWD authentication mode.

mqtt_IAMMETER_home assistant

Advantage & Disadvantage

Advantage

  • You can subscribe to the reading of the energy meter easily from more than one client, the client`s quantity is only restricted by the setting of the MQTT broker. (compared with the Modbus/TCP mode , which recommends requesting the data only from one client).

Disadvantage:

  • This is different from the first two modes, If you use MQTT mode to integrate the energy meter into Home Assistant, it will not able to upload the data to the IAMMETER system anymore.

Tutorials & Video

Set the username and pwd of the MQTT ,connect the energy meter to the Home Assistant

Video tutorial:Integrate the wifi energy meter into Home assistant by MQTT mode

HACS (custom_integrations)

Because it is difficult to upgrade the IAMMETER`s integration in the core of Home assistant now, we provide a custom component about IAMMETER in HACS.

IAMMETER@HACS by HTTP

Video tutorial: IAMMETER@HACS by HTTP

Request the energy meter`s data from modbus/tcp in HACS

Video:Request the energy meter`s data from modbus/tcp in HACS

Monitor the solar PV system in home assistant

This article provide two methods to display the dashboard, use the lovelace dashboard or use the energy management component.

Monitor your solar PV system in the home assistant

Monitor your solar pv system in the home assistant

Control the relay by the real-time reading of the energy meter

The basic wiring,include wifi energy meter(sensor), sonoff smart socket(Actuator),load,

Because of the high sample rate (1s/s) that supported in the modbus/tcp integration mode, there are many interesting function can be achieved. This app note show how to read the active power of the energy meter each 1 second and use this value to control the relay in home assistant.

Do a realtime control loop in the home assistant,use the reading of modbus tcp sensor to control the sonoff output.

Home Assistant`s Dashboard effect of this experiment

Top