Measuring air quality

When people think about comfort in their apartment, most people think first about temperature. But another important factor is air quality. I don’t have to tell you that smells from cooking aren’t always the best. There are much more particles in the air that impact the quality. These particles are generally named “Particulate matter”. The EPA defines PM as follows:

“Particulate matter, or PM, is the term for particles found in the air, including dust, dirt, soot, smoke, and liquid droplets. Particles can be suspended in the air for long periods of time. Some particles are large or dark enough to be seen as soot or smoke. Others are so small that individually they can only be detected with an electron microscope. ”

Today, most measurements you find are PM2.5 measurements. This measures particles smaller than 2.5µm. Roughly one out of every three people in the United States is at a higher risk of experiencing PM2.5 related health effects.

Do you know the PM2.5 values in your living environment? Most likely not, but it is relatively easy and cheap to do do these measurements today. While calibrated sensors is still very expensive, for home-use uncalibrated sensors do a good job to give you a rough idea about possible problems.

These sensors work as follows:

dust-sensor

A light sends light into an air flow. Small particles will reflect the light. A receiver than measures these reflections. Seems very simple – right? It really is. The cheapest sensors are available for less than $20 on Chinese shopping sites. They use LEDs as a light source. Laser-based devices are a bit more expensive ($50 and up), but they can detect smaller particles.

Let’s have a look about a laser-based sensor like this:

P7180912-web

The fan creates an continuos air flow through the device. Looking into the device you see the air channel and the detector.

P7180899-web

The detector looks like this:


What else is inside?

This is the simple PCB. It is based on a small microcontroller and some external components.

The good thing about these (more expensive) sensors is that they already do the hard work for you. They have a serial output that already sends the PM1.0, PM2.5 and PM10 values.

You can use a simple USB-to-Serial converter and read the data directly from your PC. How to connect this sensor to the adapter is shown here.

References

Cool sensors for your next automation project

Home automation isn’t about controlling a lamp with your smartphone. It is called “automation”. A home automation software should do things automatically. Do do this, it needs to have an idea what’s going on in your apartment (or outside). For this, you need sensors. While some sensor types are well-known you might not know what is available already on the market for a small budget. The following sensors can be integrated easily with your Arduino, EPS8266 or Raspberry Pi.

Temperature

35040-img_0674Almost everybody already did experiments with temperature sensors. The DS18B20 is a 1-Wire sensor that can be connected easily to many platforms. You will find a lot of code snippets for this sensor already. It has a 0.5 degree celsius accuracy which is more than enough for most use cases. If you only want to monitor the temperature, go for this one.

Humidity

dht-11-1The DHT-11 and DHT-22 are two sensors that combine a temperature sensor with a humidity sensor. Both are more expensive than a simple temperature sensor. However, humidity informations might help you to do better automatisations. One use case could be turning on an air humidifier when the humidity is too low. Another would be opening windows, when humidity is too high. While these sensors also use a 1-Wire-type protocol, it is different from the 18B20 sensor. You can’t connect both sensors to the same GPIO. However as the DHT-11 has the temperature sensor already included, there is no need for an additional 18B20.

Soil moisture

13995201090You’re plant are dying regularly because you forget to water them? Another use case for a sensor. Soil moisture sensors are available in 2 variants: the cheap sensors just measure the soil resistance. The problem with this sensor type is corrosion (over a longer lifetime). Capacitive sensors are becoming more popular and don’t show this problem as the electrodes are isolated. However, they are more expensive and a bit less sensitive. You need to experiment a bit to find the correct threshold for alarming.

Motion detection

pir-motion-sensor-536x408You want to know if somebody is home? PIR motion sensors are also available for a few bucks and will give you information about people (or pets) moving. If somebody is just sitting or sleeping, the motion sensor won’t detect this. However, for many use cases this is just fine.

Sound pressure

grove-Sound-SensorYou’re not at home, but your teenage son. What do you think will happen? A party! Your neighbors will tell you tomorrow. Wouldn’t it be cool to automatically reduce the volume of your stereo system when the volume exceeds a specific level? This level might be higher at 5pm than at 11pm. A sound pressure sensor will do the job – at least until your son finds our where it is located and puts some damping onto it.

Small particles

Particle sensorSmall particles in the air can be a problem for some people – especially if you suffer from asthma. These emissions can come from various sources. Measuring the number of small particles in the air might give you an idea what might be the source and do something against it. These sensors are based on optical measurements. While this might sound complicated, sensors like this are not very expensive anymore.

433MHz window sensor

On eBay, Alibaba or other web sites, you can find cheap Window sensors that will send a data packet to inform you about the state of your windows. They often costs less than 10$ per unit, which makes it easy to test them.

They look like this:

Newest-High-quality-1Pcs-433-MHZ-Wireless-Home-Security-Door-Window-Sensor-Detector-with-Battery-for

But what’s inside? Let’s have a look. The part that is mounted on the window itself is basically just a magnet. You might already know what will be on the other side: a reed relay. But what else:

The electronic circuit is based on the HS1527. The nice thing about this chip is the 1uA standby current. Even with a small battery, the battery life will be relatively high. It is powered by a small 12V battery – I haven’t seen this battery type before.

The good thing about the chip is that you can use a lot of cheap 433MHz receivers connected to a Raspberry Pi or Arduino to receive the signals.

However, there is one major downside: This sensor sends only a data packet when you open the window, not when you close it. This is ok if you want to use it to detect break-ins, but it won’t work if you want to detect if a window is open (e.g. if you want to turn off the heating).

Therefore I can’t recommend this sensor type for home automation use.

Innovation begins at home

Andy Stanford-Clark, IBM Distinguished Engineer for the Internet of Things, will explain how his hobby of home automation and his passion for energy saving converges with the Internet of Things.
This has led to projects that have helped alleviate energy poverty in social housing, and are helping commuters from the Isle of Wight check if the ferries are running on time.
Andy will explain that “it’s all about the data” and how these solutions are built from instrumented, interconnected, intelligent devices. He will illustrate his talk with examples from his home, including his twittering mouse traps!

Click on the image to view the video on Vimeo.

Screenshot 2016-05-17 09.22.36

A minimal KNX setup

If you are an experienced electronics hacker and you want to do some tests with KNX, you need to invest a bit. However, a minimal KNX setup for initial tests doesn’t have to be very expensive:

  • a 29V power supply that supplies at least 300mA
    Most bench power supplies will do the job. For a test you don’t have to buy an expensive KNX power supply.
  • a KNX choke
    You can’t connect KNX devices directly to the power supply. A choke is essential. Without it, no communication on the bus will be possible. Standalone chokes starts at around 35€.
    Another option is using a 47-Ohm resistor in between the power supply and your KNX bus line. While it might not work, it is worth a try as it will cost you only a few cent.
  • a KNX sensor
    If you have some push buttons laying around, a cheap KNX bus coupler from eBay might be the cheapest option. You can get these for less than 30€
  • a KNX actuator
    Some KNX sensors (like wall-mounted push buttons) have status LEDs that can be controlled from the KNX bus. In this case, you do not need a separate actuator. Otherwise have a look on eBay for old binary outputs. You should be able to find something for less than 30€
  • USB or Ethernet interface
    USB interfaces are usually a bit cheaper. You might find used USB interfaces in the range of 50-80€. However, I would still recommend to spend a bit more money and buy an Ethernet/KNX interface. You are more flexible with these as multiple devices can access it simultaneously. You might not be able to save a lot of money on a used one, but new Ethernet interfaces are available from 150€

This means, a minimal KNX setup will cost you between 200€ and 300€. This isn’t really cheap, but still less expensive than many people might think. The good thing: The most expensive component is the Ethernet interface. If you decide not to go on with a full KNX installation, you can still sell it for a good price. Otherwise, you can use this in your house installation.

The minimal installation looks like this:

Minimal KNX installation