-
Notifications
You must be signed in to change notification settings - Fork 8
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
Cannot read HPMA115C0 #26
Comments
Hi @cburlacu Thanks for the partial fix.
I do not have this sensor, so I wrote the module based on the datasheet...
Excellent! I can use this sample to update the test suite and hopefully fix this module. I need to find some spare time to look into this, so pleas be patient. |
Hi @cburlacu I pushed a patch a few days ago. Could you test this new version? pip install --force-reinstall git+https://github.com/avaldebe/PyPMS.git@6409565 |
Hi,
As far as I remember the issue is that it would call validate for the start command response ack: i.e. |
Thanks for checking. I'll try to figure the problem |
I see, it seems that the datasheet was inaccurate again and there is an |
Apparently still fails:
As far as I understand it, there are issued 2 commands and the result is concatenated:
so in Maybe |
I happen to have one of these hooked up on my desk right now and it does seem to work: DEBUG:pms:message hex: 400d04000000000000000000000000af One separate issue is that you're assuming zero values being returned mean the sensor is warming up. This isn't always the case. Here I had to wave an incense stick around for a few seconds in order to create enough pollution to get a reading. Let me know if you need any info to close the issue. I have a logic analyzer hooked up to it as well. |
That is great news. Thanks fort letting me know, so I can close the issue.
I see it more like a feature. Some of the supported sensors report zero PM if they are queried too soon after powering up, and I one would have to manually filter out such measurements. In any case, please open a separate issue about this "feature" so we can discuss how to address it. Thanks again, |
I agree it's really a CR, I'll open it as you suggest. FYI it's been running 4 days without any issues. I appreciate your project! |
Hi,
There are some issues while trying to connect to this PM sensor:
The length of the packet is 16 bytes, hence the second byte of the response should be 0x0D ... The datasheet seems to be wrong...
Also, when receiving the ack from passive mode command it fails (wrong header length - it receives 0xA5 0xA5) - it is validated as a message (in s0 _validate)...
It is not a fix, but at least I was able to take a sample
The text was updated successfully, but these errors were encountered: