Project

!!  Probably is easier to use a NODEMCU board or a Wemos Mini D1 due to built in USB !!

To make this Air Quality Sensor i’ve used Shinyei PPD42NS sensor and Adafruit Huzzah Esp8266 board.

The first thing that you need is an adapter for the Huzzah to connect it to your PC/Mac with USB cable.

ftdi cable
ftdi cable

I’ve used this cheap one bought on eBay: FT232RL FTDI USB to TTL Serial Adapter

FT232RL FTDI USB to TTL Serial Adapter
FT232RL FTDI USB to TTL Serial Adapter

To use the Huzzah ESP8266 with Arduino IDE read this official link: Using Arduino IDE – Adafruit Huzzah Esp8266

The small problem is that Huzzah ESP8266 has 3.3V logic level, due to that to connect the sensor i’ve used a Logic Level Converter because the Shinyei PPD42NS works at 5V.

Logic Level Converter
Logic Level Converter

Now you only need to hookup the parts correctly, in this image i’ve used the same ports of the code.

wiring shinyei pdd42ns

If you want to use Thingspeak you need to setup and create an account, it’s free and easy but you have the limit of one value update every 20 second.
So i’ve set to update the read of the Shinyei every 60 second, this also gave better accuracy to the readings.
Also check the Thingspeak API key of your channel, this key must be copied in the code for update your channel.

Then i’ve put everything in a electric plastic box:

arduinoairpollution.altervista.org
arduinoairpollution.altervista.org
arduinoairpollution.altervista.org
arduinoairpollution.altervista.org
arduinoairpollution.altervista.org
arduinoairpollution.altervista.org
arduinoairpollution.altervista.org
arduinoairpollution.altervista.org
arduinoairpollution.altervista.org
arduinoairpollution.altervista.org
arduinoairpollution.altervista.org
arduinoairpollution.altervista.org

To have a better reading i’ve also mounted a fan to circulate some air near the sensor.

CLICK HERE TO SEE THE CODE