News for hackers. Stuff that matters.
Re:CO2meter: A Python interface to USB CO2 monitor devices by joecool1029 on Thursday April 02, 2020 @07:02PM (#22764771)
This library is for the RAD-0301 meter, marketed as a the co2meter.com mini CO2 meter. I don't know if it works with any other models but as I have one of these, I can tell you it works from my linux machines.

You're probably going 'Wow that's expensive for a CO2 meter when I can goto Aliexpress and get one for $10!' This is actually pretty cheap for a NDIR sensor which is what one should use for CO2 monitoring. The cheapo $10 sensors are all VOC sensors that require calibration and can be affected by airborne pollutants like alcohol.

I believe this is only 100ppm accuracy, the 5-10ppm resolution sensors are many hundreds of dollars. It's fine enough for casual air quality measurements.

Re:CO2meter: A Python interface to USB CO2 monitor devices by Hasz on Friday April 03, 2020 @01:01AM (#22766415)
For $20, you can get the MH Z-19, which is a NDIR type. You can talk to it over UART, and it comes in a 5000ppm and 2000ppm model IIRC. Decent documentation, and a good little sensor.

The S8-0053 looks interesting, but I have no experience with it. Also NDIR, boasts +- 40ppm accuraxy -- the room air might not even be that homogeneous...

The cheap ones are electrochemical, and they're not even that cheap.

https://sandboxelectronics.com/files/SEN-000007/MG811.pdf

Re:CO2meter: A Python interface to USB CO2 monitor devices by polskibus on Friday April 03, 2020 @09:37AM (#22768994)
Problem with it is that it autorecalibrates itself every 24hrs as far as I remember. It is a problem in room monitoring where you have constant high CO2- you'd have to take the sensor outside to fix it's reference level.
Re:CO2meter: A Python interface to USB CO2 monitor devices by petsfed on Thursday April 02, 2020 @07:16PM (#22764862)
The core device is typically on the order of $50-$150 US, but with many of the sensors that CO2meter sells, you're also getting a microcontroller, display, power supply, etc. You'll frequently find temperature and humidity sensors and also barometric pressure sensors rolled into that, since NDIR is affected by all those things.

So the price of a good, fully realized NDIR CO2 meter is comparable with any low-volume, moderate precision, moderate complexity electronic device.

Re:CO2meter: A Python interface to USB CO2 monitor devices by Klinky on Thursday April 02, 2020 @07:38PM (#22765005)
Andreas Spiess has a good video on VOC vs CO2 sensors.

https://www.youtube.com/watch?v=FL0L-nic9Vw

Re:CO2meter: A Python interface to USB CO2 monitor devices by Rebelgecko on Friday April 03, 2020 @01:05AM (#22766432)
His channel is a goldmine for anyone who plays around with ESP-32 microcontrollers or similar devices
Re:CO2meter: A Python interface to USB CO2 monitor devices by lhoff on Thursday April 02, 2020 @06:35PM (#22764603)
Iam looking to build my own CO2 Meter for a while know. I even thought about making a little series as christmas presents. My struggle always was to pick the right module. Its so hard to pick one and really trust it when you don't have a reference.

So i thought maybe i give this sensor a shot but i can't find a reputable source for it. Does someone knows where to buy it or uses another module that works good?

Re:CO2meter: A Python interface to USB CO2 monitor devices by petsfed on Thursday April 02, 2020 @06:51PM (#22764695)
I'm fond of the Sensirion SCD30. Its low cost, low power, and easy to interface with. A lot of NDIR CO2 sensors pull 5V, so the sensirion's 3.3v power is nice. Digikey is currently out of them, but SparkFun has them in stock. Nice for hobbyists!

CO2meter.com is a good source for buying OEM CO2 sensors, although a little too coy with manufacturer's data sheets, in my opinion.

Virtually all NDIR CO2 sensors use some sort of automatic calibration, where the lowest reading in a certain period of time is assigned the value 450ppm. If that's accurate for your area and you can guarantee that the space the sensor is monitoring is unoccupied during that period of time, its not bad. Otherwise, a reference gas is the only way to really trust the readings.

Re:CO2meter: A Python interface to USB CO2 monitor devices by 411111111111111 on Friday April 03, 2020 @01:54AM (#22766628)
i was shopping around last year as well. i finally went with `TFA Dostmann AirControl Mini CO2 Meter`, you can get the data pretty easily [1] if you connect it to a raspberry pi (or any linux system, really), so i'm currently pushing it through MQTT to my HomeAssistant. i was really surprised when i started monitoring it how closely related my concentration is to the co2 ppa in my home.

[1] https://github.com/maddindeiss/co2-monitor

Re:CO2meter: A Python interface to USB CO2 monitor devices by Arkanosis on Friday April 03, 2020 @05:10PM (#22773980)
This is a great device. We've never had windows open as much as since we have it, and believe me, it means a lot of headaches that go away every week without any coffee or paracetamol.

The next time we move house, proper ventilation is definitely one of the first things we'll check.

Re:CO2meter: A Python interface to USB CO2 monitor devices by xenonite on Monday April 06, 2020 @02:36AM (#22791363)
This device is a rebranded RAD-0301 meter. In Germany, this brand seems to be the easiest way for purchasing the RAD-0301.
Re:CO2meter: A Python interface to USB CO2 monitor devices by gsich on Thursday April 02, 2020 @06:58PM (#22764746)
mh-z14 or mh-z19.

Automatic calibration can be disabled.

Re:CO2meter: A Python interface to USB CO2 monitor devices by ClumsyPilot on Thursday April 02, 2020 @09:46PM (#22765682)
I use those, on ESPHome and connected to homeassistant. They seem to provide reasonable readings
Re:CO2meter: A Python interface to USB CO2 monitor devices by throwaway9d0291 on Friday April 03, 2020 @04:48AM (#22767368)
+1 for Sensirion's SCD30 [0], or even better when it comes out, SCD40.

I've tested a lot of different sensors and the SCD30 is more expensive than the Chinese sensors but in my experience it's much more accurate. The problem with all of these sensors is calibration. They naturally drift over time so you need some way to compensate for that. There are a few common approaches:

- Assume that every single day, the sensor is completely immersed in fresh air at some point - this is the way the MH-Z19 series of sensors works. It can make sense in business HVAC systems where it's common to do a fresh air purge every 24h but in a residential environment it's unreliable because there's no guarantee that a room will return to fresh air levels of CO2 (e.g. if a room only has 3-4h unoccupied and the windows aren't open, it might not return to 400ppm). To be clear, this isn't a problem unique to the Chinese sensors. There are also expensive sensors from major and reputable manufacturers that act this way, again, because it's common in commercial HVAC systems to do a daily fresh-air purge.

- The above but a bit more intelligent - this is the SCD30's method: it looks at the previous 7 days of data and only if there were at least 5 days where the baselines are within 50ppm of each other, treats the average of those baselines as the fresh air concentration. This makes it fantastic for residential applications. Even if your room's CO2 levels don't return to 400ppm every day, as long as they don't consistently return to another baseline, the auto-calibration cycle won't run and mess up your data.

- Manually do a baseline calibration every few months: make the user take the sensor outside into fresh air (or vent a building with fresh air) and tell the sensor "the CO2 concentration right now is 400ppm" - this is the only way the MH-Z19 and similar sensors can really be made anything close to accurate.

Also, make sure to avoid anything other than NDIR sensors. There are a lot of "eCO2" sensors that give you estimated CO2 levels based on VOCs, which always results in garbage readings.

Finally, you can usually buy the SCD30 very easily. It's routinely stocked by electronic component distributors so you can just look it up in OctoPart[1]. Make sure to avoid the eval kits though.

[0]: https://www.sensirion.com/en/environmental-sensors/carbon-di...

[1]: https://octopart.com/search?q=Sensirion+SCD30&currency=USD&s...

Re:CO2meter: A Python interface to USB CO2 monitor devices by toasted_flakes on Friday April 03, 2020 @04:54AM (#22767391)
> it looks at the previous 7 days of data and only if there were at least 5 days where the baselines are within 50ppm of each other, treats the average of those baselines as the fresh air concentration.

Is that documented anywhere? I couldn't figure out why mine is reading garbage, it could be that it didn't see fresh air every day for a full week

Re:CO2meter: A Python interface to USB CO2 monitor devices by throwaway9d0291 on Friday April 03, 2020 @06:16AM (#22767793)
The main public information is page 13 of the interface description [0]. I got some more specifics from Sensirion directly when I contacted them (the 50ppm minima thing in particular).

Not seeing fresh air for a week isn't enough to throw it off, it needs to not have seen fresh air for a week _and_ the baselines that it has seen have to be within 50ppm of each other.

Have you allowed it to calibrate even once? It needs 7d of uninterrupted power and daily fresh air for the initial calibration.

You can also do forced calibration against a known value using the process on page 14 of [0].

It can also give iffy results if the temperature/humidity values are totally out of whack, which could happen if it's put in an enclosure or something like that. You can set an offset using the instructions on page 15 of [0].

There's also altitude compensation but unless you're doing something really weird that shouldn't affect you so much.

Finally, there's sensor placement [1]. It shouldn't be placed in such a way that there's a lot of air flowing over it directly (e.g. exposed to the air). If it's in front of a fan or something it's going to do weird things.

I'd suggest placing it outside for a few minutes and see what the readings are. If they're far from 400ppm it definitely needs calibrating.

[0]: https://www.sensirion.com/fileadmin/user_upload/customers/se...

[1]: https://www.sensirion.com/fileadmin/user_upload/customers/se...

Re:CO2meter: A Python interface to USB CO2 monitor devices by petsfed on Friday April 03, 2020 @11:49AM (#22770452)
"There's also altitude compensation but unless you're doing something really weird that shouldn't affect you so much."

Disagree. I've moved co2 sensors between sea level and 2000m, and measured reference 400ppm gas and seen quite large differences (~150ppm). So it can matter. That's the reason why the SCD30 allows you to set an altitude or pressure.

But its not important enough to constantly feed it pressure data, a once-a-day pressure reading from the NWS would be sufficient.

Re:CO2meter: A Python interface to USB CO2 monitor devices by toasted_flakes on Friday April 03, 2020 @10:05AM (#22769227)
Brilliant, thanks. I didn't realise the threshold was 5 days out of a full week, and didn't remember reading about the 50ppm minima.
Re:CO2meter: A Python interface to USB CO2 monitor devices by lorenzhs on Friday April 03, 2020 @05:41AM (#22767616)
Re:CO2meter: A Python interface to USB CO2 monitor devices by mataug on Thursday April 02, 2020 @06:39PM (#22764620)
+1 on this,

Where does one buy a reliable indoor sensor ?

Re:CO2meter: A Python interface to USB CO2 monitor devices by foobarbecue on Thursday April 02, 2020 @08:42PM (#22765349)
Hunh. I've been working with gas monitoring for years (mostly during my volcanology PhD) and written lots of code to interface with many CO2 sensors, usually as part of packages that talked to many other sensors. Other than some weird binary protocols, it was all straightforward, brainless code so I never thought it needed to be published. LMK if anybody wants a hand with anything specific.
Re:CO2meter: A Python interface to USB CO2 monitor devices by bjelkeman-again on Friday April 03, 2020 @01:54AM (#22766627)
What would be a good oxygen air sensor?
Re:CO2meter: A Python interface to USB CO2 monitor devices by foobarbecue on Friday April 03, 2020 @11:07AM (#22769946)
I've used a few multigas sensors that had O2 when mapping volcanic caves -- Draeger Multiwarn, MultiRAE, National... Safety (?), and CrowCon GasMan. The CrowCon was my favorite by far. Disclosure: they gave us equipment for free as sponsorship for our expedition, but it was also honestly just way better than the Draeger or RAE. Great datalogger built-in with good serial interface, small, waterproof enough for our uses (the others said IP68 and still died of water damage). I suspect all CrowCon products are quite good and cheaper than the competition.
Re:CO2meter: A Python interface to USB CO2 monitor devices by foobarbecue on Saturday April 04, 2020 @08:58AM (#22777979)
Or, if you're building your own unit, then I remember citytech (welcome to city tech!) was pretty much the only option when I was doing it. The circuits to run electrochemical gas sensors are a little annoying to set up.
Re:CO2meter: A Python interface to USB CO2 monitor devices by smcleod on Thursday April 02, 2020 @07:20PM (#22764888)
I had a good play with MH-Z19 Co2 sensors and some basic python, here's some photos (and some old crappy code): https://github.com/sammcj/CO2-Logger#photos
Re:CO2meter: A Python interface to USB CO2 monitor devices by platz on Thursday April 02, 2020 @08:14PM (#22765191)
I'd be more interested in VOC sensors or PM2.5 sensors.

I feel like PM sensors are easy to understand. I wish i had a better grasp on VOC/TVOC though.

It's hard to interpret what an elevated VOC from my foobot actually means.

Re:CO2meter: A Python interface to USB CO2 monitor devices by gh02t on Friday April 03, 2020 @09:48AM (#22769082)
I've used the Plantower PMS7003 sensors for some DIY particulate sensors. I don't have a lab reference to calibrate against, but they should be pretty accurate as they are a laser sensor and the readings I got out of them were very sensible and consistent. Plus they include a tiny fan, which is important to get good readings. They are easy to use as well, it's just a simple UART digital interface. I also experimented with the cheaper Sharp IR dust sensors, but these were much less stable and also require constant calibration; they were ok for doing simple relative readings but they were clearly very inaccurate and unstable.

Sensing VOC's accurately is really difficult because most sensors have radically different (orders of magnitude) sensitivities to multiple compounds but can't actually distinguish between them. The readings typically get heavily skewed by the presence of minute amounts of some compound the sensor is very sensitive to. I tried several sensors and the best I could get out of them was a relative "good / bad" reading.

Re:CO2meter: A Python interface to USB CO2 monitor devices by platz on Friday April 03, 2020 @01:12PM (#22771626)
The PMS7003 looks like a great option, thanks!
Re:CO2meter: A Python interface to USB CO2 monitor devices by gh02t on Thursday April 02, 2020 @06:59PM (#22764748)
Interesting, but does anybody know which USB meter is this meant to be used with? I can't actually find it in any of the docs or links, but maybe I'm overlooking it.
Re:CO2meter: A Python interface to USB CO2 monitor devices by warp on Thursday April 02, 2020 @09:04PM (#22765471)
Re:CO2meter: A Python interface to USB CO2 monitor devices by lhoff on Thursday April 02, 2020 @07:02PM (#22764772)
There is a link to a manual for the ZG01 CO2 Module at the bottom of the page. So i guess the lib is for that module. But i couldn't find a source to buy that.
Re:CO2meter: A Python interface to USB CO2 monitor devices by xenonite on Friday April 03, 2020 @05:51AM (#22767661)
Great, this works instantly with my recently purchased TFA AirCO2ntrol Mini [1]. Moderately priced for EUR 65, this gives relatively accurate readings (the maximum of ±7% or ±100ppm for values <=2000ppm, and ±10% for values >2000ppm).

[1] https://www.tfa-dostmann.de/en/produkt/co2-monitor-airco2ntr...

Re:CO2meter: A Python interface to USB CO2 monitor devices by xenonite on Monday April 06, 2020 @02:35AM (#22791361)
This device probably is a rebranded RAD-0301 meter.
Re:CO2meter: A Python interface to USB CO2 monitor devices by toasted_flakes on Friday April 03, 2020 @04:46AM (#22767359)
I have a scd30 from Sensirion, hooked up to a raspberry pi GPIO pins, with a python script pushing the measurement to InfluxDB and Grafana.

It's super cool how open source projects make it easy to get a great UI, built-in basic statistics etc, with a few hours of datasheet reading.

Word of warning though: make a proper enclosure for the sensor. Mine is now perpetually reading 1400 ppm or above after a fairly rough move, even outside (where it should be about 415 ppm).

Re:CO2meter: A Python interface to USB CO2 monitor devices by doitLP on Thursday April 02, 2020 @11:19PM (#22766054)
Great to see this here. I started monitoring the CO2 levels in my new apartment after waking up with headaches every night since moving in.

Plugged it in and the alarm started going off immediately at 3000ppm. I use this package to graph out the readings.

Recently started at a new job and had to educate everyone on the issues with CO2 build up in meeting rooms. We got each meeting room outfitted with a sensor and custom monitoring with grafana now.

Re:CO2meter: A Python interface to USB CO2 monitor devices by awinter-py on Thursday April 02, 2020 @08:49PM (#22765398)
cool that it has a timeseries! I'm not familiar with this space but 'timeseries for iot' is a consumer category that I would be a consumer of

(really could be just me though)

Re:CO2meter: A Python interface to USB CO2 monitor devices by tito on Thursday April 02, 2020 @07:32PM (#22764970)
Gut check here, could you share what you want to use a CO2 monitor for?
Re:CO2meter: A Python interface to USB CO2 monitor devices by losteric on Thursday April 02, 2020 @08:20PM (#22765227)
Monitoring CO2 levels? Personally, I want a discrete meter for monitoring levels in meetings... especially large design/product discussions. I suspect some of our meeting rooms have poor ventilation and CO2 build up contributes to increasingly dumb discussions.
Re:CO2meter: A Python interface to USB CO2 monitor devices by tito on Thursday April 02, 2020 @08:45PM (#22765373)
Awesome! That's what I figured but wanted to check. Yes, indoor air in meeting rooms gets crazy, easily above 1000 ppm.
Re:CO2meter: A Python interface to USB CO2 monitor devices by gbear605 on Thursday April 02, 2020 @08:24PM (#22765258)
https://slatestarcodex.com/2018/08/23/carbon-dioxide-an-open... gives a decent reason why you should care about controlling (and thus monitoring as a first step) internal CO2 levels.
Re:CO2meter: A Python interface to USB CO2 monitor devices by bjelkeman-again on Friday April 03, 2020 @02:01AM (#22766646)
Indoor growing, CO2 levels drop and so does the plants ability to grow.