# RGB Matrix Portal Room CO2 Monitor

## Overview

https://youtu.be/cDeol3qiV-0

![](https://cdn-learn.adafruit.com/assets/assets/000/099/195/medium800thumb/temperature___humidity_banner.jpg?1612299477)

Carbon dioxide, aka CO<sub>2</sub>, is a gas that is an [essential part of the Earth's atmosphere](https://en.wikipedia.org/wiki/Carbon_dioxide) and life in general. However, while essential, it can have negative effects when concentrations exceed certain level. It can impact the entire planet via [global warming](https://en.wikipedia.org/wiki/Climate_change). But it can also have very local effects, for example on [indoor air quality](https://en.wikipedia.org/wiki/Indoor_air_quality#Carbon_dioxide). Elevated levels of CO<sub>2</sub> can lead to reduced cognitive ability and other health related concerns. Therefore, monitoring CO<sub>2</sub> levels of inside air can be useful as a part of gauging general air quality.&nbsp;

![](https://cdn-learn.adafruit.com/assets/assets/000/099/191/medium800/led_matrices_co2_banner.jpg?1612293758 Image source: https://commons.wikimedia.org/wiki/File:AIRS_Carbon_Dioxide_Vertical.png)

Numerous projects have already been done to monitor indoor CO<sub>2</sub>. This [project posted to Hackster](https://www.hackster.io/ferrithemaker/weather-and-air-quality-home-station-with-esp8266-nodemcu-10d346) uses an ESP8266 and a CCS811 to send values to [Adafruit IO](https://io.adafruit.com/). This [tweet](https://twitter.com/stephanschulz3/status/1353139291933831168) (and also [blog post](https://blog.adafruit.com/2021/01/29/family-creates-a-homemade-carbon-dioxide-test-feather-covid19-health-diy-mtlgazette/) with more info) shares a project done by an 11 year old and is based on the Feather ecosystem using the [SCD-30](https://www.adafruit.com/product/4867) CO<sub>2</sub> sensor from Sensirion. This is an excellent **true** CO<sub>2</sub> concentration sensor which we also use in this project.

In this project we use the **SCD-30** along with a **Matrix Portal** to drive a 64x32 RGB **LED matrix**. This provides a nice way to display the current conditions and have it be readable to an entire room. And as a bonus, with this hardware arrangement, **there is no soldering required!**

Primary: 

## Hardware

Here's a summary of the hardware needed for this project. Some items are optional. Also note that if you purchased an [**Adabox 016**](https://learn.adafruit.com/adabox016), you will have most of these items already.

The key item is of course the **SCD-30 CO2 sensor** itself:

### Adafruit SCD-30 - NDIR True CO2 Temperature and Humidity Sensor

[Adafruit SCD-30 - NDIR True CO2 Temperature and Humidity Sensor](https://www.adafruit.com/product/4867)
Take a deep breath in...now slowly breathe out. Mmm isn't it wonderful? All that air around us, which we bring into our lungs, extracts oxygen from and then breathes out carbon dioxide. CO2 is essential for life on this planet we call Earth - we and plants&nbsp;take turns using and...

In Stock
[Buy Now](https://www.adafruit.com/product/4867)
[Related Guides to the Product](https://learn.adafruit.com/products/4867/guides)
![Video of someone blowing a dust on a Adafruit SCD-30 - NDIR CO2 Temperature and Humidity Sensor. ](https://cdn-shop.adafruit.com/product-videos/640x480/4867-05.jpg)

To provide a solderless way to connect the SCD-30 to the Matrix Portal, you can use a **STEMMA QT cable**. They come in various lengths:

### STEMMA QT / Qwiic JST SH 4-Pin Cable - 50mm Long

[STEMMA QT / Qwiic JST SH 4-Pin Cable - 50mm Long](https://www.adafruit.com/product/4399)
This 4-wire cable is&nbsp;50mm / 1.9" long and fitted with JST SH female 4-pin connectors on both ends. Compared with the chunkier JST PH these are 1mm pitch instead of 2mm, but still have a nice latching feel, while being easy to insert and remove.

<a...></a...>

In Stock
[Buy Now](https://www.adafruit.com/product/4399)
[Related Guides to the Product](https://learn.adafruit.com/products/4399/guides)
![Angled of of JST SH 4-Pin Cable.](https://cdn-shop.adafruit.com/640x480/4399-00.jpg)

### STEMMA QT / Qwiic JST SH 4-pin Cable - 100mm Long

[STEMMA QT / Qwiic JST SH 4-pin Cable - 100mm Long](https://www.adafruit.com/product/4210)
This 4-wire cable is a little over 100mm / 4" long and fitted with JST-SH female 4-pin connectors on both ends. Compared with the chunkier JST-PH these are 1mm pitch instead of 2mm, but still have a nice latching feel, while being easy to insert and remove.

<a...></a...>

Out of Stock
[Buy Now](https://www.adafruit.com/product/4210)
[Related Guides to the Product](https://learn.adafruit.com/products/4210/guides)
![Angled shot of STEMMA QT / Qwiic JST SH 4-pin Cable.](https://cdn-shop.adafruit.com/640x480/4210-00.jpg)

### STEMMA QT / Qwiic JST SH 4-Pin Cable - 200mm Long

[STEMMA QT / Qwiic JST SH 4-Pin Cable - 200mm Long](https://www.adafruit.com/product/4401)
This 4-wire cable is a little over 200mm / 7.8" long and fitted with JST-SH female 4-pin connectors on both ends. Compared with the chunkier JST-PH these are 1mm pitch instead of 2mm, but still have a nice latching feel, while being easy to insert and remove.

<a...></a...>

In Stock
[Buy Now](https://www.adafruit.com/product/4401)
[Related Guides to the Product](https://learn.adafruit.com/products/4401/guides)
![Angled shot of JST SH 4-Pin Cable - 200mm Long.](https://cdn-shop.adafruit.com/640x480/4401-04.jpg)

You'll also need a **64x32 LED matrix** and a **Matrix Portal** to drive the matrix:

### Adafruit Matrix Portal - CircuitPython Powered Internet Display

[Adafruit Matrix Portal - CircuitPython Powered Internet Display](https://www.adafruit.com/product/4745)
Folks love our [wide selection of RGB matrices](https://www.adafruit.com/category/327) and accessories, for making custom colorful LED displays... and our RGB Matrix Shields and FeatherWings can be quickly soldered together to make the wiring much easier. But what if we made it...

In Stock
[Buy Now](https://www.adafruit.com/product/4745)
[Related Guides to the Product](https://learn.adafruit.com/products/4745/guides)
![Video of a person rotating an LED matrix panel with animation resembling falling colored sand.](https://cdn-shop.adafruit.com/product-videos/640x480/4745-05.jpg)

### 64x32 RGB LED Matrix - 4mm pitch

[64x32 RGB LED Matrix - 4mm pitch](https://www.adafruit.com/product/2278)
Bring a little bit of Times Square into your home with this sweet 64 x 32 square RGB LED matrix panel. These panels are normally used to make video walls, here in New York we see them on the sides of busses and bus stops, to display animations or short video clips. We thought they looked...

In Stock
[Buy Now](https://www.adafruit.com/product/2278)
[Related Guides to the Product](https://learn.adafruit.com/products/2278/guides)
![Two white hands hold out an assembled and powered on 64x32 RGB LED Matrix Panel - 4mm pitch. The matrix displays "Adafruit Industries LED MATRIX! 32x64 *RGB*"](https://cdn-shop.adafruit.com/640x480/2278-00.jpg)

 **OPTIONAL**. You can add one of these acrylic diffusers to provide a more matted look to the display:

### Black LED Diffusion Acrylic Panel - 10.2" x 5.1"

[Black LED Diffusion Acrylic Panel - 10.2" x 5.1"](https://www.adafruit.com/product/4749)
&nbsp;nice whoppin' rectangular slab of some lovely black acrylic to add some extra diffusion to your LED Matrix project. This material is 2.6mm (0.1") thick and is made of special cast acrylic that makes it perfect for glowy projects, especially matrices or NeoPixels.

Unlike...

In Stock
[Buy Now](https://www.adafruit.com/product/4749)
[Related Guides to the Product](https://learn.adafruit.com/products/4749/guides)
![LED RGB matrix 10.2" x 5.1" with "Adafruit Industries LED Matrix" text showing, and LED acrylic slowly covering to make it nicely diffused](https://cdn-shop.adafruit.com/product-videos/640x480/4749-02.jpg)

# RGB Matrix Portal Room CO2 Monitor

## CO2 Air Levels

The SCD-30 sensor reports the CO<sub>2</sub> levels in units of [parts per million](https://en.wikipedia.org/wiki/Parts-per_notation) (ppm). This is a bit of a wacky unit of measure, but is pretty much what it says. If you had a million "parts" of air, then how many "parts" of CO<sub>2</sub> does it contain. Or as [OSHA](https://www.osha.gov) defines it:

> Parts of vapor or gas per million parts of contaminated air by volume at 25 °C and 760 torr.

From the [SCD-30 datasheet](https://cdn-learn.adafruit.com/assets/assets/000/098/461/original/Sensirion_CO2_Sensors_SCD30_Datasheet.pdf) we can see that the sensor range is 400 to 10000 ppm:

![](https://cdn-learn.adafruit.com/assets/assets/000/099/152/medium800/led_matrices_sensor_range.jpg?1612226895)

But how do these ppm levels translate into air quality? Below is a PDF that covers lots of issues related to indoor air quality:

[OSHA Indoor Air Quality in Commercial and Institutional Buildings](https://www.osha.gov/Publications/3430indoor-air-quality-sm.pdf)
Buried in **Appendix A** is a section that discusses carbon dioxide levels. The key one they mention is the **5000 ppm Permissible Exposure Limit** (PEL). Think of that as the upper limit - your workplace should ideally be below that level.

Values below the 5000 ppm PEL limit are commonly broken down into these subjective ranges, which we have also adopted for use in this project.

- **\< 1000 = Good** air. Your body will be happy!
- **1000 - 2000 = Poor** air. See if there is any way to improve.
- **2000 - 5000 =&nbsp; Warning** levels. Good idea to investigate why.
- **\> 5000 = Dang** , you are above the OSHA Permissible Exposure Limit for 8 hour exposure. Something should be done.

So by "Dang" do you mean "Dangerous"? Sort of, but not like immediately dangerous. That requires levels greater than around 15,000 ppm (see PDF linked above). So it's not like you need to run for your life if the ppm jumps above 5000. But you don't want to spend extended periods of time in that environment.

## Matrix Display of Air Quality

The general idea for the Matrix Portal based air quality display is pretty simple. It has a readout of the current CO<sub>2</sub> levels in ppm so that value it always viewable. Then, for each of the four ranges above, there is an associated "smiley face" icon and word. This combination of icon/word was chosen as way to make the display more universally readable. The smileys don't rely on any specific language and additionally use color to help reinforce the condition. The green=good and red=bad association is fairly universal. But not everyone can distinguish the red/green colors. So the word provides an additional textual (but in English only) indication in a single color.

Hopefully with the combination of the two, smiley + word, the message is universally understood.

 **CO2 ppm \< 1000**

![led_matrices_good_example.jpg](https://cdn-learn.adafruit.com/assets/assets/000/099/166/medium640/led_matrices_good_example.jpg?1612283742)

 **1000 \<= CO2 ppm \< 2000**

![led_matrices_poor_example.jpg](https://cdn-learn.adafruit.com/assets/assets/000/099/168/medium640/led_matrices_poor_example.jpg?1612283786)

 **2000 \<= CO2 ppm \< 5000**

![led_matrices_warn_example.jpg](https://cdn-learn.adafruit.com/assets/assets/000/099/169/medium640/led_matrices_warn_example.jpg?1612283821)

 **CO2 ppm \>= 5000**

![led_matrices_dang_example.jpg](https://cdn-learn.adafruit.com/assets/assets/000/099/171/medium640/led_matrices_dang_example.jpg?1612283857)

# RGB Matrix Portal Room CO2 Monitor

## Prep the MatrixPortal

## Power Prep

The MatrixPortal supplies power to the matrix display panel via two standoffs. These come with protective tape applied (part of our manufacturing process) which MUST BE REMOVED!

Use some tweezers or a fingernail to remove the two amber circles.

![adafruit_io_mxprtl-3866.jpg](https://cdn-learn.adafruit.com/assets/assets/000/094/902/medium640/adafruit_io_mxprtl-3866.jpg?1600706317)

![adafruit_io_mxprtl-3867.jpg](https://cdn-learn.adafruit.com/assets/assets/000/094/903/medium640/adafruit_io_mxprtl-3867.jpg?1600706324)

## Power Terminals

Next, screw in the spade connectors to the corresponding standoff.

- **red** wire goes to **+5V** &nbsp;
- **black** wire goes to **GND**

![adafruit_io_mxprtl-3869.jpg](https://cdn-learn.adafruit.com/assets/assets/000/094/907/medium640/adafruit_io_mxprtl-3869.jpg?1600706432)

![adafruit_io_mxprtl-3871.jpg](https://cdn-learn.adafruit.com/assets/assets/000/094/908/medium640/adafruit_io_mxprtl-3871.jpg?1600706551)

## Panel Power

Plug either one of the four-conductor power plugs into the power connector pins on the panel. The plug can only go in one way, and that way is marked on the board's silkscreen.

![adafruit_io_mxprtl-3872.jpg](https://cdn-learn.adafruit.com/assets/assets/000/094/910/medium640/adafruit_io_mxprtl-3872.jpg?1600706597)

![adafruit_io_mxprtl-3873.jpg](https://cdn-learn.adafruit.com/assets/assets/000/094/911/medium640/adafruit_io_mxprtl-3873.jpg?1600706672)

## Dual Matrix Setup

If you're planning to use a 64x64 matrix, [follow these instructions on soldering the Address E Line jumper](https://learn.adafruit.com/adafruit-matrixportal-m4/pinouts#address-e-line-jumper-3072815).

## Board Connection

Now, plug the board into the left side shrouded 8x2 connector as shown. The orientation matters, so take a moment to confirm that the **white indicator arrow on the matrix panel is oriented pointing up and right** as seen here and the MatrixPortal overhangs the edge of the panel when connected. This allows you to use the edge buttons from the front side.

&nbsp;

Check nothing is impeding the board from plugging in firmly. If there's a plastic nub on the matrix that's keeping the Portal from sitting flat, cut it off with diagonal cutters

![adafruit_io_mxprtl-3874.jpg](https://cdn-learn.adafruit.com/assets/assets/000/094/912/medium640/adafruit_io_mxprtl-3874.jpg?1600706721)

![adafruit_io_mxprtl-3875.jpg](https://cdn-learn.adafruit.com/assets/assets/000/094/913/medium640/adafruit_io_mxprtl-3875.jpg?1600706732)

![](https://cdn-learn.adafruit.com/assets/assets/000/094/914/medium800/adafruit_io_mxprtl-3876.jpg?1600706891)

![](https://cdn-learn.adafruit.com/assets/assets/000/094/915/medium800/adafruit_io_mxprtl-3877.jpg?1600706894)

Info: 

# RGB Matrix Portal Room CO2 Monitor

## Install CircuitPython

[CircuitPython](https://github.com/adafruit/circuitpython) is a derivative of [MicroPython](https://micropython.org) designed to simplify experimentation and education on low-cost microcontrollers. It makes it easier than ever to get prototyping by requiring no upfront desktop software downloads. Simply copy and edit files on the **CIRCUITPY** drive to iterate.

## Set up CircuitPython Quick Start!

Follow this quick step-by-step for super-fast Python power :)

[Download the latest version of CircuitPython for this board via circuitpython.org](https://circuitpython.org/board/matrixportal_m4/)
## Further Information

For more detailed info on installing CircuitPython, check out [Installing CircuitPython](https://learn.adafruit.com/welcome-to-circuitpython/installing-circuitpython).

 **Click the link above and download the latest UF2 file.**

Download and save it to your desktop (or wherever is handy).

![led_matrices_Save_to_Desktop.png](https://cdn-learn.adafruit.com/assets/assets/000/095/075/medium640/led_matrices_Save_to_Desktop.png?1601050695)

Plug your MatrixPortal M4 into your computer using a known-good USB cable.

**A lot of people end up using charge-only USB cables and it is very frustrating! So make sure you have a USB cable you know is good for data sync.**

Double-click the **Reset** button (indicated by the green arrow) on your board, and you will see the NeoPixel RGB LED (indicated by the magenta arrow) turn green. If it turns red, check the USB cable, try another USB port, etc.

If double-clicking doesn't work the first time, try again. Sometimes it can take a few tries to get the rhythm right!

![led_matrices_matrixportal_install_cp.jpg](https://cdn-learn.adafruit.com/assets/assets/000/125/447/medium640/led_matrices_matrixportal_install_cp.jpg?1697644568)

You will see a new disk drive appear called **MATRIXBOOT**.

&nbsp;

Drag the **adafruit\_circuitpython\_etc.uf2** file to **MATRIXBOOT****.**

![led_matrices_MATRIXBOOT.png](https://cdn-learn.adafruit.com/assets/assets/000/125/448/medium640/led_matrices_MATRIXBOOT.png?1697644692)

![led_matrices_Drag_to_Drive.png](https://cdn-learn.adafruit.com/assets/assets/000/125/449/medium640/led_matrices_Drag_to_Drive.png?1697644703)

The LED will flash. Then, the **MATRIXBOOT** &nbsp;drive will disappear and a new disk drive called **CIRCUITPY** will appear.

That's it, you're done! :)

![led_matrices_circuitpy.png](https://cdn-learn.adafruit.com/assets/assets/000/125/450/medium640/led_matrices_circuitpy.png?1697645066)

# RGB Matrix Portal Room CO2 Monitor

## Code

Here's how to load the code and assets as well as some additional libraries you'll need.

## Additional Libraries

To use with CircuitPython, you need to first install a few libraries, into the lib folder on your **CIRCUITPY** drive. Then you need to update **code.py** with the example script.

Thankfully, we can do this in one go. In the example below, click the **Download Project Bundle** button below to download the necessary libraries and the **code.py** file in a zip file. Extract the contents of the zip file, open the directory **Matrix\_Portal\_CO2\_Monitor/** and then click on the directory that matches the version of CircuitPython you're using and copy the contents of that directory to your **CIRCUITPY** drive.

Your **CIRCUITPY** drive should now look similar to the following image:

![CIRCUITPY](https://adafruit.github.io/Adafruit_Learning_System_Guides/Matrix_Portal_CO2_Monitor.png )

## Code

Here's the code for the Matrix Portal CO<sub>2</sub> Monitor.

https://github.com/adafruit/Adafruit_Learning_System_Guides/blob/main/Matrix_Portal/Matrix_Portal_CO2_Monitor/code.py

# RGB Matrix Portal Room CO2 Monitor

## CO2 Sensor Setup

Connecting the SCD-30 sensor to the Matrix Portal is easy thanks to the [STEMMA QT connector system](https://learn.adafruit.com/introducing-adafruit-stemma-qt).

Pretty simple. Use the **STEMMA QT cable** to connect the **SCD-30** to the **Matrix Portal**.

![led_matrices_connection.jpg](https://cdn-learn.adafruit.com/assets/assets/000/099/190/medium640/led_matrices_connection.jpg?1612291654)

Where to actually place the SCD-30 is sort of up to you and your specific setup. However, you'll want to put&nbsp; a little thought into it to make sure the sensor is properly exposed to the ambient air conditions. Sensirion actually has a document with some guidelines you can read below:

[SCD30 Sensor Placement Guidelines](https://cdn-learn.adafruit.com/assets/assets/000/098/502/original/Sensirion_SCD30_Design-In_Guidelines_D1.pdf?1609963143)
For example, make sure the sensor isn't exposed to direct sunlight. They also have a nice diagram to illustrate suggested placement within an enclosure:

![](https://cdn-learn.adafruit.com/assets/assets/000/099/157/medium800/led_matrices_sensor_placement.jpg?1612232215)

There's also information related to self heating and use in a moving air duct. So give that document a read to help determine where and how best to locate the SCD-30.

## CircuitPython Usage

If you want more in depth coverage of using the SCD-30 sensor in CircuitPython, checkout the main guide for the sensor below:

[SCD-30 Python &amp; CircuitPython](https://learn.adafruit.com/adafruit-scd30/python-circuitpython)
# RGB Matrix Portal Room CO2 Monitor

## What Font?

If you've done other CircuitPython projects involving text and displays, you've probably used a custom font file. That's a great way to get a nice custom look to project read outs. But you may have noticed - **this project has no font file**.

So how did we get those nice bold text readouts? Let's talk about that a bit. It's a trick that could be useful for other projects. We'll mainly focus on the way the CO<sub>2</sub> reading was done.

## Sprite Sheet Instead of Font File

At the heart of the CircuitPython [displayio](https://learn.adafruit.com/circuitpython-display-support-using-displayio) library is the concept of [TileGrids](https://learn.adafruit.com/circuitpython-display-support-using-displayio/tilegrid-and-group). This lets you carve up a source bitmap into multiple sections (tiles) and then layout one or more of them (grid). You can do this with any bitmap, but here we use one that contains the numbers 0-9. It was created by hand in [GIMP](https://www.gimp.org/):

![](https://cdn-learn.adafruit.com/assets/assets/000/099/153/medium800/led_matrices_Screenshot_from_2021-02-01_17-05-49.png?1612228295)

The max value the SCD30 can report is 10000 ppm. Ignoring that upper limit, every other reading is at most 4 digits wide. The LED matrix we use is 32 pixels wide. Mathy McMathy says "32 / 4 = 8" so we make each digit be 8 pixels wide. We chose 10 pixels for the height as a "meh, that looks about right" value.

Loading the source **Bitmap** into our code is just one line of code:

```python
digits_bmp, digits_pal = adafruit_imageload.load("/bmps/digits.bmp")
```

Setting up our **TileGrid** that will use this source **Bitmap** is also a single line of code, but there are numerous parameters that get used:

```python
co2_value = displayio.TileGrid(
    digits_bmp,
    pixel_shader=digits_pal,
    x=0,
    y=51,
    width=4,
    height=1,
    tile_width=8,
    tile_height=10,
)
```

We tell it to use `digits_bmp`, and its associate color palette `digits_pal`, as our source Bitmap. We also go ahead and set our location on the matrix with `x` and `y`. Now for the more important ones to understand. With `width` and `height` we are setting the size of the resulting **TileGrid** in terms of number of tiles. The similarly named `tile_width` and `tile_height` are what actually set the individual tile size - and how the source bitmap is carved up. The result looks something like this:

![](https://cdn-learn.adafruit.com/assets/assets/000/099/156/medium800/led_matrices_digits_sprite1.png?1612230823)

The `co2_value` **TileGrid** is 4 x 1 tiles. Each of these tiles can "point" to any of the possible source tiles, 0 - 10, from the source **Bitmap** `digits_bmp`. The syntax for doing that would look like:

```python
co2_value[1] = 4
```

to set the second digit (index 1) to 4 as an example.

By creating our source bitmap with the digits arranged as they are, the indices correspond to the actual digits, 3=3, 7=7, etc. That lets us use the digits from the actual CO<sub>2</sub> reading to set each tile. That's what this bit of code does:

```python
# CO2 value
# clear it
for i in range(4):
    co2_value[i] = 10
# update it
i = 3
while value:
    co2_value[i] = value % 10
    value = int(value / 10)
    i -= 1
```

So it looks like we are printing text using a blocky font, but we are not. It's all done with a bitmap file. Pretty neat trick, huh?

## Why Do That?

So why do this TileGrid / Bitmap file approach vs. just using a font file and formatted prints? Mainly for precise control of the resulting output. Like pixel-by-pixel control. The LED matrix is physically large but is pretty low resolution - only 64 x 32. And our CO<sub>2</sub> value readout uses only 8x10 pixel digits. Getting a font to render exactly like you want at that low of a resolution can sometimes be tricky. And since we only needed digits, not a full alphabet, we just felt we could get there quicker with this approach.

TileGrids can be a bit tricky to wrap your head around at first. Hopefully this example not only helps illustrate how they work, but also maybe a neat way you can use them in your projects. Be sure to checkout the [Displayio Learn Guide](https://learn.adafruit.com/circuitpython-display-support-using-displayio) for more details.

## Changing The Text Labels

The text readouts are done with the four English words GOOD, POOR, WARN, and DANG. This was also done using a TileGrid / Bitmap combo. Here's the source bitmap:

![](https://cdn-learn.adafruit.com/assets/assets/000/099/172/medium800/led_matrices_Screenshot_from_2021-02-02_08-41-40.png?1612284181)

It's simpler than the CO2 value read out. It's just a single tile which points to one of the 32x16 pixel words. If you wanted to change the text, you could do so by editing the source bitmap. Since it's a bitmap, you can make it be whatever you want. No need to find a font that supports a specific language.

## Changing The Smileys

The smiley face icons also come from a source bitmap:

![](https://cdn-learn.adafruit.com/assets/assets/000/099/173/medium800/led_matrices_Screenshot_from_2021-02-02_08-48-32.png?1612284547)

So they could also be changed if you wanted by simply editing each of the sub 32x32 pixel icons.

# RGB Matrix Portal Room CO2 Monitor

## 3D Printed Sensor Case

We designed a 3D printed bracket for the display and sensor so the parts are nicely secured.

You can use a screw or nail to hang it on a wall with our 3D printed bracket.

The bracket is secured to the heat set inserts that are built into the frame of the display.

The sensor is press fitted into the case with openings on the side for the cables.

The cover snap fits over the case and features holes to allow air to reach the sensor.

&nbsp;

![temperature___humidity_hero-case-close.jpg](https://cdn-learn.adafruit.com/assets/assets/000/099/469/medium640/temperature___humidity_hero-case-close.jpg?1613493657)

![temperature___humidity_hero-front.jpg](https://cdn-learn.adafruit.com/assets/assets/000/099/470/medium640/temperature___humidity_hero-front.jpg?1613493709)

The bracket and enclosure parts are 3d printed without any support material using PLA filament.

The Wall hanger is attached the Matrix with M3 screws.

![temperature___humidity_wallhanger.jpg](https://cdn-learn.adafruit.com/assets/assets/000/099/471/medium640/temperature___humidity_wallhanger.jpg?1613493909)

## Parts List

STL files for 3D printing are oriented to print "as-is" on FDM style machines. Parts are designed to 3D print without any support material. Original design source may be downloaded using the links below.

Medium Sized Matrix ([Adabox 16](https://learn.adafruit.com/adabox016))

- CO2-Lid-txt
- CO2-Case
- CO2-Bracket ([https://www.adafruit.com/product/2278](https://www.adafruit.com/product/2278))
- CO2-Wall-Hang

Large Matrix PID: 2276 ([https://www.adafruit.com/product/2276](https://www.adafruit.com/product/2276))

- CO2Bracket-LG
- CO2-Wall-Hang-LG.stl
- Wall-Hang-LG

![temperature___humidity_3d-parts.jpg](https://cdn-learn.adafruit.com/assets/assets/000/099/472/medium640/temperature___humidity_3d-parts.jpg?1613498505)

[Edit Matrix CO2 Parts](https://a360.co/2OJCGcZ)
[Download STLs](https://www.thingiverse.com/thing:4766986)
## Slicing Parts

Slice with settings for PLA material. The parts were sliced using CURA using the slice settings below.

- PLA filament 215c extruder
- 0.2 layer height
- 10% gyroid infill
- 60mm/s print speed
- 60c heated bed

![temperature___humidity_slice-loop.gif](https://cdn-learn.adafruit.com/assets/assets/000/099/473/medium640thumb/temperature___humidity_slice-loop.jpg?1613499587)

## Case Assembly

&nbsp;

The bracket is secured to the enclosure using M2.5 hardware screws and hex nuts.

The bracket is secured to the heat set inserts that are built into the frame of the display.

&nbsp;

![temperature___humidity_screws.jpg](https://cdn-learn.adafruit.com/assets/assets/000/099/474/medium640/temperature___humidity_screws.jpg?1613499739)

![temperature___humidity_matrixPortal-brackets.jpg](https://cdn-learn.adafruit.com/assets/assets/000/099/475/medium640/temperature___humidity_matrixPortal-brackets.jpg?1613499830)

The sensor is press fitted into the case with openings on the side for the cables.

The cover snap fits over the case and features holes to allow air to reach the sensor.

![temperature___humidity_hero-scd30-close.jpg](https://cdn-learn.adafruit.com/assets/assets/000/099/477/medium640/temperature___humidity_hero-scd30-close.jpg?1613500199)

![temperature___humidity_sensor-cover.jpg](https://cdn-learn.adafruit.com/assets/assets/000/099/478/medium640/temperature___humidity_sensor-cover.jpg?1613500266)


## Featured Products

### Adafruit SCD-30 - NDIR True CO2 Temperature and Humidity Sensor

[Adafruit SCD-30 - NDIR True CO2 Temperature and Humidity Sensor](https://www.adafruit.com/product/4867)
Take a deep breath in...now slowly breathe out. Mmm isn't it wonderful? All that air around us, which we bring into our lungs, extracts oxygen from and then breathes out carbon dioxide. CO2 is essential for life on this planet we call Earth - we and plants&nbsp;take turns using and...

In Stock
[Buy Now](https://www.adafruit.com/product/4867)
[Related Guides to the Product](https://learn.adafruit.com/products/4867/guides)
### Adafruit Matrix Portal - CircuitPython Powered Internet Display

[Adafruit Matrix Portal - CircuitPython Powered Internet Display](https://www.adafruit.com/product/4745)
Folks love our [wide selection of RGB matrices](https://www.adafruit.com/category/327) and accessories, for making custom colorful LED displays... and our RGB Matrix Shields and FeatherWings can be quickly soldered together to make the wiring much easier. But what if we made it...

In Stock
[Buy Now](https://www.adafruit.com/product/4745)
[Related Guides to the Product](https://learn.adafruit.com/products/4745/guides)
### 64x32 RGB LED Matrix - 4mm pitch

[64x32 RGB LED Matrix - 4mm pitch](https://www.adafruit.com/product/2278)
Bring a little bit of Times Square into your home with this sweet 64 x 32 square RGB LED matrix panel. These panels are normally used to make video walls, here in New York we see them on the sides of busses and bus stops, to display animations or short video clips. We thought they looked...

In Stock
[Buy Now](https://www.adafruit.com/product/2278)
[Related Guides to the Product](https://learn.adafruit.com/products/2278/guides)
### Black LED Diffusion Acrylic Panel - 10.2" x 5.1"

[Black LED Diffusion Acrylic Panel - 10.2" x 5.1"](https://www.adafruit.com/product/4749)
&nbsp;nice whoppin' rectangular slab of some lovely black acrylic to add some extra diffusion to your LED Matrix project. This material is 2.6mm (0.1") thick and is made of special cast acrylic that makes it perfect for glowy projects, especially matrices or NeoPixels.

Unlike...

In Stock
[Buy Now](https://www.adafruit.com/product/4749)
[Related Guides to the Product](https://learn.adafruit.com/products/4749/guides)
### STEMMA QT / Qwiic JST SH 4-Pin Cable - 50mm Long

[STEMMA QT / Qwiic JST SH 4-Pin Cable - 50mm Long](https://www.adafruit.com/product/4399)
This 4-wire cable is&nbsp;50mm / 1.9" long and fitted with JST SH female 4-pin connectors on both ends. Compared with the chunkier JST PH these are 1mm pitch instead of 2mm, but still have a nice latching feel, while being easy to insert and remove.

<a...></a...>

In Stock
[Buy Now](https://www.adafruit.com/product/4399)
[Related Guides to the Product](https://learn.adafruit.com/products/4399/guides)

## Related Guides

- [Adafruit MatrixPortal M4](https://learn.adafruit.com/adafruit-matrixportal-m4.md)
- [Adafruit SCD-30 - NDIR CO2 Temperature and Humidity Sensor](https://learn.adafruit.com/adafruit-scd30.md)
- [Adafruit Triple LED Matrix Bonnet for Raspberry Pi with HUB75](https://learn.adafruit.com/adafruit-triple-led-matrix-bonnet-for-raspberry-pi-with-hub75.md)
- [Scroll an SMS Text Message on your RGB Matrix](https://learn.adafruit.com/scroll-an-sms-text-message-on-your-rgb-matrix.md)
- [Matrix Portal RGB Display Handbag](https://learn.adafruit.com/matrix-portal-rgb-display-handbag.md)
- [Weather Display Matrix](https://learn.adafruit.com/weather-display-matrix.md)
- [Tombstone Matrix Portal](https://learn.adafruit.com/tombstone-matrix-portal.md)
- [Creating MatrixPortal Projects with CircuitPython](https://learn.adafruit.com/creating-projects-with-the-circuitpython-matrixportal-library.md)
- [Cardboard Window Skull With Animated LED Eyes](https://learn.adafruit.com/cardboard-window-skull-animated-led-eyes.md)
- [LED Protest Sign](https://learn.adafruit.com/led-protest-sign.md)
- [RGB Matrix Automatic YouTube ON AIR Sign](https://learn.adafruit.com/rgb-matrix-automatic-youtube-on-air-sign.md)
- [RGB LED Matrix Basics](https://learn.adafruit.com/32x16-32x32-rgb-led-matrix.md)
- [Tombstone Prop-Maker RP2040](https://learn.adafruit.com/tombstone-prop-maker-rp2040.md)
- [Image Correction for RGB LED Matrices](https://learn.adafruit.com/image-correction-for-rgb-led-matrices.md)
- [Custom Scrolling Quote Board Matrix Display](https://learn.adafruit.com/aio-quote-board-matrix-display.md)
- [Matrix Portal Creature Eyes](https://learn.adafruit.com/matrix-portal-creature-eyes.md)
- [Purple Air AQI Display](https://learn.adafruit.com/purple-air-aqi-display.md)
