WeatherDuino Forum

Full Version: Just tried testing a SDS011 here & don't seem to be getting a reading.
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Just tried testing a SDS011 here & don't seem to be getting a reading.
At this point I have it connected to an ESP32 Dev Board.

Assume TX & RX between the sensor & ESP must be crossed, as Tx-->Tx2 & Rx-->Rx2 gives not reply in the monitor.
Just all Zeros in the replies & then Wrong reply from sensor on reading, so I assume I have it connected correctly now.

Here's what I'm seeing.

Cheers

Phil.

Edit:-

Should also add that gefore connecting I tested the SDS011 with this Windows Software & it reads fine.
https://github.com/Galch/DustViewerSharp

Not sure how old these two sensors are as I've had them in the parts box for maybe 2 years or so.

 
Code:
16:11:29.745 -> ets Jun  8 2016 00:22:57
16:11:29.745 ->
16:11:29.745 -> rst:0x1 (POWERON_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
16:11:29.779 -> configsip: 0, SPIWP:0xee
16:11:29.779 -> clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
16:11:29.779 -> mode:DIO, clock div:1
16:11:29.779 -> load:0x3fff0018,len:4
16:11:29.779 -> load:0x3fff001c,len:1044
16:11:29.779 -> load:0x40078000,len:10124
16:11:29.779 -> load:0x40080400,len:5856
16:11:29.779 -> entry 0x400806a8
16:11:30.084 ->   WeatherDuino 4Pro
16:11:30.084 -> Air Quality Monitor III
16:11:30.084 ->   Firmware: 6.1_b007
16:11:30.084 ->
16:11:31.068 -> Initializing the SDS011 sensor!
16:11:31.068 ->
16:11:31.170 -> AA,C0,D6,4,FC,7,58,59,8E,AB
16:11:31.203 -> Calculate crc: 8E
16:11:31.203 ->  Response crc: 8E
16:11:31.203 -> SDS011 correctly set to active report mode.
16:11:31.203 ->
16:11:32.189 -> AA,C0,D1,16,11,2D,58,59,D6,AB
16:11:32.189 -> Calculate crc: D6
16:11:32.189 ->  Response crc: D6
16:11:32.189 -> SDS011 correctly set to factory working period.
16:11:32.189 ->
16:11:32.223 ->
16:11:32.223 -> Connecting to IITSNet-2G
16:11:32.459 -> ......................
16:11:34.529 -> WiFi connected!
16:11:34.529 -> IP address: 192.168.59.48
16:11:34.733 -> Get time OK.
16:11:34.733 -> UTC Time  : 1633583493
16:11:34.733 -> Local Time: Thursday, 07 October 2021 16:11:33
16:11:34.733 -> Reading Temp, Hum and Pressure
16:11:34.733 -> Temperature: nan
16:11:34.733 -> Humidity: nan
16:11:34.733 -> Amb. Pressure: nan
16:11:34.733 -> SL Pressure: nan
16:11:34.733 ->
16:11:34.733 ->
16:11:34.733 -> Waking up the dust sensor...
16:11:34.733 -> Reading will be done 40s later.
16:11:34.733 ->
16:12:14.692 -> Fan State: 1
16:12:14.692 -> Reading the dust sensor...
16:12:14.930 -> AA,C0,FA,4,DC,6,58,59,91,AB,
16:12:14.930 -> Calculate crc: 91
16:12:14.930 ->  Response crc: 91
16:12:14.930 ->
16:12:14.930 ->
16:12:14.930 ->
SDS011 readings:
16:12:14.930 -> PM2.5 : nan
16:12:14.930 -> PM10.0: nan


Also, the JSON URL reads like this.
 
Code:
{"ID":"AQM-III_Outdoor","TID":11,"ts":1633600111,"T":-1,"H":65535,"P":-1,"PM25_last":65535,"PM100_last":65535,"PM25_1H":65535,"PM100_1H":65535,"PM25_3H":65535,"PM100_3H":65535,"PM25_12H":65535,"PM100_12H":65535,"PM25_24H":65535,"PM100_24H":65535,"CO2":0}
Hi Phil,

For the connections of the SDS011 to the AQM-III board, please refer to this post:

https://www.meteocercal.info/forum/Threa...5#pid15365

I can't assure that the AQM-III firmware will work with other boards, however by seeing this:

Code:
{"ID":"AQM-III_Outdoor","TID":11,"ts":1633600111,"T":-1,"H":65535,"P":-1,"PM25_last":65535,"PM100_last":65535,"PM25_1H":65535,"PM100_1H":65535,"PM25_3H":65535,"PM100_3H":65535,"PM25_12H":65535,"PM100_12H":65535,"PM25_24H":65535,"PM100_24H":65535,"CO2":0}

I would bet you are trying to run the code without having the BME280 installed. Wink

Rgs.
Werk_AG
(07-10-2021, 19:53)Werk_AG Wrote: [ -> ]I would bet you are trying to run the code without having the BME280 installed. Wink

Thanks Werk,

100% correct & patched at the moment by fudging the missing Humidity to 50%.

Next step will be to begin reading the CCS811/HDC1080 Voc sensor sitting on my desk.

[attachment=2947]

Seems to be plenty of examples of basic sketches to read the 811, will need to search a few to do the HDC1080 as well.

Hoping that's easy to integrate into the main code on a Copy/Paste/Edit basis of existing code blocks.

If all goes good & I get the desired result I plan to purchase another board to build an in indoor hybrid that also monitors Voc's.

Cheers

Phil.

(Expect many questions as my ESP/C+ skills are very limited).
(11-10-2021, 22:04)Phil23 Wrote: [ -> ]Thanks Werk,

100% correct & patched at the moment by fudging the missing Humidity to 50%.

Wink Advantages of the open source code.


(11-10-2021, 22:04)Phil23 Wrote: [ -> ]Next step will be to begin reading the CCS811/HDC1080 Voc sensor sitting on my desk.
...
If all goes good & I get the desired result I plan to purchase another board to build an in indoor hybrid that also monitors Voc's.

(Expect many questions as my ESP/C+ skills are very limited).


I'm no ESP/C++ expert either, just a struggling amateur ReadManual .
Since the AQM-III does not use the CCS811/HDC1080 sensor, I suggest that the subject is not dealt with in this AQM-III support section, but in private or in this area:
https://www.meteocercal.info/forum/Forum...alking--68

Rgs.
Werk_AG