# Pi Zero + enviro+ + pms5003 = pin error

**URL:** <https://forums.pimoroni.com/t/pi-zero-enviro-pms5003-pin-error/23520>\
**Category:** Support\
**Created:** [December 14, 2023, 7:17am UTC](https://forums.pimoroni.com/t/pi-zero-enviro-pms5003-pin-error/23520 "2023-12-14T07:17:11Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![AAA](https://avatars.discourse-cdn.com/v4/letter/a/ea666f/32.png) [@AAA](https://forums.pimoroni.com/u/AAA)\
**Post date:** [December 14, 2023, 7:17am UTC](https://forums.pimoroni.com/t/pi-zero-enviro-pms5003-pin-error/23520/1 "2023-12-14T07:17:11Z")

</div>

The pi zero and enviro+ hat are not working with the pms5003 sensor. Seemingly the GPIO pin detection is not working due to updated libraries - per a discussion on GitHub.

When particulates.py is tried the error output is:

File “/usr/local/lib/python3.9/dist-packages/pms5003/ **init**.py”, line 109, in **init**  
self.\_pin\_enable, self.\_pin\_reset = gpiodevice.get\_pins\_for\_platform(PLATFORMS)  
ValueError: not enough values to unpack (expected 2, got 0)

UPDATE - the LCD is not working either. The lcd.py example returns:

Woah there, suitable gpiochip not found!  
⚠️ /dev/gpiochip0: 9 is an int and has been skipped, did you mean “PIN9” or “GPIO9”?

Is there any way for a plug and play / cut and paste user like me to fix it? Or is it a matter of waiting until the libraries are updated to fix the problem?

---

<div class="post-metadata">

**Author:** ![AAA](https://avatars.discourse-cdn.com/v4/letter/a/ea666f/32.png) [@AAA](https://forums.pimoroni.com/u/AAA)\
**Post date:** [December 15, 2023, 1:57pm UTC](https://forums.pimoroni.com/t/pi-zero-enviro-pms5003-pin-error/23520/2 "2023-12-15T13:57:53Z")

</div>

Update - the enviro+ hat works with the pms5003 on a Pi 4, but the lcd screen is not working. Pi zero refuses to work with the pms5003.

---

<div class="post-metadata">

**Author:** ![nemecek\_f](https://sea2.discourse-cdn.com/flex016/user_avatar/forums.pimoroni.com/nemecek_f/32/10286_2.png) [@nemecek\_f](https://forums.pimoroni.com/u/nemecek_f)\
**Post date:** [December 16, 2023, 10:48am UTC](https://forums.pimoroni.com/t/pi-zero-enviro-pms5003-pin-error/23520/3 "2023-12-16T10:48:58Z")

</div>

Hi, you can get lucky with some fixes posted in this thread, but nothing worked for me so far:

> [@Issue with Enviro+ with RPi Zero: Display and particles not working](https://forums.pimoroni.com/t/issue-with-enviro-with-rpi-zero-display-and-particles-not-working/23365/13):
>
> I am still stuck and honestly pretty tired trying to fix it so I will probably wait for the update. I currently cannot get over the Numpy error. Tried the code from the pull request, but that fails during installation because of permission issues and when I run it as sudo the script says it shouldn’t be run as sudo and exists early.

---

<div class="post-metadata">

**Author:** ![SithLord](https://avatars.discourse-cdn.com/v4/letter/s/d78d45/32.png) [@SithLord](https://forums.pimoroni.com/u/SithLord)\
**Post date:** [December 21, 2023, 7:16pm UTC](https://forums.pimoroni.com/t/pi-zero-enviro-pms5003-pin-error/23520/4 "2023-12-21T19:16:10Z")

</div>

I have posted an update in [Issue with Enviro+ with RPi Zero: Display and particles not working - Support - Pimoroni Buccaneers](https://forums.pimoroni.com/t/issue-with-enviro-with-rpi-zero-display-and-particles-not-working/23365/13) that may resolve this problem.

---

<div class="post-metadata">

**Author:** ![AAA](https://avatars.discourse-cdn.com/v4/letter/a/ea666f/32.png) [@AAA](https://forums.pimoroni.com/u/AAA)\
**Post date:** [September 20, 2026, 6:28am UTC](https://forums.pimoroni.com/t/pi-zero-enviro-pms5003-pin-error/23520/5 "2026-09-20T06:28:28Z")

</div>

After abandoning the Enviro+ since 2023 I gave it another go today using Debian Trixie on a pi zero W. Initially the LCD was not working, now fixed by using Claude. That conversation for anyone who has been similarly frustrated by it:

Woah there, suitable gpiochip not found!

✅ GPIO9: (line 9) found - /dev/gpiochip0 (pinctrl-bcm2835)!

⚠️ GPIO9: (line 9, GPIO9) currently claimed by None

EXIT CODE: 1

(pimoroni)

This is a **known, currently open, unresolved bug** in Pimoroni’s own repo — issue #148, filed against this exact hardware (Pi Zero W Rev 1.1, Bookworm), same symptom. It’s assigned to the maintainer but has no fix or resolution posted yet, so there’s no clean “correct” answer sitting on GitHub waiting for you.

What’s going on, concretely: pinctrl shows GPIO9 starts out correctly assigned as SPI0\_MISO (alt function). Somewhere during st7735’s init it gets reassigned to plain GPIO9 = output — but the reporter says even _after_ that reassignment, the screen still doesn’t work (backlight on, no image), and various dc/cs argument tweaks people tried didn’t fix it either. So even beyond your current crash, there may be a further rendering issue waiting once the gpiochip error is solved.

Nice, glad it’s up and running. For anyone else hitting this later: the combo that worked was dtoverlay=spi0-2cs,no\_miso in /boot/firmware/config.txt — frees GPIO9 from the SPI0 MISO alt-function (which gpiod/st7735 needs to claim as a DC pin) while keeping both chip-selects available (since the Enviro+ LCD is wired to CS1).
