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

Lights flickering #7

Open
icky7s opened this issue Oct 4, 2020 · 3 comments
Open

Lights flickering #7

icky7s opened this issue Oct 4, 2020 · 3 comments

Comments

@icky7s
Copy link

icky7s commented Oct 4, 2020

I noticed my lights flicker/flash to white before setting the color.
I'm wondering if this is an issue with my lights or something else?
Code that causes issues:

await lights.setColorAsync(255, 0, 0); // all colors cause flashes
@icky7s
Copy link
Author

icky7s commented Oct 4, 2020

I fixed the flickering by modifying the SetColorAsync method, changed

if (Protocol == LedProtocol.LEDENET) 
    await SendDataAsync(0x41, color.Red, color.Green, color.Blue, 0x00, 0x00, 0x0f);
else
    await SendDataAsync(0x56, color.Red, color.Green, color.Blue, 0xaa);

to

await SendDataAsync(0x31, color.Red, color.Green, color.Blue, 0x00, 0x00, 0x0f); // stolen from a nodejs module that didn't cause flickering

@icky7s icky7s closed this as completed Oct 4, 2020
@nathanielxd nathanielxd reopened this Oct 9, 2020
@nathanielxd
Copy link
Owner

Hello! Can you tell me what kind of led strip are you using so I can fix this problem? Thanks.

@icky7s
Copy link
Author

icky7s commented Oct 9, 2020

I am using these https://www.amazon.com/gp/product/B07HD1CS45

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

No branches or pull requests

2 participants