Unicorn pHAT Detected but doesn't light up

I have set up a Raspberry Pi Zero W with a Unicorn pHAT, attached with pogopins, as per this link: Pogo-a-go-go Solderless GPIO Pogo Pins – Pimoroni

When I run detect, it seems to detect it successfully:

pi@raspberrypi:~/Pimoroni/unicornhat/examples $ sudo ./detect.py
Detect

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:
unicorn.set_layout(unicorn.AUTO)

Otherwise use one of the following in our code:

unicorn.set_layout(unicorn.PHAT)
unicorn.set_layout(unicorn.HAT)

However, the lights don’t light up. I’ve tried running through the steps here: Getting Started with Unicorn pHAT - Pimoroni Yarr-niversity

I’ve also tried running the examples in the folder shown in the code sample above. When I try to run the examples, they all seem to hang when they get here:

pi@raspberrypi:~/Pimoroni/unicornhat/examples $ sudo ./rainbow_blinky.py
Rainbow Blinky

Blinks a rainbow from the center of the display.

If you're using a Unicorn HAT and only half the screen lights up,
edit this example and  change 'unicorn.AUTO' to 'unicorn.HAT' below.

I have to ctrl-c to progress beyond here (same in all the examples).

Is there anything obviously wrong about my setup?
Is there anything else I can do to check if I’ve done anything wrong?

I’ll post a link with some pics in comments in case I’ve got a layer 1 issue.

Pics here: Raspberry Pi ZeroW Pogopins - Imgur

Your missing some ground connections.
Unicorn pHAT at Raspberry Pi GPIO Pinout

All the grounds marked with that black horseshoe shaped blob need to be connected.
6, 9, 14, 20…

Thanks for taking the time to respond! I did as you suggested but the result is the same - the detect script detects it successfully, but I can’t get any of the LEDs to light (either using the example scripts or following the Getting Started steps). I also note that on the product page for the pogo pins (linked above) it shows the pHAT connected with three pins only, and the video shows this too (and it seems to work in the video).

Is there anything else I can check?

If you have enough pogo pins I’d put one on the other 5V pin and one on the 3.3V pin.

I tried with every pin connected just to see what would happen, and same result. TO make sure I wasn’t going crazy, I rebooted without the pHAT attached and ran the detect script again, and got the same result. Am I interpreting this incorrectly?

root@raspberrypi:/home/pi/Pimoroni/unicornhat/examples# ./detect.py
Detect

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:
unicorn.set_layout(unicorn.AUTO)

Otherwise use one of the following in our code:

unicorn.set_layout(unicorn.PHAT)
unicorn.set_layout(unicorn.HAT)

root@raspberrypi:/home/pi/Pimoroni/unicornhat/examples#

That looks to me like it detected it, especially when compared to the result shown in this post. Is there a problem with this script? Or is there some trick I’m missing?

I “think” that detect.py file just looks in “/proc/device-tree/hat/product” to see what installer you ran? It’s looking at the installed software / driver, not the actual device. I’m far from any type of expert on this though. And don’t really know exactly what its doing?
I have a couple of Unicorn Hat HD’s, and a Unicorn Mini. I haven’t ever run that file on them though.

How exactly are you running your examples?

I “think” that detect.py file just looks in “/proc/device-tree/hat/product” to see what installer you ran? It’s looking at the installed software / driver, not the actual device.

That makes sense, but I think might not be right based on the other post I linked to (when that user ran it they mentioned an EEPROM error which went away when it was re-attached properly).

How exactly are you running your examples?

Firstly I installed the library by running:
curl -sS https://get.pimoroni.com/unicornhat | bash

Looks like this clones the repo and then runs some install scripts. When it clones the repo it copies a bunch of sample scripts into an Examples folder. In here is the detect.py script as well as some others (for example, demo.py, rainbow_blinky.py, etc). So as root I just run these from bash:
./demo.py

Otherwise, using the examples in the Getting Started guide, I just bring up a Python prompt (sudo python) and just run the commands:

import unicornhat as uh
uh.set_layout(uh.PHAT)
uh.brightness(0.5)
uh.set_pixel(0, 0, 255, 0, 0)
uh.show()

I note in another thread you recommended to someone that they try reverting to an older OS version. I’m currently using Raspberry Pi OS, current version, downloaded from Operating system images – Raspberry Pi but will try using the OS from the link you provided and let you know if it helps.

OK, I’m with you so far. I usually run Pi OS with desktop, and run the examples from an IDE like Thonny. Less typing that way and less chance of a typo
I have done it from a Python prompt like you are when following a guide. I clip and past when I can.