Open SpikedCola opened 4 years ago
I believe that code was commented out when I was using it in a project for APA102 and had some issue with building the lib code on my pi. It was easier to just comment out than fix the compile. This was just a dump of the source code at that point in time and could probably use some love to get it into a more documented and friendly state.
I can confirm the code for WS2811 absolutely worked so you should be able to get it working again fairly easily.
I'm not actively developing on this at the moment, but I'm still here to answer any questions. If you get it working again I'd welcome a PR :)
Hey Grant,
Thanks for taking the time to reply.
Unfortunately I didn't understand what I was getting myself into with this codebase. I've spent a few hours trying to learn what is going on, and get it to compile, but I'm stuck at a linker error (I'm by no means a C++ programmer). It seems some part of the compiling/linking process can't find the ws2811 library:
/usr/bin/ld: CMakeFiles/e131bridge.dir/src/WS2811Strip.cpp.o: in function WS2811Strip::WS2811Strip(YAML::Node&)': /home/jordan/raspberrypi-e131-led/src/WS2811Strip.cpp:7: undefined reference to
ws2811_init'
/usr/bin/ld: /home/jordan/raspberrypi-e131-led/src/WS2811Strip.cpp:8: undefined reference to `ws2811_get_return_t_str'
At this point I think I'm just going to give up... There are yaml config options in the source that don't exist in the config file (eg. strip_channel, invert). Perhaps it works with APA102, but WS2811 needs more love than I am capable of giving.
EDIT Finally found a reference to the ws2811 lib, commented out in CMakeLists.txt
. Glad I'm not going crazy!
Spent a bit more time on this after figuring out the library issue, and I seem to have run into an issue you've also run into: the call to ws2811_render() seems to hang. As you say, _init returns successfully, but _render hangs its respective thread. I noticed you closed the issue on rpi_ws281x - did you ever figure out what was causing this? Or is this what drove you to APA102?
If I remember correctly it was a stupid error and I wasn't initializing the struct properly I think. I forgot about that until you mentioned it.
I had this as private, but I just opened it. Feel free to look at this repo. https://github.com/grantHarris/NZR-e131. The ws2811 issue was fixed. This repo was a fork with some recording and playback functionality implemented. I just merged the branch it was on into master.
The reason I was using APA102 was because it was a project which required really small LED's: DotStar Micro LEDs (APA102–2020)
Thanks, that's excellent! I ended up getting WS2811 working, so it will be interesting to compare with what you did in NZR-e131. Will send over a PR soon-ish.
Hi there,
This project exactly what I've been looking for. Got it to build on my Raspberry Pi Model A (running raspbian buster), but I'm not getting any output. This is my config.yaml file:
Here is the log of e131bridge starting and running (note I changed multicast ip setup from wlan0 to eth0):
When I start Jinx, I do see packets being received, but there is no activity on the strip:
If I run 'strandtest.py' from
rpi-ws281x/python/examples
, with the following config, the strip works as expected:I've also noticed that CTRL+C has no effect on e131bridge - I have to
kill -9
it to make it stop.When I started looking for why the pixels may not be lighting up, I noticed that all of
WS2811Strip.cpp
andWS2811Strip.h
are commented out. Only APA102 looks normal.Perhaps you can offer some insight here. Really looking forward to getting e1.31->ws281x working!
Note: I needed to do the following in order to build:
apt install cmake libyaml-cpp0.6 libyaml-cpp-dev libboost-all-dev
(note: cmake must be > 3.10, this required an update from stretch to buster)