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

fix(x1_boost): totals are consecutive u16 ints #129

Merged
merged 7 commits into from
Feb 11, 2024

Conversation

kalosisz
Copy link
Contributor

Total values are two consecutive unsigned 16bit integers for X1 Boost inverter.

@kalosisz
Copy link
Contributor Author

hey @squishykid, the values for the test case are from our X1 Boost inverter. We have been using the Solax plugin in HomeAssistant, but unfortunatelly, some of the values are wrong.

Copy link
Owner

@squishykid squishykid left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great. One change with your tests though: could you please add another set of expected values, rather than modifying the existing set of expected values?

The existing set of expected values is output from a known inverter, and we want that to continue working. So your new values and the existing values should coesist

@kalosisz kalosisz requested a review from squishykid February 10, 2024 21:42
@kalosisz
Copy link
Contributor Author

I've added the new text case for the overflown case.

Copy link
Owner

@squishykid squishykid left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking right on track! You just need to reference your new test values in ‘fixtures.py’, so the tests run with your new values in addition to all of the existing values.

@squishykid
Copy link
Owner

squishykid commented Feb 11, 2024

Do this by adding another ‘ InverterUnderTest’ in fixtures.py, referencing your new test values

@kalosisz
Copy link
Contributor Author

I should've checked! Fixture added.

@squishykid
Copy link
Owner

Nice work!

@squishykid squishykid merged commit ce0732f into squishykid:master Feb 11, 2024
3 checks passed
@kalosisz
Copy link
Contributor Author

Thanks! How do new versions get released? I'd need this fix for updating the deps in here.

@dooblem
Copy link

dooblem commented Feb 12, 2024

Hello thanks guys. Just tested with the very last git version today.

I don't know if this is the right place to post.
My X1 Boost G3 is detected as "X1MiniV34". Is it OK ?
When removing X1MiniV34 from discovery.py, still not detected as X1 Boost.

I'm still getting some data though. From first look the data seems OK.

@Elliottmonaghan
Copy link

Hello thanks guys. Just tested with the very last git version today.

I don't know if this is the right place to post.

My X1 Boost G3 is detected as "X1MiniV34". Is it OK ?

When removing X1MiniV34 from discovery.py, still not detected as X1 Boost.

I'm still getting some data though. From first look the data seems OK.

This is what I have experienced also. The values mostly line up but the exported power/power now values are not lined up so will not work, also the x1 boost Gen 3 uses a pack_u16 to combine a few values so some of the total values will be off. I have changed this manually on the x1 mini v34 file and got it reporting correct values but haven't delved into it on how to get it to register as an x1 boost on initial discovery.

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

Successfully merging this pull request may close these issues.

4 participants