Announcement

Collapse
No announcement yet.

Installation and configuration

Collapse
This topic is closed.
X
This is a sticky topic.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Installation and configuration

    DESCRIPTION

    This plugin is designed to work with nearly all Smart Meters with a P1 connection, which is very common in The Netherlands. Smart Meters in other countries have not been tested, Requires a special Serial or USB to P1 (RJ11) cable. Supports all attributes of a DSMR 4 meter and DSMR 5 meter, and most common attributes of older (DSMR 3 and older) meters. Including devices connected to the M-Bus (for instance, Gas) up to 4 devices. Optionally keeps track of hourly, daily, weekly, monthly and/or yearly cumulative values.

    REQUIREMENTS
    • This plugin is for HS4 only. It works with both Windows and Linux versions
    • Windows: .NET Framework 4.7.2 or later
    • Linux: mono 5.18 or later
    • A special Serial or USB to P1 (RJ11) cable (available in several Home Automation web shops), which looks like this:
    Click image for larger version  Name:	smart0.png Views:	170 Size:	383.8 KB ID:	1370856


    INSTALLATION

    There are no additional software requirements. Start by selecting “Add” from the “Plugins” menu:
    Click image for larger version  Name:	smart1.png Views:	156 Size:	69.5 KB ID:	1370857

    Search for “Smart Meter” and click on the “Smart Meter P1” plugin found:
    Click image for larger version  Name:	smart2.png Views:	156 Size:	66.0 KB ID:	1370858

    Click “INSTALL” from the popup shown above, and the plugin will complete the installation:
    Click image for larger version  Name:	smart3.png Views:	156 Size:	72.5 KB ID:	1370859


    CONFIGURATION

    After installation and starting the Plugin, start by adding a new meter. Select “Smart Meter P1” from the “Plugins” menu, and click “Add new meter”.
    • After clicking “CONTINUE” on the intro text, select the connection method. Normally, when the P1 cable is connected to your HS4 machine, select “USB: P1 cable connected to your HomeSeer system”. For network connections, see next chapter.
    • Select the Com Port of the P1 cable. For Windows, when in doubt, open the “Device Manager” and look for “USB Serial Port (COMx)” under “Ports (COM & LPT)”.
    • Select the correct Com Port Attributes. Most modern (DSMR 4 & 5 meters) use 115200 8N1 as settings. Older meters often use 9600 7E1. This can be modified later in the meter settings if required.
    • Give the meter a meaningful name, so you can recognize this later easily. Then name will only be used in the setup.
    • Validate all settings and click “CONFIRM.
    Click image for larger version  Name:	smart4.png Views:	156 Size:	210.8 KB ID:	1370860


    NETWORK SETUP

    When it is not possible to connect the USB P1 cable directly to your HS4 system (due to length limitations), you can use a Serial-to-Network device instead. For instance, a Raspberry Pi (RPi) with ser2net installed. After a default setup of a RPi (please search the Internet for a guide), do the folling:
    • Login to the RPi and execute the following command: sudo apt-get install ser2net
    • Edit the configuration file: sudo nano /etc/ser2net.conf
    • At the bottom of the config file, the configuration must the updated. The P1 cable is usually recognized as /dev/ttyUSB0. Here is an example:
    2000:telnet:600:/dev/ttyUSB0:115200 8DATABITS NONE 1STOPBIT banner
    • Note that the first number (2000) is the port number, save this information together with the IP address of the RPi as we need that information later to configure the plugin.
    • It is recommended to comment out all other config lines by prefixing them with #.
    • Save the config file (Ctrl-X) and press y to save
    Note that newer versions of ser2net (v4 and up) use a yaml configuration file. Here is an example of a ser2net.yaml file:

    Code:
    connection: &con0096
        accepter: tcp,2000
        connector: serialdev,
                  /dev/ttyUSB0,
                  115200n81,local​
    When the RPi configuration is complete, go back to HS4 and select “Smart Meter P1” from the “Plugins” menu, and click “Add new meter”.
    • After clicking “CONTINUE” on the intro text, select the connection method. In this case, select “Network: P1 cable connected to a SerialToEthernet device (ie ser2net on RPi)”
    • Enter the IP address (in either IPv4 or IPv6 format) of the RPi
    • Enter the Port number, as configured in ser2net.conf
    • Give the meter a meaningful name, so you can recognize this later easily. Then name will only be used in the setup.
    • Validate all settings and click “CONFIRM.
    Click image for larger version  Name:	smart5.png Views:	156 Size:	219.2 KB ID:	1370861


    SETTINGS

    Sometimes additional settings are required to setup the meter, or to customize the operation of the plugin. Select “Smart Meter P1” from the “Plugins” menu, and click “Settings”.
    Click image for larger version  Name:	smart6.png Views:	156 Size:	77.8 KB ID:	1370862

    Click the Smart Meter you want to configure. In this case, “Meterkast thuis”:Click image for larger version  Name:	smart7.png Views:	156 Size:	300.2 KB ID:	1370863
    • Enable this meter: allows you to temporarily disable this Smart Meter.
    • Com Port, BaudRate, Data Bits, Parity, Stop Bits: advanced settings; only change when you have issues.
    • In case of a network connected meter: the previous settings would be replaced by IP address and IP port settings.
    • Polling interval: number of seconds that the Smart Meter devices should be updated. DSMR 5 meters can go as low as 1 second, but this will hit your HS4 system quite hard! Older meters are limited to every 10 seconds.
    • Energy logging interval: how often the Energy Database logging/graphing function of HS4 should be updated. Not recommended to set this lower than 300 (5 minutes) to avoid database issues. More energy settings can be found on the HS4 device settings page, see next chapter.
    • Other settings:
    Click image for larger version  Name:	smart8.png Views:	156 Size:	74.4 KB ID:	1370864
    • Hourly, Daily, Weekly, Monthly and/or Yearly total devices can be created by enabling the corresponding options. For every option, a device with 7 features will be created to hold these totals.
    • Debug logging, Log data received and Log To File: only needed to troubleshoot.
    • Delete this meter: delete the configuration of this meter. HS4 devices/features won’t be affected.
    • Delete this meter and all connected devices: delete the configuration of this meter. HS4 devices/features related to this meter will be removed as well.

    ENERGY SETTINGS

    By default, HS4 Energy Database logging/graphing is enabled. You can customize it on the device config page of the main Smart Meter device:

    Click image for larger version  Name:	smart9.png Views:	0 Size:	272.8 KB ID:	1371849

    For “Electricity consumed (Peak)”, “Electricity consumed (Offpeak)”, “Electricity produced (Peak)” and “Electricity produced (Offpeak)”, there are 4 configuration options:
    • Enable Energy logging: to enable or disable Energy logging for the selected device
    • Appliance Type: default is “Meter_Service”. For producing devices, default is “Solar_Panel”.
    • Energy direction: default is “Consumed”. For producing devices, default is “Produced”.
    • Energy Rate: you can overwrite the default HS4 rate (as found in HS4 setup) for each device.
    stefxx
Working...
X