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

ld2420: fix energy mode documentation #6225

Merged
merged 1 commit into from Mar 18, 2024

Conversation

andresv
Copy link
Contributor

@andresv andresv commented Feb 14, 2024

What does this implement/fix?

LD2420 energy output mode documentation was incorrect. In energy output mode it returns:

presence: bool
distance: u16
energies: [u16; 16]

Also length was wrong in the example. Correct is 23 00 instead of 00 23.

Here can be seen that parser also already expects energies right after distance field: https://github.com/esphome/esphome/blob/dev/esphome/components/ld2420/ld2420.cpp#L351-L354.

Types of changes

  • Bugfix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Other

@probot-esphome
Copy link

Hey there @descipher, mind taking a look at this pull request as it has been labeled with an integration (ld2420) you are listed as a code owner for? Thanks!
(message by CodeOwnersMention)

@codecov-commenter
Copy link

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (7baf091) 53.71% compared to head (ac5baab) 53.71%.

Additional details and impacted files
@@           Coverage Diff           @@
##              dev    #6225   +/-   ##
=======================================
  Coverage   53.71%   53.71%           
=======================================
  Files          50       50           
  Lines        9404     9404           
  Branches     1653     1653           
=======================================
  Hits         5051     5051           
  Misses       4055     4055           
  Partials      298      298           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@descipher
Copy link
Contributor

Thanks for catching the error, I have a PR in to do a workaround at the moment #6168 If you could do review comment there we can get it done faster that way.

@jesserockz jesserockz merged commit f569573 into esphome:dev Mar 18, 2024
57 checks passed
@github-actions github-actions bot locked and limited conversation to collaborators Mar 20, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants