Close
0%
0%

Particle Powered Air Quality Sensor

Learn how to monitor your air quality with some simple off the shelf components. Harness the power of Particle's platform to make it happen.

Public Chat
Similar projects worth following
Particle^2 (Particle Squared) is a breakout board to help you sense the air quality of your home or workspace using a Particle Argon, Boron, and Xenon. (Also compatible with Adafruit Feather)

If you want to go mobile, you can be power it on battery power. Or, if wall power is more of your thing than you can do that too.

Air quality. 

You probably think about it more now that our clean air has turned into a permanent haze across the sky. 

Yuck. 

One thing you do have control over is the air quality inside your home. In this tutorial, I'll show you how to build an air quality sensor in a few short steps.

  • 1 × Particle Argon Particle Mesh Wifi + Thread/Bluetooth Board
  • 1 × Particle^2 Air quality sensor board.
  • 1 × Molex Cabling Cable to connect HPM sensor to Particle^2
  • 1 × Honeywell HPMA115S0 Particle sensor

  • 1
    Gather the Goods

    Get everything together that you'll need for this project. 

    This includes:

    • A Particle Mesh board (Argon, Boron, Xenon). You can get them almost anywhere. Buying direct always works too.
    • Particle^2 Air Quality Sensor.
    • Honeywell HPMA115S0 Particle Sensor. 
    • Cable for HPMA115S0 Sensor. (The last three you can get here.)

    Side note: you can also gather all the separate pieces yourself and assemble. More on how to do that here.

  • 2
    Assemble Them
    1. Attach the Particle to the Particle^2 board
    2. Connect the HPM Particle sensor to the Particle^2 using the cable
    3. Plug in USB!

  • 3
    Configure Google Docs - Create the Script
    1. Create a new Google Sheet
    2. Then click the Tools menu and click Script Editor
    3. Create a new script
    4. Insert the below code into the script:
      //this is a function that fires when the webapp receives a POST request
      function doPost(e) {
      
       //Return if null
       if( e == undefined ) {
         Logger.log(“no data”);
         return HtmlService.createHtmlOutput(“need data”);
       }
      
       //Parse the JSON data
       var event = JSON.parse(e.postData.contents);
       var data = JSON.parse(event.data);
      
       //Get the last row without data
       var sheet = SpreadsheetApp.getActiveSheet();
       var lastRow = Math.max(sheet.getLastRow(),1);
       sheet.insertRowAfter(lastRow);
      
       //Get current timestamp
       var timestamp = new Date();
      
       //Insert the data into the sheet
       sheet.getRange(lastRow + 1, 1).setValue(event.published_at);
       sheet.getRange(lastRow + 1, 2).setValue(data.temperature);
       sheet.getRange(lastRow + 1, 3).setValue(data.humidity);
       sheet.getRange(lastRow + 1, 4).setValue(data.pm10);
       sheet.getRange(lastRow + 1, 5).setValue(data.pm25);
       sheet.getRange(lastRow + 1, 6).setValue(data.tvoc);
       sheet.getRange(lastRow + 1, 7).setValue(data.c02);
      
       SpreadsheetApp.flush();
       return HtmlService.createHtmlOutput(“post request received”);
      }

View all 7 instructions

Enjoy this project?

Share

Discussions

Similar Projects

Does this project spark your interest?

Become a member to follow this project and never miss any updates