-
-
Notifications
You must be signed in to change notification settings - Fork 6
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
tcp: Make firmware strings (in packet suffix) optional #376
tcp: Make firmware strings (in packet suffix) optional #376
Conversation
Multiple of the following reports are going around: Buffer size too small (85 instead of at least 125 bytes) As it turns out these last 40 bytes contain exactly the `firmware` and `firmware_slave` strings, which are not sent by certain 3000TL inverters. Move the fields to a secondary, optional `Structure` to allow these devices to be read out over TCP, and warn when the length of a reply isn't matching one of the known message sizes so that we can potentially discover more different layouts.
Makes `_parse_information_reply()` quite a bit slimmer
4637629
to
7a6168c
Compare
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## main #376 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 6 6
Lines 341 357 +16
Branches 55 57 +2
=========================================
+ Hits 341 357 +16
☔ View full report in Codecov by Sentry. |
There hasn't been any activity on this pull request recently. This pull request has been automatically marked as stale because of that and will be closed if no further activity occurs within 7 days. Thank you for your contributions. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✅ LGTM
Fixes robbinjanssen/home-assistant-omnik-inverter#142, robbinjanssen/home-assistant-omnik-inverter#134 (comment)
Multiple of the following reports are going around:
As it turns out these last 40 bytes contain exactly the
firmware
andfirmware_slave
strings, which are not sent by certain 3000TL inverters. Move the fields to a secondary, optionalStructure
to allow these devices to be read out over TCP, and warn when the length of a reply isn't matching one of the known message sizes so that we can potentially discover more different layouts.