MISSION 17

Moisture Sensor for Your Plants

Plants provide oxygen, they look good, and they smell great. Plants are cool. To keep my plants alive, I’m going to create a sensor that checks whether the soil inside my potted plants is moist.

When soil is wet, it conducts electricity! So we can use the micro:bit and the Circuit Playground Express to keep an eye on the moistness level of our potted plant soil. Try to say this three times: “potted plant soil, potted plant soil, potted plant soil.”

Instead of using the digital read pin, we’re going to use analogue read. Digital read returns either 1 or 0, true or false. I’d like to know how wet/dry my soil is. I want a range of numbers. Analogue read returns a range of numbers. Both the micro:bit and ...

Get Save the World with Code: 20 Fun Projects for All Ages Using Raspberry Pi, micro:bit, and Circuit Playground Express now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.