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

Small number of LEDs don't turn off #184

Open
Adiventure opened this issue May 16, 2018 · 13 comments
Open

Small number of LEDs don't turn off #184

Adiventure opened this issue May 16, 2018 · 13 comments

Comments

@Adiventure
Copy link

I'm not entirely sure whether this is a Prismatik issue, but about 10 contiguous leds are not turning off. Otherwise they behave normally, reacting to color, but they don't go off.

@psieg
Copy link
Owner

psieg commented May 16, 2018

  • Are these the first or last 10 LEDs?
  • Which device?

@Adiventure
Copy link
Author

Adiventure commented May 16, 2018 via email

@dmadison
Copy link

I'm assuming you're using Adalight?

How many LEDs are you running, total? And what is your baud rate?

@Adiventure
Copy link
Author

Adiventure commented May 17, 2018 via email

@dmadison
Copy link

What do you mean "due to only one side measurement"?

Are you using my driver code? If so, what happens if you let the LEDs idle for a minute? Do all of the LEDs turn off then?

@Adiventure
Copy link
Author

Adiventure commented May 17, 2018 via email

@dmadison
Copy link

On idle all other lights go off, but the 10 remain on.

Then it's an issue with your LEDs, power, or wiring.

@Adiventure
Copy link
Author

Adiventure commented May 17, 2018 via email

@dmadison
Copy link

Can you share what the problem was? Is there a bug in the Adalight code, or did you have a typo somewhere?

Re: update rate / baud balancing: higher baud the better until you're device starts showing errors. Lowest grab rate possible until you saturate the bus with data, then your framerate will drop significantly. The equation here is a good place to start. Note that the reported framerate number in Prismatik will fluctuate wildly in the WinAPI mode, as it doesn't generate new frames if the data hasn't changed.

I have not played around with Hyperion, and from what I remember it wasn't really built for capturing directly from a display (though that may have changed). Prismatik has an API and a plugin system, so if you're feeling adventurous you could write a smarthome plugin. Though you'd need to have the PC on for it to work.

@Adiventure
Copy link
Author

Adiventure commented May 17, 2018 via email

@Adiventure
Copy link
Author

Adiventure commented May 17, 2018 via email

@dmadison
Copy link

Yes, the same rate should go in the serial speed in the code as well as in the Prismatik config.

You won't see the drops in the reported framerate from Prismatik. If the delay between frames is less than the LED latch time (~5.6 ms for 186 LEDs) frames will be silently dropped by the Arduino and the displayed framerate, i.e. what is actually being shown on the LEDs, will drop significantly (#117). If the bus is fully saturated, not only will your frames drop, but Prismatik will keep filling the PC-side serial buffer and you'll build up a delay between the rendered frame and when it is displayed on the LEDs. Although to quote Westworld: if you don't notice, does it matter?

There is no solution to either of those issues at the moment, except for being mindful of them and configuring the device properly. This is also why I keep stressing keeping the # of LEDs low, although no one seems to listen 😐. If the dropped frames bother you the easiest thing to do is switch to another LED chipset that doesn't disable interrupts (APA102 e.g.).

@Adiventure
Copy link
Author

If it's just a matter of observed framerate than I simply haven't played with it enough to tell. My debugging on this go around has not involved much observation of the leds as opposed to seeing what showed as values within Prismatik.

LED count is good advice, but it's virtually invisible until one really digs into this project, as with different chipsets. None of the instructables/blogposts/youtube videos mention overdoing it, nor that there's a functional reason to get a different LED set. I chose this one specifically because it was listed as 'one of the good ones' repeatedly. Little did I know XD. I suspect it's one of those things where the jump from casual project to enthusiast/nitty gritty side of it is too big. I'd consider myself reasonably technically competent, and psieg's walkthrough/experience was a bit intimidating.

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

3 participants