Skip to the content
2 layers40 × 125 mmMoisture sensor, the printed circuit board in 3D

Capacitive moisture sensor

Size
40 × 125 mm
Copper layers
2
Thickness
1.6 mm
Parts
35
Nets
33
Pads
120
Tracks, vias
281, 86
Pours
3
Routed
Yes
KiCad
KiCad 6 (file 20211014)
Created
8 Nov 2022
Updated
5 Dec 2022

Overview

Moisture sensor is an open-source printed circuit board by friedrich, from the friedrich/soil-moisture-sensor repository on GitHub. It is a 2-layer board of 40 × 125 mm with 35 parts on 33 nets, routed with 281 tracks and 86 vias.

It is built around the ESP32-C3-WROOM-02-N4, TPS631000DRL and RC0805FR-0710KL, with the GRM21BR71A106KA73, GRM21A5C2E180JW01 and GRM21BR61A476ME15L among its other parts. Its parts include 14 resistors, 8 capacitors, 3 ICs, 3 diodes and 1 connector. It belongs with the sensors and measurement boards and the ESP32 and RISC-V boards of this library.

Main components

12

README

README.md

Moisture sensor

A capacitive moisture sensor board employing an ESP32-C3 RISC-V microcontroller capable of transmitting measurements via Wi-Fi and Bluetooth 5 (LE). The board is powered by a single cell LiPo battery, which can be charged using the USB-C port.

rendering

Components are spaced quite far apart, with the goal of making it easier to solder them by hand.

Sensor circuit

rendering

The sensor circuit consists of the following building blocks:

  • The microcontroller generating a square wave, depicted as voltage source $U_0$.
  • A low pass filter made up of resistor $R_1$ and capacitor $C_1$. Capacitor $C_1$ stands for sensor wires together with the medium to be measured acting as a dielectric. Its value is to be determined by the circuit.
  • A peak voltage detector made up of diode $D_1$, resistor $R_2$ and capacitor $C_2$.
  • The microcontroller measuring voltage $U_2$.

Since resistor $R_2$ is chosen to be quite large, the impact of the peak voltage detector on the low pass filter becomes negligible, as soon as $C_2$ reaches a stable voltage. Just considering the voltage source together with the low pass filter leads to a peak voltage of

$$ U_p = U_+ \frac{1 - e^{-\omega T D}}{1 - e^{-\omega T}}, $$

where $U_+$ is the high voltage of the voltage source, $T$ the period, $D$ the duty cycle, and $\omega = 1/(R_1 C_2)$. The peak voltage has a range from $U_+$ for zero $C_2$ down to $D U_+$ for infinite $C_2$.

Possible future circuit improvements

  • Add battery protection circuit.
  • Add a switch for turning the device on and off.
  • Add a button to put the device into a mode where it acts as an access point or can be connected via Bluetooth.
  • Make it possible for the microcontroller to measure battery voltage and to know if it is powered using USB or the battery. Detect USB using an RTC GPIO port to be able to wake the microcontroller when plugged in.
  • Replace the battery solder pads with a connector.
  • Remove sensing traces from the top so that it matters less how deep the sensor is pushed into the soil. Additionally, moisture variations are more relevant deeper down than on the top.
  • Increase the length of the probe.
  • Make it possible to power the board without a battery, using USB-C only. This is currently possible by bypassing the battery charge management controller by connecting VDD and +BATT. Otherwise, the power supply voltage of the microcontroller is not stable.
  • Expose JTAG pins for development since the USB-to-JTAG interface is turned off during deep sleep.

Parts

35
QtyValueFootprintReferences
410kResistor_SMD:R_0805_2012Metric_Pad1.20x1.40mm_HandSolderR1, R2, R3, R10
210uFCapacitor_SMD:C_0805_2012Metric_Pad1.18x1.45mm_HandSolderC8, C9
218pFCapacitor_SMD:C_0805_2012Metric_Pad1.18x1.45mm_HandSolderC2, C3
21kResistor_SMD:R_0805_2012Metric_Pad1.20x1.40mm_HandSolderR4, R9
247uFCapacitor_SMD:C_0805_2012Metric_Pad1.18x1.45mm_HandSolderC4, C5
25.1kResistor_SMD:R_0805_2012Metric_Pad1.20x1.40mm_HandSolderR6, R7
2Conn_01x01Connector_Wire:SolderWire-0.25sqmm_1x01_D0.65mm_OD1.7mm-BATT1, +BATT1
2LEDDiode_SMD:D_0805_2012Metric_Pad1.15x1.40mm_HandSolderD1, D2
11MResistor_SMD:R_0805_2012Metric_Pad1.20x1.40mm_HandSolderR14
11nFCapacitor_SMD:C_0805_2012Metric_Pad1.18x1.45mm_HandSolderC6
11uFCapacitor_SMD:C_0805_2012Metric_Pad1.18x1.45mm_HandSolderC1
11uHInductor_SMD:L_1008_2520Metric_Pad1.43x2.20mm_HandSolderL1
1220RResistor_SMD:R_0805_2012Metric_Pad1.20x1.40mm_HandSolderR12
13.3kResistor_SMD:R_0805_2012Metric_Pad1.20x1.40mm_HandSolderR13
132.768kHzCrystal:Crystal_SMD_G8-2Pin_3.2x1.5mm_HandSolderingY1
147RResistor_SMD:R_0805_2012Metric_Pad1.20x1.40mm_HandSolderR11
1511kResistor_SMD:R_0805_2012Metric_Pad1.20x1.40mm_HandSolderR5
191kResistor_SMD:R_0805_2012Metric_Pad1.20x1.40mm_HandSolderR8
1DDiode_SMD:D_SOD-323_HandSolderingD3
1ESP32-C3-WROOM-02library:ESP32-C3-WROOM-02U1
1EVQ-Q2F03WButton_Switch_SMD:SW_SPST_EVQP2RESET1
1Jumper_2_OpenJumper:SolderJumper-2_P1.3mm_Open_RoundedPad1.0x1.5mmBOOT1
1MCP73832Package_TO_SOT_SMD:SOT-23-5_HandSolderingU4
1TPS631000Package_TO_SOT_SMD:SC-70-8U2
1USB4110library:USB4110-GF-A_REVBJ3

Similar boards

  • 2 layersMacropad, the printed circuit board in 3D

    Macropad

    moonbeeper/moonpad

    109 partsMIT
  • 4 layers42 × 65 mmIcarus Flight Computer, the printed circuit board in 3D

    Icarus Flight Computer

    daedalus-ind/icarus-hardware

    Hardware of the onboard flight computer for the Icarus rocket.

    106 parts2MIT
  • 6 layers64.2 × 40.6 mmInitial physical, the printed circuit board in 3D

    Initial physical

    tbennellick/sts-hiz-serial-bodge

    586 parts
  • 4 layers96 × 71.9 mm260510-Digital hearing aid, the printed circuit board in 3D

    260510-Digital hearing aid

    RV-crtl/Digital-Hearing-Aid-G1

    Anna — controls · Ryan — BT/telecoil · Mariya — microphone/DSP · Naomi — speaker output · Interface contracts

    236 parts
  • 2 layers80 × 70 mmPlaced before silk, the printed circuit board in 3D

    Placed before silk

    SamarGrigoriy/simistor-regulator

    Семисторный регулятор

    41 parts1MIT
  • 4 layers144.7 × 95.9 mmCell Monitoring Unit (CMU), the printed circuit board in 3D

    Cell Monitoring Unit (CMU)

    VikingMotorsports/Battery-Management-System-Capstone-2026

    The BMS Capstones deliverables

    186 parts1
  • 4 layers100 × 106 mmDelivery robot 1, the printed circuit board in 3D

    Delivery robot 1

    ECE49022Team22/delivery-robot-pcb

    Delivery robot KiCad PCB project and reusable 3.3 V LDO module

    181 parts
  • 2 layers80 × 70 mmPd bench, the printed circuit board in 3D

    Pd bench

    kekoraa/usb-c-pd-bench-breakout

    USB-C PD trigger/breakout with selectable voltage requests and a routed two-layer KiCad PCB. Design-stage

    31 parts

Questions

How big is the Moisture sensor PCB?

It measures 40 × 125 mm and has 2 copper layers, 1.6 mm thick.

What parts does the Moisture sensor use?

35 parts, built around the ESP32-C3-WROOM-02-N4, TPS631000DRL, RC0805FR-0710KL and GRM21BR71A106KA73. The full list of its parts is on this page, with links to each part's symbol and footprint where PCBKit's library has them.

Where can I download the Moisture sensor KiCad files?

From the friedrich/soil-moisture-sensor repository on GitHub, at the commit this page was made from: the board is pcb/moisture-sensor.kicad_pcb and its schematic pcb/moisture-sensor.kicad_sch. PCBKit opens the board in the browser, with nothing to install.

Can I use the Moisture sensor design in my own project?

Its repository states no licence, so its author keeps all rights: ask friedrich before reusing the design.