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

Neopixel control apparently not working #140

Closed
gertorro opened this issue May 12, 2018 · 5 comments
Closed

Neopixel control apparently not working #140

gertorro opened this issue May 12, 2018 · 5 comments
Labels

Comments

@gertorro
Copy link

Hi there,
I'm having a rare issue with the enclosure pluging and a strip of neopixel LEDs.
Say I configure GPIO 4 as output (simple toggle on off), with that, I'm able to control pin 7 with no issues.
Then, I erase that configuration and put instead a Neopixel output on the same physical output and it does nothing when I send a sample color to show.
Any clue why this might be happening? I have attached the configuration just in case it gives you a hint.
Thanks in advance,
Germán

image

image

@vitormhenrique
Copy link
Owner

Yes, I know exactly what is going on, I think I did not fully document on the read-me how to get it working.
You need to use hardware capable PWM pins, and also install some libraries.
Follow this guide install everything and get it working, after that, it should work on the same pin that you configured following the guide.

@gertorro
Copy link
Author

Thanks for the fast response Victor
everything seems OK with the instructions until I arrive to this command:

pi@octopi:~/rpi_ws281x/python $ sudo python setup.py install Extracting in /tmp/tmpoF9Z2J Traceback (most recent call last): File "setup.py", line 4, in <module> use_setuptools() File "/home/pi/rpi_ws281x/python/ez_setup.py", line 145, in use_setuptools return _do_download(version, download_base, to_dir, download_delay) File "/home/pi/rpi_ws281x/python/ez_setup.py", line 120, in _do_download _build_egg(egg, archive, to_dir) File "/home/pi/rpi_ws281x/python/ez_setup.py", line 62, in _build_egg with archive_context(archive_filename): File "/usr/lib/python2.7/contextlib.py", line 17, in __enter__ return self.gen.next() File "/home/pi/rpi_ws281x/python/ez_setup.py", line 100, in archive_context with ContextualZipFile(filename) as archive: File "/home/pi/rpi_ws281x/python/ez_setup.py", line 88, in __new__ return zipfile.ZipFile(*args, **kwargs) File "/usr/lib/python2.7/zipfile.py", line 770, in __init__ self._RealGetContents() File "/usr/lib/python2.7/zipfile.py", line 811, in _RealGetContents raise BadZipfile, "File is not a zip file" zipfile.BadZipfile: File is not a zip file

Any clue on that error? Google wasn't useful this time around.
Thanks again!
Germán

@vitormhenrique
Copy link
Owner

Not really sure, you need to get those libraries installed before getting neopixel to work, post an issue on rpi_ws281x github, they could help you out... https://github.com/jgarff/rpi_ws281x, also try to find other tutorials on installing rpi_ws281x.

@gertorro
Copy link
Author

gertorro commented May 13, 2018

Hello Victor, in the issues from the WS281X library appears the solution,
apparently the source that hosts the setuptools... file is corrupted.
After deleting it manually and downloading it again from the official python servers it runs like a charm.
I leave you the source of the fix: jgarff/rpi_ws281x#290
so you can implement the automatic installation out of the box.
Thanks for the support, I personally think your work is of great value for those with 3D printers! Keep it up!
Regards,
Germán

@vitormhenrique
Copy link
Owner

No problem! glad it work out for you!
I had problems trying to install automatically the requirements of this plugin using octoprint pip, I'll try to get this working for following releases.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants