The simplest possible program:
import unicornhat as uh
crashes with a segfault:
root@h2opi31:/home/Display# python D.py
As do the example programs (that terminate):
root@h2opi31:~/Pimoroni/unicornhat/examples# python detect.py
Note: Your Unicorn HAT must be plugged in before boot to detect properly!
Trying to detect if you have a Unicorn HAT or Unicorn pHAT
Autodetection finished, let’s see the result…
Your height is NOT equal to your width, so you must have a pHAT.
If your hardware has been properly detected, it should be safe to use the following in your code:
Otherwise use one of the following in our code:
Do I have out-of-date drivers or something? I just built a Raspberry Pi Zero W with a Unicorn pHAT and installed Raspian Lite using NOOBS Lite, so I’m running Raspbian GNU/Linux 9 (stretch).
I had to modify the install script because I’m running as the root user, but it seems to work, all the demos work, and my code works, but I get a segfault on program termination, and that just doesn’t feel right…
Am I doing something wrong?