-
-
Notifications
You must be signed in to change notification settings - Fork 40
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
Two LED strip on RPI 4 #40
Comments
Update: BR |
Hi If a command is sent via TCP for the first strip, and shortly afterwards a command for the second, both processes are aborted. Is it possible to run two strips independently of each other? BR |
Sorry, not possible to do this unless you can combine commands for strip 1 and 2 in the same loop/thread. Try running 2 servers on different ports. |
Ok, tried running with two servers. In summary, the following can be said. The first instance of the server is set up and initialized on channel 1 with PWM0 with the pin used for LED strip 1. TCP port 9999. The second instance of the server is set and initialized on channel 1 with PWM0 and a UNUSED pin and on channel 2 with PWM1 and the pin used for LED strip 2. TCP port 9998. Channel 1 cannot be used together with PWM1 since an error during setup is thrown by the server. So I had to setup an "unused" channel 1 with an unused pin on this second server. If messages are now sent one after the other, Strip 1 and Strip 2 will work properly. However, if the processes run parallel, the LEDs of both strips light up, but they influence each other. So it does not work just like that. Could this be because both servers or the rpi_ws281x library use the same DMA channel? Maybe you have to assign different DMA channels to each server? Thank you for your support. |
Update: At https://github.com/jgarff/rpi_ws281x it can be found, that DMA 5 should not be used. |
You forgot the first argument of the init command is the operating frequency. but I've changed the default DMA number to 10 anyway in the source code. |
Hi
Thank you for your WS2812 server.
I tried your it with two LED strips. It worked from the beginning very nice with only one strip.
Then I connected a second, which is not working.
For the first, the setup is:
setup 1,256,3,0,255,18; init;
Using the second, the setup is:
setup 1,256,3,0,255,18; setup 2,60,3,0,255,13; init;
The first one uses PWM0, the second PWM1 (I guess). So in theory two strips can be connected.
Before going into details I'd like to know if I'm doing something fundamentally wrong.
Do you prefer another channel to ask such basic questions?
BR
Wym
The text was updated successfully, but these errors were encountered: