@marieper it’s not possible with esphome. Because DSMR Reader needs or a usb device (that shows the telegrams) or needs a telnet device. Sadly esphome doesn’t support that.
I thought that i read somewere you could flash the “slimmelezer” from Marcel with a other firmware, so it could use telnet. And then use DSMR Reader plugin (https://www.zuidwijk.com/using-esp-link/)
I experience an issue, possibly related to this reported issue.
The quick and dirty solution is to restart the add-on periodically. A small blueprint is a temporary solution:
Bssed on the reported issue i created a new release as stability is essential. @EDouna , can you let me know if the issue is temperarly resolved with this release?
2024-04-17: DSMR Reader Add-on v 1.11.2, DSMR-reader v5.11 Changelog here
I run the latest addon. and when I use ingress link to check dsmr everything went well. If i want to login i got a error.
I use nginx proxy manager to enter my domain: https://domainxxx.nl
Ho can I solve this?
’
Verboden (403)
CSRF-verificatie mislukt. Aanvraag afgebroken.
U ziet deze melding, omdat deze HTTPS-website vereist dat uw webbrowser een ‘Referer header’ meestuurt, maar deze ontbreekt. Deze header is om veiligheidsredenen vereist om er zeker van te zijn dat uw browser niet door derden wordt gekaapt.
Als u ‘Referer’-headers in uw browser hebt uitgeschakeld, schakel deze dan weer in, op zijn minst voor deze website, of voor HTTPS-verbindingen, of voor ‘same-origin’-aanvragen.
Als u de tag gebruikt of de header ‘Referrer-Policy: no-referrer’ opneemt, verwijder deze dan. De CSRF-bescherming vereist de ‘Referer’-header voor strenge referer-controle. Als u bezorgd bent om privacy, gebruik dan alternatieven zoals <a rel=“noreferrer” …> voor koppelingen naar websites van derden.
’
Currently the have a state_class of total_increasing
However, if you read the documentation explaining the differences between the 3 state_classes, it looks like I should be using total instead? Quote:
TOTAL The state represents a total amount that can both increase and decrease, e.g. a net energy meter. Statistics of the accumulated growth or decline of the sensor’s value since it was first added is updated every 5 minutes. This state class should not be used for sensors where the absolute value is interesting instead of the accumulated growth or decline, for example remaining battery capacity or CPU load; in such cases state class measurement should be used instead.| TOTAL_INCREASING Similar to total, with the restriction that the state represents a monotonically increasing positive total which periodically restarts counting from 0, e.g. a daily amount of consumed gas, weekly water consumption or lifetime energy consumption. Statistics of the accumulated growth of the sensor’s value since it was first added is updated every 5 minutes. A decreasing value is interpreted as the start of a new meter cycle or the replacement of the meter.
Reading this it looks like the “_increasing” total has the ability to reset itself to zero
“as start of a new cycle” (which should never happen with an energy meter?)
“which periodically restarts counting from 0” - which you never want from the main energy meter?
“the replacement of a meter”, which hardly ever happens? (and couldn’t that be done with state_class: total?
So the question is: should the main energy meters have state_class TOTAL ?
about three weeks ago all of a sudden the add-on stopped working. I tried a lot already (changing configurations, looking at this forum, reinstall the add-on and integration, use a different P1 cable), but the last message processed is three weeks ago. The error message I get is:
2024-11-12 11:58:43,631 ERROR mixins run_once 107 | dsmr_datalogger.management.commands.dsmr_datalogger: [!] Exception raised. Traceback (most recent call last):
File "/app/dsmr_datalogger/scripts/dsmr_datalogger_api_client.py", line 39, in read_telegram
serial_handle = serial.serial_for_url(
^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/serial/__init__.py", line 90, in serial_for_url
instance.open()
File "/usr/local/lib/python3.11/site-packages/serial/serialposix.py", line 336, in open
self._update_dtr_state()
File "/usr/local/lib/python3.11/site-packages/serial/serialposix.py", line 713, in _update_dtr_state
fcntl.ioctl(self.fd, TIOCMBIS, TIOCM_DTR_str)
OSError: [Errno 5] I/O error
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/app/dsmr_backend/mixins.py", line 96, in run_once
self.run(data=self.data, **options)
File "/app/dsmr_datalogger/management/commands/dsmr_datalogger.py", line 29, in run
telegram = next(self.telegram_generator)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/app/dsmr_datalogger/scripts/dsmr_datalogger_api_client.py", line 43, in read_telegram
raise RuntimeError("Failed to connect: {}", error) from error
RuntimeError: ('Failed to connect: {}', OSError(5, 'I/O error'))
2024-11-12 11:58:43,632 INFO mixins _stop 138 | dsmr_datalogger.management.commands.dsmr_datalogger: Exiting on next run...
Hi Jaap, can you dubbel check the usb port configuration? Sometimes it can happen that the p1 usb reader pops up on a other internal USB bus. Go to settings → System → hardware → All hardware and lookup the correct USB port in the list: