Giter Site home page Giter Site logo

Animation Color Error about pixelpi HOT 3 CLOSED

Jokelo avatar Jokelo commented on August 12, 2024
Animation Color Error

from pixelpi.

Comments (3)

derblub avatar derblub commented on August 12, 2024

Looks like a wrong wiring to me - check your joints.

from pixelpi.

marian42 avatar marian42 commented on August 12, 2024

I don't have an idea what it could be. It seems that the green color channel gets through correctly. That suggests that it's working on the software side and there is a hardware issue.

The WS281x library has an invert option, although on the photo it doesn't quite look like it's inverted.
It would also be interesting to know what you see with the stdrandtest.py that is provided with the WS2812 library.

Sorry I'm not being super helpful... I think your best bet is asking on the Raspberry Pi Forum. I hope you get it resolved!

from pixelpi.

Jokelo avatar Jokelo commented on August 12, 2024

Thanks for the responses. Sorry if my initial post was vague. I am using a ws2812B LED strip from eBay. Just to specify the problem, the green and the red LEDs were reversed (if the animation was supposed to be green the LEDs would show red and vice versa. Blue remained the same).

After looking around and double checking my hardware I narrowed the problem down to the rpi_ws281x library. Specifically I discovered that within the neopixels.py file (the file that pixelpi imports from) there was a place (line 52) where you could change the type of LEDs you had. After a bit more searching I found this list (Lines 53-59) of possible color configurations (RGB, GRB, GBR, etc). After a bit of trial and error (changing the strip_type, sudo python setup.py install within the rpi_ws281x/python directory every time I changed the strip_type, and loading up example_animation.py in pixelpi to see if the change worked) I finally got the right colors. I believe the strip_type that eventually worked for me was WS2811_STRIP_BRG though I can't quite remember for sure.

This error is too bizarre as the rpi_ws281x library seems to indicate that ws2811 are equivalant to ws2812/12B. I guess this means that the library for a RGB ws2812B is the same as the library for a BRG ws2811?

At any rate I'm glad to have it resolved. Thanks again.

from pixelpi.

Related Issues (5)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.