Skip to content
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

Add support for number of particles on PMSX003 devices #1120

Open
wants to merge 1 commit into
base: dev
Choose a base branch
from

Conversation

ruimarinho
Copy link
Contributor

@ruimarinho ruimarinho commented Aug 9, 2018

screen shot 2018-11-02 at 00 39 37

Tested on a PMS7003 device only.

MAGNITUDE_PARTICLES_10
}
},
{"PMSX003_9", 9, 3, {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unsure what this device is @Yonsm.

MAGNITUDE_PM1dot0,
MAGNITUDE_PM2dot5,
MAGNITUDE_PM10
}},
{"PMS5003T", 13, 3, {MAGNITUDE_PM2dot5, MAGNITUDE_TEMPERATURE, MAGNITUDE_HUMIDITY}},
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Yonsm could you check if these devices also support same readings?

"PM1.0", "PM2.5", "PM10", "CO2", "Lux", "UV", "Distance" , "HCHO",
"PM1.0", "PM2.5", "PM10",
"Particles ≧0.3 ﹤0.5µm", "Particles ≧0.5 ﹤1µm", "Particles ≧1 ﹤2.5µm ",
"Particles ≧2.5 ﹤5µm", "Particles ≧5 ﹤10µm", "Particles ≧10µm",
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

According to the data sheet:

screen shot 2018-08-09 at 01 54 17

I don't really understand how the device can measure "beyond 10µm" if that it's max range. What am I missing?

@ruimarinho ruimarinho force-pushed the support/number-of-particles-pmsx003 branch from 9e1832b to 2a96ba7 Compare August 9, 2018 01:00
@@ -287,6 +302,12 @@ class PMSX003Sensor : public BaseSensor, PMSX003 {
_slot_values[0] = data[3];
_slot_values[1] = data[4];
_slot_values[2] = data[5];
_slot_values[3] = data[6] * 10; // convert particles per 0.1L of air to 1L
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

According to the data sheet:

screen shot 2018-08-09 at 01 54 17

This was my interpretation (read value * 10 for number of particles in 1L)

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, I understand the same, but you have defined the units per square meter of air when it should me per liter, so magnitude_particles_m3 should be magnitude_particles_l

@@ -287,6 +302,12 @@ class PMSX003Sensor : public BaseSensor, PMSX003 {
_slot_values[0] = data[3];
_slot_values[1] = data[4];
_slot_values[2] = data[5];
_slot_values[3] = data[6] * 10; // convert particles per 0.1L of air to 1L
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, I understand the same, but you have defined the units per square meter of air when it should me per liter, so magnitude_particles_m3 should be magnitude_particles_l

@ruimarinho ruimarinho force-pushed the support/number-of-particles-pmsx003 branch 2 times, most recently from 03bec80 to fa1a11d Compare August 15, 2018 23:29
@ruimarinho
Copy link
Contributor Author

@xoseperez fixed units - thanks.

@ruimarinho
Copy link
Contributor Author

@xoseperez rebased and comments addressed.

@ruimarinho ruimarinho force-pushed the support/number-of-particles-pmsx003 branch from fa1a11d to 29e30c6 Compare November 2, 2018 00:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants