sberthelot / teleinfo-home-assistant Goto Github PK
View Code? Open in Web Editor NEWFrench TIC/Teleinfo integration for Home Assistant (needs a serial dongle/interface)
License: MIT License
French TIC/Teleinfo integration for Home Assistant (needs a serial dongle/interface)
License: MIT License
Just reinstalled a fresh HA and tried this extension with no success:
Despite the modification on configuration (see here after remarks) the extension does not start
WARNING (MainThread) [homeassistant.bootstrap] Waiting on integrations to complete setup: sensor.enedis
2022-10-15 19:40:22.388 WARNING (MainThread) [homeassistant.components.sensor] Timed out adding entities for domain sensor with platform enedis after 500s
2022-10-15 19:40:22.429 ERROR (MainThread) [homeassistant.helpers.event] Error while processing template: Template("{{ states.sensor.enedis_teleinfo.attributes["PRM"] }}")
Traceback (most recent call last):
File "/srv/homeassistant/lib/python3.9/site-packages/homeassistant/helpers/template.py", line 420, in async_render
render_result = _render_with_context(self.template, compiled, **kwargs)
File "/srv/homeassistant/lib/python3.9/site-packages/homeassistant/helpers/template.py", line 1915, in _render_with_context
return template.render(**kwargs)
File "/srv/homeassistant/lib/python3.9/site-packages/jinja2/environment.py", line 1301, in render
self.environment.handle_exception()
File "/srv/homeassistant/lib/python3.9/site-packages/jinja2/environment.py", line 936, in handle_exception
raise rewrite_traceback_stack(source=source)
File "<template>", line 1, in top-level template code
File "/srv/homeassistant/lib/python3.9/site-packages/jinja2/sandbox.py", line 303, in getitem
Note that documentation should be updated:
It is in fact possible to get Linky information without using any extension by simply using HA templating.
# add following line within your configuration.yaml
# reference: https://www.enedis.fr/media/2035/download
sensor:
- platform: serial
name: Enedis
serial_port: /dev/ttyAMA0
baudrate: 9600
parity: E
bytesize: 7
value_template: >-
{% set slots = value.split('\t') %}
{{ slots[0] }},{{ slots[1] }}
- platform: template
sensors:
#debug_enedis:
# unique_id: enedis:teleinfo:debug
# friendly_name: "Debug Input"
# icon_template: mdi:current-ac
# device_class: current
# value_template: "{{ states('sensor.enedis') }}"
enedis_watt:
unique_id: enedis:teleinfo:watt
friendly_name: "Conso-VA"
unit_of_measurement: "VA"
icon_template: mdi:current-ac
device_class: current
value_template: >-
{% if states('sensor.enedis').startswith('SINSTS') %}
{{ states('sensor.enedis').split(',')[1] }}
{% else %}
{{ states('sensor.enedis_watt') }}
{% endif %}
enedis_amp:
unique_id: enedis:teleinfo:amp
friendly_name: "Conso-Amp"
unit_of_measurement: "A"
icon_template: mdi:current-ac
device_class: current
value_template: >-
{% if states('sensor.enedis').startswith('IRMS1') %}
{{ states('sensor.enedis').split(',')[1] }}
{% else %}
{{ states('sensor.enedis_amp') }}
{% endif %}
Hello sberthelot,
I am new to HA but come from Domoticz on which I had Teleinfo data from ttyAMA0.
Sorry to open an issue for that: how to integrate your work to HA?
I have a base 6kVA power supply.
Thanks
I placed component into ~/.homeassistant/custom_components/teleinfo. HA see and warn about it at boot time
Aug 05 11:10:40 raspberry systemd[1]: Started Home Assistant.
Aug 05 11:10:43 raspberry hass[1837]: 2022-08-05 11:10:43 WARNING (SyncWorker_0) [homeassistant.loader] We found a custom integration enedis which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
Nevertheless I cannot find it from web integration UI.
Question: how do we configure this componant for HA ?
Merci
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.