-
Notifications
You must be signed in to change notification settings - Fork 33
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 settings #133
Fix settings #133
Conversation
This "special case" seems erroneous. It breaks autotemp settings page.
Datatype 0x0f is a float from a single raw byte divided by 2. "is_float2"
float8: length "1" (single raw byte) with divider float16: length 2, with divider. float32: length 4, with divider.
This removes This could really use a refactor with a common function to convert raw bytes to int/uint/float. Note that this treats all "floats" as signed raw bytes. I'll add a signed/unsigned to the TODO. |
Looks good and works fine on CVE devices |
Use generic functions to handle datatypes
Unfortunately |
It seems casting "signed" raw bytes (negative values, I'll do a more thorough check tomorrow. |
Signed ints i.e. (0xfffffc18) = -1000 Must be cast from singed ints to float/double: static_cast<double>((int32_t) value);
Add 133 Reserved Add 177 Reserved
79 Blocking time heating to cooling 80 Blocking time cooling to heating 81 Min outdoor temp to change to cooling 82 Command test heating cooling
This seems to work, finally. I added autotemp settings for fw12. but I have fw10... So that is untested. The settings are very desireable however, so I asked on Tweakers forum if someone has a fw12 autotemp. |
Great work, thanks! |
Yes... painful work. Please don't tell me there is some kind of automation for this. |
The WPU 5G v37 has 237 setting values. Hence, the index must be uint8_t not int8_t
Argh... Setting 179 on WPU is datatype Some more work to do... |
4 raw itho bytes are casted into an int64 to preserve sign and prevent overflows.
I seem to have catched and fixed the remaining overflow errors. I merged this into the latest |
int64_t cast_raw_bytes_to_int
Hi @tomkooij can you share a bin file that I can test? On version |
Thanks a lot! I’ll pull in this PR and test it somewhere after this weekend. |
Beta4 does not include this PR, will be in beta5 somewhere next week |
This seems to work on my CVE and DemandFlow devices correctly, thanks for all the work! |
This tries to fix the settings pages for non-CVE devices
(Hopefully CVE devices as well, but I cannot test on CVE devices)
TODO:
0x01
0x0f
(Float divider 2).Fixes #129
Fixes #126
Fixes #119