-
Notifications
You must be signed in to change notification settings - Fork 14
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
When using quadratic output correction the light dims before fading #13
Comments
My current thoughts on this: self.__val_act_i[i] is the "output corrected" value. (see line 138) What do you think? |
What do you mean? The lib already does smooth dimming regardless of the channel width which represents the capability of the connected device.
I've pushed a new version. Could you test it, please? |
Thanks for that. the dimming is now working correctly. With Quadratic correction, this drives the output to be greater than 65,535 (0xFFFF). Causing the DMX outputs to go back to 0000 The fix I have tested (for Quadratic): dmx_channel.pi line 13: also: class DmxChannel16Bit(DmxChannel): class DmxChannel24Bit(DmxChannel): class DmxChannel32Bit(DmxChannel): also for safety in output_correction.py: def quadratic(val: float, max_val: int = 256 * 256 - 1): def cubic(val: float, max_val: int = 256 * 256 * 256 - 1): def quadruple(val: float, max_val: int = 256 * 256 * 256 * 256 - 1): |
Thanks for your feedback! I made more changes and pushed them again. |
That looks good. I tested all the output correction modes and they work correctly. Thanks. |
I just wanted to wait for your feedback - I'll push it now. |
Hi,
Thanks for the great Library, I am using it to add DMX onto Home assistant, incorporating the new Color Mode and using the 16 bit for smooth dimming at low level.
When using any output_correction other than linear. When a Fade starts, it will use the corrected value to start the fade then apply the correction again so the start of the fade is a lot lower value than the previous DMX value.
step to reproduce:
Expected behavior light should fade from DMX value 64 to 155
impact: when fading up or down from a mid brightness the light dims significantly then fades to the correct value.
I have been looking at the code to see if there is an easy way to fix it but I'm still finding my way around it. If I find a solution I will let you know.
The text was updated successfully, but these errors were encountered: