-
Notifications
You must be signed in to change notification settings - Fork 53
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Issue after sleep function #21
Comments
i just figured out that if i connect it again; it works until the part of the code it says to sleep and then doesnt turn on anymore after i reconnect it again. i deleted that part and could make it work again, but my question is: how can i use the sleep mode and wakeup mode properly? i know it has been asked before but i couldnt find an answer. thanks! |
This seems like a problem with the SDS011. Normally neither sleep() or wakeup() are working because of a bad connection between the cpu board and the SDS011. In this case the SDS011 can send to the board, but can't receive the commands. |
Thanks for your fast reply Ricki. The fan is stopping at the sleep command. But it's not starting at the wakeup one. What I had to do is to delete the sleep from the code and then re upload it and reconnect it (with this I mean plug off and on again) and it starts again. |
As mentioned the SDS011 should start again on any command sent. So this seems to be an issue with your SDS011. |
Ok. I will try with another one. But I will also try wiring again, as I have shared grounds and the 5v for other sensors, maybe this could be it? |
uhmmm nope, ive changed the wiring and also tried other SDS011 but the same happens. do you have another idea what could be happening? it might be an issue of communication, but i dont know nothing about this. thanks in advance! |
I am seeing the same things. My new batch of SDS011's no longer wake-up based on the (simplified) wakeup() function in the library. The wakeup() function simply sends an 0x01 byte to the SDS011, which used to wake up my SDS sensors. However that no longer works... Solution: In the current datasheet, it is specified that the proper wake-up procedure is to send a 19-byte sequence very similar to the SLEEP command. If you modify "sds011.cpp" by adding the struct below and changing the wakeup function similar to what I tried below then everything seems to work just fine! Here's a link to the spec, refer to pages 7 and 8: [https://nettigo.pl/attachments/415]
|
I will change this. The "short" version was used to save some memory. |
THANKS a lot!! it worked :) |
Please update the library with the new wakeup() function as specified in the specs. I did some tests several SDS sensors with the following serial numbers: 5002-2525 (wakeup ok) It seems that the old SDS sensors worked fine with the short wakeup(), but the new SDS sensors needs the full qualified message of 19 bytes as is specified in the documentation. |
My SDS needed the changings in the .cpp file as described above as well! Now it works. Thank you! Serial number: 5002-C8F5. |
Hello, im doing a project with DHT22 and SDS011, its a typical project as I can see.
First of all I want to thank you because of you work to make this for compatible with arduino.
Here's my issue:
I was reading the sds011 data and i havent the slept function in the code and everything was fine
then i added this line to the code
mySDS.sleep();
delay(6000);
mySDS.wakeup();
in the loop after measuring all the data, and now the fan doesnt turn on and it displays 0 as values and 1 as the "error" value, which will come as a "1" if there's no data available, and thats because its under sleepmode i think? but i cant make it to wake up...
any tips on this?
thanks in advance!
The text was updated successfully, but these errors were encountered: