Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reading from UART timed out at byte 0! #3

Closed
steeriks opened this issue Dec 16, 2020 · 9 comments
Closed

Reading from UART timed out at byte 0! #3

steeriks opened this issue Dec 16, 2020 · 9 comments

Comments

@steeriks
Copy link

steeriks commented Dec 16, 2020

I am getting this error:

Aidon meter with Rj12 (activated) NodeMcu V3. Wiring as suggested!

[17:31:09][E][uart_esp8266:167]: Reading from UART timed out at byte 0!
[17:31:09][E][uart_esp8266:167]: Reading from UART timed out at byte 0!
[17:31:09][E][uart_esp8266:167]: Reading from UART timed out at byte 0!
[17:31:09][E][uart_esp8266:167]: Reading from UART timed out at byte 0!
[17:31:09][E][uart_esp8266:167]: Reading from UART timed out at byte 0!
[17:31:10][E][uart_esp8266:167]: Reading from UART timed out at byte 0!
[17:31:10][E][uart_esp8266:167]: Reading from UART timed out at byte 0!
[17:31:10][E][uart_esp8266:167]: Reading from UART timed out at byte 0!
[17:31:10][E][uart_esp8266:167]: Reading from UART timed out at byte 0!
[17:31:10][E][uart_esp8266:167]: Reading from UART timed out at byte 0!
[17:31:19][E][uart_esp8266:167]: Reading from UART timed out at byte 0!
[17:31:19][E][uart_esp8266:167]: Reading from UART timed out at byte 0!
[17:31:19][E][uart_esp8266:167]: Reading from UART timed out at byte 0!
[17:31:19][E][uart_esp8266:167]: Reading from UART timed out at byte 0!
[17:31:19][E][uart_esp8266:167]: Reading from UART timed out at byte 0!
[17:31:20][E][uart_esp8266:167]: Reading from UART timed out at byte 0!
[17:31:20][E][uart_esp8266:167]: Reading from UART timed out at byte 0!
[17:31:20][E][uart_esp8266:167]: Reading from UART timed out at byte 0!
[17:31:20][E][uart_esp8266:167]: Reading from UART timed out at byte 0!
[17:31:20][E][uart_esp8266:167]: Reading from UART timed out at byte 0!
[17:31:29][E][uart_esp8266:167]: Reading from UART timed out at byte 0!
[17:31:29][E][uart_esp8266:167]: Reading from UART timed out at byte 0!
[17:31:29][E][uart_esp8266:167]: Reading from UART timed out at byte 0!
[17:31:29][E][uart_esp8266:167]: Reading from UART timed out at byte 0!
[17:31:29][E][uart_esp8266:167]: Reading from UART timed out at byte 0!
[17:31:30][E][uart_esp8266:167]: Reading from UART timed out at byte 0!
[17:31:30][E][uart_esp8266:167]: Reading from UART timed out at byte 0!
[17:31:30][E][uart_esp8266:167]: Reading from UART timed out at byte 0!
[17:31:30][E][uart_esp8266:167]: Reading from UART timed out at byte 0!
[17:31:30][E][uart_esp8266:167]: Reading from UART timed out at byte 0!

@maccan-tech
Copy link
Contributor

maccan-tech commented Jan 1, 2021

Same here.
Tekniskaverken, Aidon 6442SE meter with Rj12 (activated).
Using ESP8266 (wemos d1) and a BC547C.

@forsberg
Copy link
Contributor

Same here, also on Tekniska Verken with Aidon. Reason seems to be that Tekniska verken have adopted "Branschrekommendation 1.2", which is a binary protocol.

Protocol information available here: https://www.tekniskaverken.se/siteassets/tekniska-verken/elnat/aidonfd-rj12-han-interface-se-v13a.cleaned.pdf

Some more information here: https://github.com/aviborg/swedishP1

@pp-svanstrom
Copy link

@forsberg Great find! From version 1.3 of the specification they changed to an ASCII format, which is what my code is expecting. I will take a look at the binary format and see if I can add a field for the user to control which version the meter is using.

@forsberg
Copy link
Contributor

I contacted Tekniska Verken kundsupport, and they are "painfully aware" and are "having a dialouge with their provider" about how to fix this.

I asked them if they have a timeline. Hopefully this will be fixed by itself in a couple of months.

@bortek
Copy link
Contributor

bortek commented Feb 5, 2021

I am also seeing this in my logs sporadically. My mete ris Landis E360. But I have more issue with CRC checksum which I put in a separate issue.

forsberg added a commit to forsberg/esphome-p1reader that referenced this issue Feb 14, 2021
…ges, used by Tekniska Verken meters.

Beginnings of an implementation, lacks CRC checks and handling of escaped HDLC flags inside frame.

See psvanstrom#3.
@forsberg
Copy link
Contributor

I have the beginnings of a fix for this in a branch, but it needs a bit of cleanup - checking CRC and handling HDLC flag bytes inside frame.

Has been running stable for about a week on an Aidon 6442SE from Tekniska Verken, Linköping.

@pp-svanstrom
Copy link

Awesome @forsberg ! You're very welcome to do a PR once you have finished the cleanup, great work 👍

@maccan-tech
Copy link
Contributor

maccan-tech commented Feb 24, 2021

@forsberg Your branch has workt great for me now the past week.
But i get this every time it reads the data. But it works
[10:41:09][D][hdlc:479]: Expect 0x01 (array tag), got 01

@jpduhen
Copy link

jpduhen commented Dec 17, 2021

esphome/issues#815 (comment)
It helped me to reset the MH-Z19B by holdoing the HD 7sec to GND and resetting the ESP. You have to calibrate the MH by keeping it in fresh air for 20 mins.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants