Sensirion / embedded-sps

Embedded i2c Driver for Sensirion Particulate Matter Sensors - Download the Zip Package from the Release Page
https://github.com/Sensirion/embedded-sps/releases
BSD 3-Clause "New" or "Revised" License
45 stars 15 forks source link

Getting the values for PM2.5 and PM10.0 is giving me values of 5000+ when using the example application. #56

Closed PopherTheG closed 2 years ago

PopherTheG commented 2 years ago

main.c: PM2.5: 5645.83 PM10.0: 5645.83

Above are the values for them I get. I was wondering what is the unit for this and is there still a conversion factor to make the results into μg/m3?

winkj commented 2 years ago

The output is in ug/m^3, so no further conversion is necessary.

Those values are obviously very high... Are you by any chance powering the SPS30 with 3.3V?

PopherTheG commented 2 years ago

@winkj Yeah I am powering it with 3.3V since the MCU I am using is also powered with 3.3V. Is there a workaround for this?

winkj commented 2 years ago

I'm not aware of any workaround; the supported supply voltage range for the SPS30 is 5V +/- 0.5V.

That said, the SPS30 will work fine with the 3.3V logic levels, so all you need to do is add a 5V line for the supply, SCL/SDA don't need any level shifting

winkj commented 2 years ago

I'll go ahead and close this as it's not a software/driver issue. If you have further questions on the SPS30 hardware, feel free to reach out to our technical support team at https://www.sensirion.com/en/about-us/support-center/.