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

(Un)Escaped SYN/ESC in master telegram #33

Closed
torsten-rupp opened this issue Jan 8, 2025 · 2 comments
Closed

(Un)Escaped SYN/ESC in master telegram #33

torsten-rupp opened this issue Jan 8, 2025 · 2 comments
Assignees
Labels

Comments

@torsten-rupp
Copy link

I noticed that with v1.1.9 AA and A9 data bytes in the master telegram are not escaped anymore. The change log entry for this is:

Remove escaping (0xAA and 0xA) master data bytes and master CRC on function EBusCommandUtils.buildPartMasterTelegram

Unfortunately this seems not to work with the Wolf BWS-06 I have. For the telegram (get number of burner starts):

FF -> 08: 5022 03 AA 26 02

I see in the dump of the eBus communication something like this:

ff 08 50 22 03 aa 26 02 6d

The aa is not escaped and this terminates the telegram early. There is no response from the BWS-06 device.

Sending a telegram in the openHab shell with AA does also not work:

openhab:ebus send "FF 08 50 22 03 AA 26 02"
The send telegram is invalid! Received SYN byte while receiving telegram! [ERROR: INVALID_SYN, DATA: FF 08 50 22 03 AA]

But sending the telegram with the escaped AA works:

openhab:ebus send "FF 08 50 22 03 A9 01 26 02"

I get this

openhab> openhab:ebus send "FF 08 50 22 03 A9 01 26 02"                                                                                                
Send telegram with id 1949926280, waiting for response ...
openhab> Status    : Successful send 1949926280                                                                                                        
Command ID: cgb2.boiler.starts:GET
Telegram  : FF 08 50 22 03 AA 26 02 A5 00 02 3B 90 C5 00

Received values:
 starts: 36923

The dump of the eBus communication for this is:

ff 08 50 22 03 a9 01 26 02 a5 00   02  3b 90 c5 00
                                                       ^  response

For a test I changed the code in buildPartMasterTelegram() to escape AA/A9 again and then the telegram for getting the number of boiler starts work again.

I do not know if there are eBus devices which really expect plain AA as data bytes. This would IMHO violate the eBus protocol specification, because AA is the synchronization byte which mark the state "bus is free". If a AA is send as a data byte any eBus controller may acquire the bus and start to send another telegram.

May it be possible to add a configuration switch for either enabling escaping of the data bytes in the master telegram or do not escaping? Then the end user may configure that as needed for his system.

Thank you for your great work on this eBus driver!

@csowada csowada self-assigned this Jan 28, 2025
@csowada csowada added the bug label Jan 28, 2025
@csowada csowada linked a pull request Jan 28, 2025 that will close this issue
@csowada csowada removed a link to a pull request Jan 29, 2025
@csowada
Copy link
Owner

csowada commented Jan 29, 2025

Should be fixed with Release v1.1.12

@csowada csowada closed this as completed Jan 29, 2025
@torsten-rupp
Copy link
Author

torsten-rupp commented Feb 2, 2025

Thank you. The problem is that the last OH3 release of the binding (v3.4.16) is based on ebus core v1.1.11.

It seems all releases are still based on ebus core v1.1.11?

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

No branches or pull requests

2 participants