Table Of Content

Plugin teleinfo

Purpose

Teleinformation is a protocol used by a French power provider. The electric meter sends informations on a special bus.

With some custom PCB, you can read these informations and keep/log/study your power consumption.

Models supported by this plugin :

Others modem could be supported by plugin. Feel free to test them with this plugin and report us :)

Interesting links about teleinfo :

Dependencies

  • Python dependancy : pyserial

Plugin configuration

There is no global configuration options for this plugin.

Plug the teleinfo module to the electric meter

Example with the Dauguet Usb Model

First, you should have an electric meter like this one:

_images/compteur.jpg

Open the bottom part (be careful, if there is a metallic security to prevoid opening, you may be looking for the wrong thing!!) of the electric meter. On the right, you should see __I1__ and __I2__ : it is there you should plug the teleinfo modem. On this photo, there are both a teleinfo modem and a heating programmer pluged:

_images/compteur_zoom.jpg

Here is the Usb teleinfo modem : on the left, the usb plug, on the right, the 2 wires that are plugged on I1 and I2:

_images/teleinfo_modem.jpg

Create an udev rule

You may create a udev rule for this device. You can find sample udev rules in the udev/ folder of this plugin.

You just need to copy the choosen sample file in the folder /etc/udev/rules.d/ and unplug/plug the device.

Check the device under Linux

Setup the connection according to the Teleinfo specifications :

$ stty -F /dev/teleinfo 1200 sane evenp parenb cs7 -crtscts

Display the data flow

$ cat /dev/teleinfo
ADCO 012345678901 =
OPTARIF HC.. <
ISOUSC 60 <
HCHC 009205446 $
HCHP 011101473 %
PTEC HP..
IINST 002 Y
IMAX 047 J
PAPP 00520 (
HHPHC D /
MOTDETAT 000000 B
...

Create the domogik devices

Domogik device type : teleinfo.electric_meter

2 parameters are needed for a domogik device creation:

Key Type Description
device string The teleinformation module device path (ex : /dev/teleinfo for an usb model).
interval number The time in seconds between each check.

Note

You can find more informations about each sensors in the description of the teleinformation frame.

Start the plugin

You can now start the plugin (start button) and use the created domogik devices.

Technical documentation

Timeout on sensors

As all keys are not always returned by the teleinformation, a timeout has been defined only on the sensor for ADCO frame. This timeout has been set to 3 minutes. All other sensors timeouts are set to 0.

xPL schema

Two new xPL schema have been defined for this plugin:

  • teleinfo.basic
  • teleinfo.short

teleinfo.basic

xpl-trig

There is no xpl-trig message for this schema

xpl-cmnd

There is no xpl-trig message for this schema

xpl-stat

Note

You will find more informations about the schema keys in the description of the teleinformation frame.

This is the classic message. Notice that the device identifier corresponds to the ADCO field:

teleinfo.basic
{
adco=...
optarif=...
isousc=...
base=...
iinst=...
imax=...
motdetat=...
[hchc=...]
[hchp=...]
[ejphn=...]
[ejphpm=...]
[bbrhcjb=...]
[bbrhpjb=...]
[bbrhcjw=...]
[bbrhpjw=...]
[bbrhcjr=...]
[bbrhpjr=...]
[pejp=...]
[ptec=...]
[demain=...]
[adps=...]
[papp=...]
[hhphc=...]
[ppot=...]
[iinst1=...]
[iinst2=...]
[iinst3=...]
[imax1=...]
[imax2=...]
[imax3=...]
[pmax=...]
}

teleinfo.short

The teleinfo.short schema is sent when the max intensity is reached on a 3 phasis installation.

xpl-trig

There is no xpl-trig message for this schema

xpl-cmnd

There is no xpl-trig message for this schema

xpl-stat

This is the message sent when for a 3 phasis installation, the max intensity is reached. Notice that the device identifier corresponds to the ADCO field:

teleinfo.short
{
adco=...
adir1=...
adir2=...
adir3=...
iinst1=...
iinst2=...
iinst3=...
}

Teleinfo informations

Teleinformation data explanation

You can find official ERDF informations here : http://www.erdf.fr/sites/default/files/ERDF-NOI-CPT_02E.pdf

Tag Format Description
ADCO 12 car. Electric meter address
OPTARIF 4 car. Tariff option
ISOUSC 2 car. unit = ampere Power subscribed
BASE 9 car. unit = Wh Base option index
HCHC 9 car. unit = Wh Peak hours index
HCHP 9 car. unit = Wh Off peak hours index
EJP HN 9 car. unit = Wh Normal hours index if option = EJP
EJP HPM 9 car. unit = Wh Peak hours index if option = EJP
PEJP 2 car. EJP notice (30 minutes before the period) if option = EJP
BBR HC JB 9 car. unit = Wh Off peak hours index for blue days if option = tempo
BBR HP JB 9 car. unit = Wh Peak hours index for blue days if option = tempo
BBR HC JW 9 car. unit = Wh Off peak hours index for white days if option = tempo
BBR HP JW 9 car. unit = Wh Peak hours index for white days if option = tempo
BBR HC JR 9 car. unit = Wh Off peak hours index for red days if option = tempo
BBR HP JR 9 car. unit = Wh Peak hours index for red days if option = tempo
PTEC 4 car. Current tariff period
DEMAIN   Tomorrow color if option = tempo
IINST 3 car. unit = A Instant power
ADPS 3 car. unit = A Warning when the subscribed poower is reached (emmitted only when needed)
IMAX 3 car. unit = A Maximum power
PAPP 5 car. unit = VA Apparent power
HHPHC 1 car. Hourly group
MOTDETAT 6 car. Counter status

Three phase specific data

If you have a 3-phase install, you will have more informations:

  • iinst1, iinst2,iinst3 instead of iinst
  • imax1, imax2, imax3 instaed of imax

If you use more power than provided on one phase, the information sent by teleinfo will change, and you will receive message using the schema teleinfo.short with only a few informations :

  • ADIR1, ADIR2, ADIR3 : intensity overload on each phase
  • IINST1, IINST2, IINST3 : intensity on each phase.

Changelog

1.1

  • Improve logs for UTF8 (minor update)

1.0

  • Adapt the plugin to Domogik 0.4

0.1

  • Plugin creation