# Help combining Enviro pHAT & Adafruit SGP30 TVOC/eCO2 Gas Sensor

**URL:** <https://forums.pimoroni.com/t/help-combining-enviro-phat-adafruit-sgp30-tvoc-eco2-gas-sensor/14303>\
**Category:** Raspberry Pi\
**Created:** [June 19, 2020, 3:52pm UTC](https://forums.pimoroni.com/t/help-combining-enviro-phat-adafruit-sgp30-tvoc-eco2-gas-sensor/14303 "2020-06-19T15:52:56Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![ianbradby](https://avatars.discourse-cdn.com/v4/letter/i/ba8739/32.png) [@ianbradby](https://forums.pimoroni.com/u/ianbradby)\
**Post date:** [June 19, 2020, 3:52pm UTC](https://forums.pimoroni.com/t/help-combining-enviro-phat-adafruit-sgp30-tvoc-eco2-gas-sensor/14303/1 "2020-06-19T15:52:56Z")

</div>

Hi I hope you can help. Please excuse my ignorance on where to find the necessary wiring information I require for my first extension project.

I have a raspberry pi zero with an enviro phat attached and I’d like to extend the sensors and add a SGP30 gas sensor.

I’ve bought a proto bonnet mini extension and can physically connect the SGP30 to the bonnet with the enviro phat mounted on top using the appropriate GPIO 11mm header, however, I have no idea how to wire up the board. How do I figure out which pins are available (i.e. not used by the enviro phat) for the SGP30 so I can wire up the additional sensor?

Many thanks

---

<div class="post-metadata">

**Author:** ![alphanumeric](https://sea2.discourse-cdn.com/flex016/user_avatar/forums.pimoroni.com/alphanumeric/32/2729_2.png) [@alphanumeric](https://forums.pimoroni.com/u/alphanumeric)\
**Post date:** [June 19, 2020, 4:53pm UTC](https://forums.pimoroni.com/t/help-combining-enviro-phat-adafruit-sgp30-tvoc-eco2-gas-sensor/14303/2 "2020-06-19T16:53:45Z")

</div>

I do believe this is what your looking for. =)

> **[Enviro pHAT at Raspberry Pi GPIO Pinout](https://pinout.xyz/pinout/enviro_phat)**
>
> A package of environmental sensors for IoT projects

---

<div class="post-metadata">

**Author:** ![ianbradby](https://avatars.discourse-cdn.com/v4/letter/i/ba8739/32.png) [@ianbradby](https://forums.pimoroni.com/u/ianbradby)\
**Post date:** [June 19, 2020, 5:08pm UTC](https://forums.pimoroni.com/t/help-combining-enviro-phat-adafruit-sgp30-tvoc-eco2-gas-sensor/14303/3 "2020-06-19T17:08:23Z")

</div>

Many thanks for helping me out :-)

---

<div class="post-metadata">

**Author:** ![alphanumeric](https://sea2.discourse-cdn.com/flex016/user_avatar/forums.pimoroni.com/alphanumeric/32/2729_2.png) [@alphanumeric](https://forums.pimoroni.com/u/alphanumeric)\
**Post date:** [June 19, 2020, 6:22pm UTC](https://forums.pimoroni.com/t/help-combining-enviro-phat-adafruit-sgp30-tvoc-eco2-gas-sensor/14303/4 "2020-06-19T18:22:56Z")

</div>

Your welcome. It is linked too from the product page, but its just in bold type and easy to miss.

---

<div class="post-metadata">

**Author:** ![ianbradby](https://avatars.discourse-cdn.com/v4/letter/i/ba8739/32.png) [@ianbradby](https://forums.pimoroni.com/u/ianbradby)\
**Post date:** [June 20, 2020, 9:18am UTC](https://forums.pimoroni.com/t/help-combining-enviro-phat-adafruit-sgp30-tvoc-eco2-gas-sensor/14303/5 "2020-06-20T09:18:56Z")

</div>

I have the SPG30 wired up and working nicely with the test code from using IC2 pins 2 & 3 [https://learn.adafruit.com/adafruit-sgp30-gas-tvoc-eco2-mox-sensor/circuitpython-wiring-test](https://learn.adafruit.com/adafruit-sgp30-gas-tvoc-eco2-mox-sensor/circuitpython-wiring-test)

I’d like to now switch to using IC2 pins 8 & 9 however I’ve been unable to figure out how to adapt the python code to switch to the different pins. I’ve been trying to find a tutorial on how to do this, but unfortunately I don’t really know enough to get started.

---

<div class="post-metadata">

**Author:** ![alphanumeric](https://sea2.discourse-cdn.com/flex016/user_avatar/forums.pimoroni.com/alphanumeric/32/2729_2.png) [@alphanumeric](https://forums.pimoroni.com/u/alphanumeric)\
**Post date:** [June 20, 2020, 9:33am UTC](https://forums.pimoroni.com/t/help-combining-enviro-phat-adafruit-sgp30-tvoc-eco2-gas-sensor/14303/6 "2020-06-20T09:33:36Z")

</div>

i2c? GPIO 8 and 9 are SPI pins? Why do you want to switch pins?  
i2c is a shared bus by the way. You can connect multiple devices to i2c and they will all work fine, as long as no two devices have the same i2c address. The address used by Pimoroni’s breakouts etc are listed on their product pages.

---

<div class="post-metadata">

**Author:** ![ianbradby](https://avatars.discourse-cdn.com/v4/letter/i/ba8739/32.png) [@ianbradby](https://forums.pimoroni.com/u/ianbradby)\
**Post date:** [June 21, 2020, 3:47pm UTC](https://forums.pimoroni.com/t/help-combining-enviro-phat-adafruit-sgp30-tvoc-eco2-gas-sensor/14303/7 "2020-06-21T15:47:26Z")

</div>

Many thanks for pointing me in the right direction. I now have my project up and running successfully.

---

<div class="post-metadata">

**Author:** ![alphanumeric](https://sea2.discourse-cdn.com/flex016/user_avatar/forums.pimoroni.com/alphanumeric/32/2729_2.png) [@alphanumeric](https://forums.pimoroni.com/u/alphanumeric)\
**Post date:** [June 21, 2020, 5:23pm UTC](https://forums.pimoroni.com/t/help-combining-enviro-phat-adafruit-sgp30-tvoc-eco2-gas-sensor/14303/8 "2020-06-21T17:23:06Z")

</div>

That’s good to hear. I’ve been tinkering with Raspberry Pi’s for years now and I’m still learning.  
It can at times be frustrating but its also a whole lot of fun. =)
