-
Notifications
You must be signed in to change notification settings - Fork 636
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
base: dev
Are you sure you want to change the base?
Add support for number of particles on PMSX003 devices #1120
Conversation
MAGNITUDE_PARTICLES_10 | ||
} | ||
}, | ||
{"PMSX003_9", 9, 3, { |
There was a problem hiding this comment.
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}}, |
There was a problem hiding this comment.
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?
code/html/custom.js
Outdated
"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", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
9e1832b
to
2a96ba7
Compare
@@ -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 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
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 |
There was a problem hiding this comment.
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
03bec80
to
fa1a11d
Compare
@xoseperez fixed units - thanks. |
@xoseperez rebased and comments addressed. |
fa1a11d
to
29e30c6
Compare
Tested on a PMS7003 device only.