pimoroni / unicorn-hat

Python library for Unicorn pHAT and HAT. 32 or 64 blinding ws2812 pixels for your Raspberry Pi
https://shop.pimoroni.com/products/unicorn-hat
MIT License
370 stars 131 forks source link

Doesn't play nicely with Scratch3 beta #124

Closed cymplecy closed 6 years ago

cymplecy commented 6 years ago

I seem to be having a clash between controlling Neopixels and running Scratch3 beta on Pi3B+ at same time

Simplest repeatability test for me is to run sudo python demo.py

Launch Chromium (All OK still) Load https://beta.scratch.mit.edu/

and then things go bad :(

Gadgetoid commented 6 years ago

I'm guessing - albeit a very tentative guess - that the underlying rpi_ws281x library is using a DMA channel that Chrome is also attempting to use. I can't think of any other resources they should be contending for- although I guess Chrome could be using the analog audio... normally that makes Unicorn HAT go horribly garbled long before any specific audio application is loaded.

Have you disabled analog audio?

cymplecy commented 6 years ago

[ignore] - I need to test more things before writing :)

cymplecy commented 6 years ago

Luckily - it does seem to just be a sound issue. If I use raspi-config and send sound output to HDMI, I can run the demo with Scratch3 loaded. Thanks for the pointing me in right direction :)