!HELP! PM 2.5 sensor ( air quality detector) !HELP!

Hi guys,

I was developing an air quality sensor with NOVA PM sensor( type: SDS011). I failed to make communication between Arduino and my PM sensor. . Basically, I follow this link: http://www.instructables.com/id/Make-one-PM25-monitor-with-Arduino-UNO/?ALLSTEPS but with some modification in pin setting and coding, so as to fit in the littlebits W6 arduino bits. This link is my Arduino code: https://drive.google.com/folderview?id=0B5zoiKAUG2TzTmFpaGtGTXFFTWc&usp=sharing. I set my connection between w6 Arduino and PM Sensor as follow:
GND ------- GND
VCC ------- VCC
d10 ------- TXD
d11 ------- RXD

a0 ------- button and power
d5 ------- Numberbit //display PM 2.5 value
d9 ------- Numberbit// display PM 10 value


Hi there, @donaldhls94 :slight_smile:

I don’t know the ins and outs of your PM sensor, but perhaps this info about the littleBits Arduino will help. Also, @chris101 did some work on a CO2 detector that might be of interest to you. He calls it the Purple People Counter. :slight_smile:


LittleBits ICSP:

…GND --> O O <-- RESET

Digital Pin 16 / MOSI --> O O <-- Digital Pin 15 / SCK

…VCC --> O O <-- Digital Pin 14 / MISO

Find a discussion on this topic here: Using the Additional I/Os on the Arduino Bit

1 Like

Thank you!
I think there are some coding problem on the serial communication of my w6 arduino and the PM sensor. Any sources about the serial communication coding please?

Hi @donaldhls94,

The littleBits Arduino uses the ATMega 32u4 chip, which has built-in serial. It works slightly different than serial on an Arduino Uno (which is what the example you are following is written for.) The serial on a Leonardo needs to reconnect when initialized, so try adding a short delay after calling Serial.begin() in your setup() routine:

... // continue, serial should be on now

This assumes that your TX and RX lines attached to the pin 0 and pin 1 bitSnaps at the top of the board. For more information, and more ideas about how to use serial, visit the Arduino forum, and search for “Leonardo and Serial”.

1 Like