Security
Secure data upload to openSenseMap
Information on connecting and programming the sensors, Bees and other components
With the SDS011 it is possible to determine the fine dust concentration in the air. The sensor outputs two values: The concentration of PM2.5 (particles < 2.5 um) and PM10 (particles < 10 um). This sensor is equipped with a small fan to suck in air. Inside it there is a laser which, together with a photodiode, measures the number of particles. The results of the measurements are given in µg/m³ (microgram per cubic meter).
#include "SenseBoxMCU.h"
#include <SPI.h>
#include <Wire.h>
SDS011 my_sds(Serial1) // Serial1 gibt hier den Seriellen Port an, an dem du den Sensor angeschlossen hast
float p10,p25
```arduino
void setup(){
// Normalen seriellen Port initialisieren
Serial.begin(9600);
while(!Serial);
// Seriellen Port an dem unsere Sensor angeschlossen ist initialisieren
Serial1.begin(9600);
delay(5000);
}
void loop(){
// Variablen den gemessenen Feinstaubwerte zuweisen
p10 = my_sds.getPm10();
p25 = my_sds.getPm25();
//Werte in der Konsole drucken
Serial.println("P2.5: "+String(p25));
Serial.println("P10: "+String(p10));
delay(1000);
}
In Blockly the sensor can be read out via the following block:
Select the port to which you have connected the sensor and the measured value via the drop-down menu.