File tree Expand file tree Collapse file tree 3 files changed +12
-3
lines changed Expand file tree Collapse file tree 3 files changed +12
-3
lines changed Original file line number Diff line number Diff line change 3636#include " SparkFun_BMV080_Arduino_Library.h" // CTRL+Click here to get the library: http://librarymanager/All#SparkFun_BMV080
3737
3838SparkFunBMV080SPI bmv080; // Create an instance of the BMV080 class
39- #define CS_PIN 15 // Define the chip select pin
39+ #define CS_PIN 5 // Define the chip select pin
4040
4141void setup ()
4242{
Original file line number Diff line number Diff line change @@ -93,11 +93,20 @@ void loop()
9393{
9494 if (bmv080.readSensor ())
9595 {
96+ float pm10 = bmv080.PM10 ();
9697 float pm25 = bmv080.PM25 ();
98+ float pm1 = bmv080.PM1 ();
9799
100+ Serial.print (" PM10: " );
101+ Serial.print (pm10);
102+ Serial.print (" \t " );
103+ Serial.print (" PM2.5: " );
98104 Serial.print (pm25);
105+ Serial.print (" \t " );
106+ Serial.print (" PM1: " );
107+ Serial.print (pm1);
99108
100- if (bmv080.isObstructed () == true )
109+ if (bmv080.isObstructed () == true )
101110 {
102111 Serial.print (" \t Obstructed" );
103112 }
Original file line number Diff line number Diff line change @@ -68,7 +68,7 @@ void setup()
6868 // Comment out this while loop, or it will prevent the remaining code from running.
6969
7070 Serial.println ();
71- Serial.println (" BMV080 Example 1 - Basic Readings " );
71+ Serial.println (" BMV080 Example 6 - Two Sensors " );
7272
7373 wirePort.begin ();
7474
You can’t perform that action at this time.
0 commit comments