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

Explanation on multiple stripe #371

Open
ScreamZ opened this issue Nov 30, 2023 · 3 comments
Open

Explanation on multiple stripe #371

ScreamZ opened this issue Nov 30, 2023 · 3 comments

Comments

@ScreamZ
Copy link

ScreamZ commented Nov 30, 2023

Hello,

I've read that strip declared together are bound on a board.

What if I do this ?

 const strip1 = new LEDStrip({ board, strips:  [{ pin: 3, length: 196 }], gamma: 2.8 });
 const strip2 = new LEDStrip({ board, strips: [{ pin: 13, length: 12 }], gamma: 2.8 });

Are those strips not supposed to be separated ? It looks like not.
Do i have to rely on custom function to select the 12 last pixels on the second strip when playing with them ?

@ajfisher
Copy link
Owner

ajfisher commented Nov 30, 2023 via email

@ScreamZ
Copy link
Author

ScreamZ commented Nov 30, 2023

I'm working on an escape room project and I have on one board two different strips.

  1. The first one is used to represent a matrix of LEDs with color indicating the riddle to solve. But the room is quite dark, that's why I have a second strip.

  2. The second strip is used with 12 LEDs with maximum white color to power a « Light » that is lighting the panel.


After the first test

I can confirm that strange things happen in this scenario. Like there are side effect when playing with one strip that appears on the other. It's like using the first one impact the secondly declared, but I'm not sure because I quickly switch to some kind of wrapper, that returns function simulating "fake strips" bound to only the LEDs they are supposed to acting on.

Even though this is quite hacky, I think we should imagine some way to design this (even if we use a wrapper) to properly address this.

In my case the first strip is about 196 LEDs, the second about 12. Does the limitation of LEDs apply on both strip total led count of its a per strip limitation. I guess its on a total one isn't ?

@ajfisher
Copy link
Owner

ajfisher commented Dec 1, 2023 via email

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